Mercurial > dropbear
annotate Makefile.in @ 147:c2b93763dac9 libtomcrypt
Fixes for it to compile and work nicely with Dropbear.
In particular, OS X's 'ar' doesn't seem to like arrays
which don't have initialising values.
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Sun, 19 Dec 2004 16:23:32 +0000 |
parents | 7ed585a2c53b |
children | b4c6e7f276e9 |
rev | line source |
---|---|
138 | 1 # MAKEFILE for linux GCC |
2 # | |
3 # Tom St Denis | |
4 # Modified by Clay Culver | |
5 | |
6 # The version | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
7 VERSION=0.99 |
138 | 8 |
147
c2b93763dac9
Fixes for it to compile and work nicely with Dropbear.
Matt Johnston <matt@ucc.asn.au>
parents:
144
diff
changeset
|
9 VPATH=@srcdir@ |
c2b93763dac9
Fixes for it to compile and work nicely with Dropbear.
Matt Johnston <matt@ucc.asn.au>
parents:
144
diff
changeset
|
10 srcdir=@srcdir@ |
c2b93763dac9
Fixes for it to compile and work nicely with Dropbear.
Matt Johnston <matt@ucc.asn.au>
parents:
144
diff
changeset
|
11 |
138 | 12 # Compiler and Linker Names |
13 #CC=gcc | |
14 #LD=ld | |
15 | |
16 # Archiver [makes .a files] | |
17 #AR=ar | |
18 #ARFLAGS=r | |
19 | |
20 # Compilation flags. Note the += does not write over the user's CFLAGS! | |
21 # The rest of the flags come from the parent Dropbear makefile | |
22 CFLAGS += -c -I$(srcdir) | |
23 # -Werror | |
24 | |
25 # optimize for SPEED | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
26 #CFLAGS += -O3 -funroll-all-loops |
138 | 27 |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
28 #add -fomit-frame-pointer. hinders debugging! |
138 | 29 #CFLAGS += -fomit-frame-pointer |
30 | |
31 # optimize for SIZE | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
32 #CFLAGS += -Os -DSMALL_CODE |
138 | 33 |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
34 # compile for DEBUGING (required for ccmalloc checking!!!) |
138 | 35 #CFLAGS += -g3 |
36 | |
37 #These flags control how the library gets built. | |
38 | |
39 #Output filenames for various targets. | |
40 LIBNAME=libtomcrypt.a | |
41 HASH=hashsum | |
42 CRYPT=encrypt | |
43 SMALL=small | |
44 PROF=x86_prof | |
45 TV=tv_gen | |
46 | |
47 #LIBPATH-The directory for libtomcrypt to be installed to. | |
48 #INCPATH-The directory to install the header files for libtomcrypt. | |
49 #DATAPATH-The directory to install the pdf docs. | |
50 DESTDIR= | |
51 LIBPATH=/usr/lib | |
52 INCPATH=/usr/include | |
53 DATAPATH=/usr/share/doc/libtomcrypt/pdf | |
54 | |
55 #List of objects to compile. | |
56 | |
57 #Leave MPI built-in or force developer to link against libtommath? | |
58 #MPIOBJECT=mpi.o | |
59 #Dropbear uses libtommath | |
60 MPIOBJECT= | |
61 | |
62 OBJECTS=error_to_string.o mpi_to_ltc_error.o base64_encode.o base64_decode.o \ | |
63 \ | |
64 crypt.o crypt_find_cipher.o crypt_find_hash_any.o \ | |
65 crypt_hash_is_valid.o crypt_register_hash.o crypt_unregister_prng.o \ | |
66 crypt_argchk.o crypt_find_cipher_any.o crypt_find_hash_id.o \ | |
67 crypt_prng_descriptor.o crypt_register_prng.o crypt_cipher_descriptor.o \ | |
68 crypt_find_cipher_id.o crypt_find_prng.o crypt_prng_is_valid.o \ | |
69 crypt_unregister_cipher.o crypt_cipher_is_valid.o crypt_find_hash.o \ | |
70 crypt_hash_descriptor.o crypt_register_cipher.o crypt_unregister_hash.o \ | |
71 \ | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
72 sober128.o fortuna.o sprng.o yarrow.o rc4.o rng_get_bytes.o rng_make_prng.o \ |
138 | 73 \ |
74 rand_prime.o is_prime.o \ | |
75 \ | |
76 ecc.o dh.o \ | |
77 \ | |
78 rsa_decrypt_key.o rsa_encrypt_key.o rsa_exptmod.o rsa_free.o rsa_make_key.o \ | |
79 rsa_sign_hash.o rsa_verify_hash.o rsa_export.o rsa_import.o tim_exptmod.o \ | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
80 rsa_v15_encrypt_key.o rsa_v15_decrypt_key.o rsa_v15_sign_hash.o rsa_v15_verify_hash.o \ |
138 | 81 \ |
82 dsa_export.o dsa_free.o dsa_import.o dsa_make_key.o dsa_sign_hash.o \ | |
83 dsa_verify_hash.o dsa_verify_key.o \ | |
84 \ | |
85 aes.o aes_enc.o \ | |
86 \ | |
87 blowfish.o des.o safer_tab.o safer.o saferp.o rc2.o xtea.o \ | |
88 rc6.o rc5.o cast5.o noekeon.o twofish.o skipjack.o \ | |
89 \ | |
90 md2.o md4.o md5.o sha1.o sha256.o sha512.o tiger.o whirl.o \ | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
91 rmd128.o rmd160.o chc.o \ |
138 | 92 \ |
93 packet_store_header.o packet_valid_header.o \ | |
94 \ | |
95 eax_addheader.o eax_decrypt.o eax_decrypt_verify_memory.o eax_done.o eax_encrypt.o \ | |
96 eax_encrypt_authenticate_memory.o eax_init.o eax_test.o \ | |
97 \ | |
98 ocb_decrypt.o ocb_decrypt_verify_memory.o ocb_done_decrypt.o ocb_done_encrypt.o \ | |
99 ocb_encrypt.o ocb_encrypt_authenticate_memory.o ocb_init.o ocb_ntz.o \ | |
100 ocb_shift_xor.o ocb_test.o s_ocb_done.o \ | |
101 \ | |
102 omac_done.o omac_file.o omac_init.o omac_memory.o omac_process.o omac_test.o \ | |
103 \ | |
104 pmac_done.o pmac_file.o pmac_init.o pmac_memory.o pmac_ntz.o pmac_process.o \ | |
105 pmac_shift_xor.o pmac_test.o \ | |
106 \ | |
107 cbc_start.o cbc_encrypt.o cbc_decrypt.o cbc_getiv.o cbc_setiv.o \ | |
108 cfb_start.o cfb_encrypt.o cfb_decrypt.o cfb_getiv.o cfb_setiv.o \ | |
109 ofb_start.o ofb_encrypt.o ofb_decrypt.o ofb_getiv.o ofb_setiv.o \ | |
110 ctr_start.o ctr_encrypt.o ctr_decrypt.o ctr_getiv.o ctr_setiv.o \ | |
111 ecb_start.o ecb_encrypt.o ecb_decrypt.o \ | |
112 \ | |
113 hash_file.o hash_filehandle.o hash_memory.o \ | |
114 \ | |
115 hmac_done.o hmac_file.o hmac_init.o hmac_memory.o hmac_process.o hmac_test.o \ | |
116 \ | |
117 burn_stack.o zeromem.o \ | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
118 \ |
138 | 119 $(MPIOBJECT) |
120 | |
121 TESTOBJECTS=demos/test.o | |
122 HASHOBJECTS=demos/hashsum.o | |
123 CRYPTOBJECTS=demos/encrypt.o | |
124 SMALLOBJECTS=demos/small.o | |
125 PROFS=demos/x86_prof.o | |
126 TVS=demos/tv_gen.o | |
127 | |
128 #Files left over from making the crypt.pdf. | |
129 LEFTOVERS=*.dvi *.log *.aux *.toc *.idx *.ilg *.ind *.out | |
130 | |
131 #Compressed filenames | |
132 COMPRESSED=crypt-$(VERSION).tar.bz2 crypt-$(VERSION).zip | |
133 | |
134 #Header files used by libtomcrypt. | |
135 HEADERS=ltc_tommath.h mycrypt_cfg.h \ | |
136 mycrypt_misc.h mycrypt_prng.h mycrypt_cipher.h mycrypt_hash.h \ | |
137 mycrypt_macros.h mycrypt_pk.h mycrypt.h mycrypt_argchk.h \ | |
138 mycrypt_custom.h mycrypt_pkcs.h | |
139 | |
140 #The default rule for make builds the libtomcrypt library. | |
141 default:library | |
142 | |
143 #ciphers come in two flavours... enc+dec and enc | |
144 aes_enc.o: aes.c aes_tab.c | |
145 $(CC) $(CFLAGS) -DENCRYPT_ONLY -c $(srcdir)/aes.c -o aes_enc.o | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
146 |
138 | 147 #These are the rules to make certain object files. |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
148 aes.o: aes.c aes_tab.c |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
149 twofish.o: twofish.c twofish_tab.c |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
150 whirl.o: whirl.c whirltab.c |
138 | 151 ecc.o: ecc.c ecc_sys.c |
152 dh.o: dh.c dh_sys.c | |
153 sha512.o: sha512.c sha384.c | |
154 sha256.o: sha256.c sha224.c | |
155 | |
156 #This rule makes the libtomcrypt library. | |
157 library: $(LIBNAME) | |
158 | |
159 $(LIBNAME): $(OBJECTS) | |
160 $(AR) $(ARFLAGS) $@ $(OBJECTS) | |
161 $(RANLIB) $@ | |
162 | |
163 #This rule makes the hash program included with libtomcrypt | |
164 hashsum: library $(HASHOBJECTS) | |
165 $(CC) $(HASHOBJECTS) $(LIBNAME) -o $(HASH) $(WARN) | |
166 | |
167 #makes the crypt program | |
168 crypt: library $(CRYPTOBJECTS) | |
169 $(CC) $(CRYPTOBJECTS) $(LIBNAME) -o $(CRYPT) $(WARN) | |
170 | |
171 #makes the small program | |
172 small: library $(SMALLOBJECTS) | |
173 $(CC) $(SMALLOBJECTS) $(LIBNAME) -o $(SMALL) $(WARN) | |
174 | |
175 x86_prof: library $(PROFS) | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
176 $(CC) $(PROFS) $(LIBNAME) $(EXTRALIBS) -o $(PROF) |
138 | 177 |
178 tv_gen: library $(TVS) | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
179 $(CC) $(TVS) $(LIBNAME) $(EXTRALIBS) -o $(TV) |
138 | 180 |
181 #This rule installs the library and the header files. This must be run | |
182 #as root in order to have a high enough permission to write to the correct | |
183 #directories and to set the owner and group to root. | |
184 install: library docs | |
185 install -d -g root -o root $(DESTDIR)$(LIBPATH) | |
186 install -d -g root -o root $(DESTDIR)$(INCPATH) | |
187 install -d -g root -o root $(DESTDIR)$(DATAPATH) | |
188 install -g root -o root $(LIBNAME) $(DESTDIR)$(LIBPATH) | |
189 install -g root -o root $(HEADERS) $(DESTDIR)$(INCPATH) | |
190 install -g root -o root doc/crypt.pdf $(DESTDIR)$(DATAPATH) | |
191 | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
192 install_lib: library |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
193 install -d -g root -o root $(DESTDIR)$(LIBPATH) |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
194 install -d -g root -o root $(DESTDIR)$(INCPATH) |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
195 install -g root -o root $(LIBNAME) $(DESTDIR)$(LIBPATH) |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
196 install -g root -o root $(HEADERS) $(DESTDIR)$(INCPATH) |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
197 |
138 | 198 #This rule cleans the source tree of all compiled code, not including the pdf |
199 #documentation. | |
200 clean: | |
201 -rm -f $(OBJECTS) $(TESTOBJECTS) $(HASHOBJECTS) $(CRYPTOBJECTS) $(SMALLOBJECTS) $(LEFTOVERS) $(LIBNAME) | |
202 -rm -f $(TEST) $(HASH) $(COMPRESSED) $(PROFS) $(PROF) $(TVS) $(TV) | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
203 -rm -f *.la *.lo *.o *.a *.dll *stackdump *.lib *.exe *.obj demos/*.obj demos/*.o *.bat *.txt *.il *.da demos/*.il demos/*.da *.dyn *.dpi \ |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
204 *.gcda *.gcno demos/*.gcno demos/*.gcda *~ doc/* |
138 | 205 -cd demos/test && make clean |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
206 -rm -rf .libs demos/.libs demos/test/.libs |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
207 |
138 | 208 #This builds the crypt.pdf file. Note that the rm -f *.pdf has been removed |
209 #from the clean command! This is because most people would like to keep the | |
210 #nice pre-compiled crypt.pdf that comes with libtomcrypt! We only need to | |
211 #delete it if we are rebuilding it. | |
212 docs: crypt.tex | |
213 -rm -f doc/crypt.pdf $(LEFTOVERS) | |
214 echo "hello" > crypt.ind | |
215 latex crypt > /dev/null | |
216 latex crypt > /dev/null | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
217 makeindex crypt.idx > /dev/null |
138 | 218 latex crypt > /dev/null |
219 dvipdf crypt | |
220 mv -ivf crypt.pdf doc/crypt.pdf | |
221 -rm -f $(LEFTOVERS) | |
222 | |
223 docdvi: crypt.tex | |
224 echo hello > crypt.ind | |
225 latex crypt > /dev/null | |
226 latex crypt > /dev/null | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
227 makeindex crypt.idx |
138 | 228 latex crypt > /dev/null |
229 | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
230 #pretty build |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
231 pretty: |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
232 perl pretty.build |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
233 |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
234 #for GCC 3.4+ |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
235 profiled: |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
236 make clean |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
237 make CFLAGS="$(CFLAGS) -fprofile-generate" EXTRALIBS=-lgcov x86_prof |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
238 ./x86_prof |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
239 rm *.o *.a x86_prof |
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
240 make CFLAGS="$(CFLAGS) -fprofile-use" EXTRALIBS=-lgcov x86_prof |
138 | 241 |
242 #zipup the project (take that!) | |
243 zipup: clean docs | |
244 cd .. ; rm -rf crypt* libtomcrypt-$(VERSION) ; mkdir libtomcrypt-$(VERSION) ; \ | |
245 cp -R ./libtomcrypt/* ./libtomcrypt-$(VERSION)/ ; tar -c libtomcrypt-$(VERSION)/* > crypt-$(VERSION).tar ; \ | |
246 bzip2 -9vv crypt-$(VERSION).tar ; zip -9 -r crypt-$(VERSION).zip libtomcrypt-$(VERSION)/* ; \ | |
144
7ed585a2c53b
propagate of 3f8f752126017cbe7d93c4086c27a91550df745f and 747ebf284d40a15b338e5a5c7730ecec6eade3d7 from branch 'au.asn.ucc.matt.ltc-orig' to 'au.asn.ucc.matt.ltc-db'
Matt Johnston <matt@ucc.asn.au>
parents:
138
diff
changeset
|
247 gpg -b -a crypt-$(VERSION).tar.bz2 ; gpg -b -a crypt-$(VERSION).zip |