Proper support for OpenBSD-i386 shared build, including assember modules!
[openssl.git] / crypto / ripemd / Makefile.ssl
1 #
2 # SSLeay/crypto/ripemd/Makefile
3 #
4
5 DIR=    ripemd
6 TOP=    ../..
7 CC=     cc
8 CPP=    $(CC) -E
9 INCLUDES=
10 CFLAG=-g
11 INSTALL_PREFIX=
12 OPENSSLDIR=     /usr/local/ssl
13 INSTALLTOP=/usr/local/ssl
14 MAKE=           make -f Makefile.ssl
15 MAKEDEPPROG=    makedepend
16 MAKEDEPEND=     $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
17 MAKEFILE=       Makefile.ssl
18 AR=             ar r
19
20 RIP_ASM_OBJ=
21
22 CFLAGS= $(INCLUDES) $(CFLAG)
23 ASFLAGS= $(INCLUDES) $(ASFLAG)
24 AFLAGS= $(ASFLAGS)
25
26 GENERAL=Makefile
27 TEST=rmdtest.c
28 APPS=
29
30 LIB=$(TOP)/libcrypto.a
31 LIBSRC=rmd_dgst.c rmd_one.c
32 LIBOBJ=rmd_dgst.o rmd_one.o $(RMD160_ASM_OBJ)
33
34 SRC= $(LIBSRC)
35
36 EXHEADER= ripemd.h
37 HEADER= rmd_locl.h rmdconst.h $(EXHEADER)
38
39 ALL=    $(GENERAL) $(SRC) $(HEADER)
40
41 top:
42         (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all)
43
44 all:    lib
45
46 lib:    $(LIBOBJ)
47         $(AR) $(LIB) $(LIBOBJ)
48         $(RANLIB) $(LIB) || echo Never mind.
49         @touch lib
50
51 # ELF
52 asm/rm86-elf.s: asm/rmd-586.pl ../perlasm/x86asm.pl
53         (cd asm; $(PERL) rmd-586.pl elf $(CFLAGS) > ../$@)
54 # COFF
55 asm/rm86-cof.s: asm/rmd-586.pl ../perlasm/x86asm.pl
56         (cd asm; $(PERL) rmd-586.pl coff $(CFLAGS) > ../$@)
57 # a.out
58 rm86-out.s: asm/rmd-586.pl ../perlasm/x86asm.pl
59         (cd asm; $(PERL) rmd-586.pl a.out $(CFLAGS) > ../$@)
60
61 files:
62         $(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
63
64 links:
65         @sh $(TOP)/util/point.sh Makefile.ssl Makefile
66         @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
67         @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
68         @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
69
70 install:
71         @for i in $(EXHEADER) ; \
72         do  \
73         (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
74         chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
75         done;
76
77 tags:
78         ctags $(SRC)
79
80 tests:
81
82 lint:
83         lint -DLINT $(INCLUDES) $(SRC)>fluff
84
85 depend:
86         $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC)
87
88 dclean:
89         $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
90         mv -f Makefile.new $(MAKEFILE)
91
92 clean:
93         rm -f asm/rm86unix.cpp asm/*.s asm/*.o *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
94
95 # DO NOT DELETE THIS LINE -- make depend depends on it.
96
97 rmd_dgst.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
98 rmd_dgst.o: ../../include/openssl/opensslv.h ../../include/openssl/ripemd.h
99 rmd_dgst.o: ../md32_common.h rmd_dgst.c rmd_locl.h rmdconst.h
100 rmd_one.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h
101 rmd_one.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h
102 rmd_one.o: ../../include/openssl/ossl_typ.h ../../include/openssl/ripemd.h
103 rmd_one.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
104 rmd_one.o: ../../include/openssl/symhacks.h rmd_one.c