RC4 for s390x.
[openssl.git] / crypto / rc4 / Makefile
1 #
2 # OpenSSL/crypto/rc4/Makefile
3 #
4
5 DIR=    rc4
6 TOP=    ../..
7 CC=     cc
8 CPP=    $(CC) -E
9 INCLUDES=
10 CFLAG=-g
11 AR=             ar r
12
13 RC4_ENC=rc4_enc.o rc4_skey.o
14
15 CFLAGS= $(INCLUDES) $(CFLAG)
16 ASFLAGS= $(INCLUDES) $(ASFLAG)
17 AFLAGS= $(ASFLAGS)
18
19 GENERAL=Makefile
20 TEST=rc4test.c
21 APPS=
22
23 LIB=$(TOP)/libcrypto.a
24 LIBSRC=rc4_skey.c rc4_enc.c
25 LIBOBJ=$(RC4_ENC)
26
27 SRC= $(LIBSRC)
28
29 EXHEADER= rc4.h
30 HEADER= $(EXHEADER) rc4_locl.h
31
32 ALL=    $(GENERAL) $(SRC) $(HEADER)
33
34 top:
35         (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all)
36
37 all:    lib
38
39 lib:    $(LIBOBJ)
40         $(AR) $(LIB) $(LIBOBJ)
41         $(RANLIB) $(LIB) || echo Never mind.
42         @touch lib
43
44 rc4-586.s:      asm/rc4-586.pl ../perlasm/x86asm.pl
45         $(PERL) asm/rc4-586.pl $(PERLASM_SCHEME) $(CFLAGS) > $@
46
47 rc4-x86_64.s: asm/rc4-x86_64.pl
48         $(PERL) asm/rc4-x86_64.pl $(PERLASM_SCHEME) > $@
49
50 rc4-ia64.S: asm/rc4-ia64.pl
51         $(PERL) asm/rc4-ia64.pl $(CFLAGS) > $@
52
53 rc4-s390x.s:    asm/rc4-s390x.pl
54         $(PERL) asm/rc4-s390x.pl > $@
55
56 rc4-ia64.s: rc4-ia64.S
57         @case `awk '/^#define RC4_INT/{print$$NF}' $(TOP)/include/openssl/opensslconf.h` in \
58         int)    set -x; $(CC) $(CFLAGS) -DSZ=4 -E rc4-ia64.S > $@ ;; \
59         char)   set -x; $(CC) $(CFLAGS) -DSZ=1 -E rc4-ia64.S > $@ ;; \
60         *)      exit 1 ;; \
61         esac
62
63 files:
64         $(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
65
66 links:
67         @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
68         @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
69         @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
70
71 install:
72         @[ -n "$(INSTALLTOP)" ] # should be set by top Makefile...
73         @headerlist="$(EXHEADER)"; for i in $$headerlist ; \
74         do  \
75         (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
76         chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
77         done;
78
79 tags:
80         ctags $(SRC)
81
82 tests:
83
84 lint:
85         lint -DLINT $(INCLUDES) $(SRC)>fluff
86
87 depend:
88         @[ -n "$(MAKEDEPEND)" ] # should be set by upper Makefile...
89         $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC)
90
91 dclean:
92         $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
93         mv -f Makefile.new $(MAKEFILE)
94
95 clean:
96         rm -f *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
97
98 # DO NOT DELETE THIS LINE -- make depend depends on it.
99
100 rc4_enc.o: ../../e_os.h ../../include/openssl/bio.h
101 rc4_enc.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h
102 rc4_enc.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
103 rc4_enc.o: ../../include/openssl/lhash.h ../../include/openssl/opensslconf.h
104 rc4_enc.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
105 rc4_enc.o: ../../include/openssl/rc4.h ../../include/openssl/safestack.h
106 rc4_enc.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
107 rc4_enc.o: ../cryptlib.h rc4_enc.c rc4_locl.h
108 rc4_skey.o: ../../e_os.h ../../include/openssl/bio.h
109 rc4_skey.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h
110 rc4_skey.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
111 rc4_skey.o: ../../include/openssl/lhash.h ../../include/openssl/opensslconf.h
112 rc4_skey.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
113 rc4_skey.o: ../../include/openssl/rc4.h ../../include/openssl/safestack.h
114 rc4_skey.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
115 rc4_skey.o: ../cryptlib.h rc4_locl.h rc4_skey.c