2 # SSLeay/crypto/bn/Makefile
8 INCLUDES= -I.. -I../../include
10 INSTALLTOP=/usr/local/ssl
11 MAKE= make -f Makefile.ssl
12 MAKEDEPEND= makedepend -f Makefile.ssl
13 MAKEFILE= Makefile.ssl
20 CFLAGS= $(INCLUDES) $(CFLAG)
25 TEST=bntest.c exptest.c
28 LIB=$(TOP)/libcrypto.a
29 LIBSRC= bn_add.c bn_div.c bn_exp.c bn_lib.c bn_mod.c bn_mul.c \
30 bn_print.c bn_rand.c bn_shift.c bn_sub.c bn_word.c bn_blind.c \
31 bn_gcd.c bn_prime.c $(ERRC).c bn_sqr.c bn_mulw.c bn_recp.c bn_mont.c \
34 LIBOBJ= bn_add.o bn_div.o bn_exp.o bn_lib.o bn_mod.o bn_mul.o \
35 bn_print.o bn_rand.o bn_shift.o bn_sub.o bn_word.o bn_blind.o \
36 bn_gcd.o bn_prime.o $(ERRC).o bn_sqr.o $(BN_MULW) bn_recp.o bn_mont.o \
43 HEADER= bn_lcl.h bn_prime.h $(EXHEADER)
45 ALL= $(GENERAL) $(SRC) $(HEADER)
48 (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all)
53 cc -pg -I.. -I../../include bn_knuth.c -o knuth $(LIB) #../../../libefence.a
55 knuth.fast: bn_knuth.c
56 cc -pg -fast -I.. -I../../include bn_knuth.c -o knuth $(LIB) #../../../libefence.a
60 $(AR) $(LIB) $(LIBOBJ)
61 sh $(TOP)/util/ranlib.sh $(LIB)
65 asm/bn86-elf.o: asm/bn86unix.cpp
66 $(CPP) -DELF asm/bn86unix.cpp | as -o asm/bn86-elf.o
69 asm/bn86-sol.o: asm/bn86unix.cpp
70 $(CC) -E -DSOL asm/bn86unix.cpp | sed 's/^#.*//' > asm/bn86-sol.s
71 as -o asm/bn86-sol.o asm/bn86-sol.s
75 asm/bn86-out.o: asm/bn86unix.cpp
76 $(CPP) -DOUT asm/bn86unix.cpp | as -o asm/bn86-out.o
79 asm/bn86bsdi.o: asm/bn86unix.cpp
80 $(CPP) -DBSDI asm/bn86unix.cpp | as -o asm/bn86bsdi.o
83 (cd asm; perl bn-586.pl cpp >bn86unix.cpp )
86 perl $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
90 $(TOP)/util/point.sh Makefile.ssl Makefile ;
91 $(TOP)/util/mklink.sh ../../include $(EXHEADER)
92 $(TOP)/util/mklink.sh ../../test $(TEST)
93 $(TOP)/util/mklink.sh ../../apps $(APPS)
96 @for i in $(EXHEADER) ; \
98 (cp $$i $(INSTALLTOP)/include/$$i; \
99 chmod 644 $(INSTALLTOP)/include/$$i ); \
104 gcc -I../../include -g2 -ggdb -o exptest exptest.c ../../libcrypto.a
108 gcc -I.. -g div.c ../../libcrypto.a
116 lint -DLINT $(INCLUDES) $(SRC)>fluff
119 $(MAKEDEPEND) $(INCLUDES) $(PROGS) $(LIBSRC)
122 perl -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
123 mv -f Makefile.new $(MAKEFILE)
126 /bin/rm -f *.o */*.o *.obj lib tags core .pure .nfs* *.old *.bak fluff bn_mulw.s
129 perl $(TOP)/util/err-ins.pl $(ERR).err $(ERR).org # special case .org
130 perl $(TOP)/util/err-ins.pl $(ERR).err $(ERR).h
131 perl ../err/err_genc.pl -s $(ERR).h $(ERRC).c
133 # DO NOT DELETE THIS LINE -- make depend depends on it.