OLD | NEW |
1 # Makefile for secure rtp | 1 # Makefile for secure rtp |
2 # | 2 # |
3 # David A. McGrew | 3 # David A. McGrew |
4 # Cisco Systems, Inc. | 4 # Cisco Systems, Inc. |
5 | 5 |
6 # targets: | 6 # targets: |
7 # | 7 # |
8 # runtest runs test applications | 8 # runtest runs test applications |
9 # test builds test applications | 9 # test builds test applications |
10 # libcrypt.a static library implementing crypto engine | 10 # libcrypt.a static library implementing crypto engine |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
195 | 195 |
196 test/srtp_driver$(EXE): test/srtp_driver.c test/getopt_s.c | 196 test/srtp_driver$(EXE): test/srtp_driver.c test/getopt_s.c |
197 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) | 197 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
198 | 198 |
199 test/rdbx_driver$(EXE): test/rdbx_driver.c test/getopt_s.c | 199 test/rdbx_driver$(EXE): test/rdbx_driver.c test/getopt_s.c |
200 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) | 200 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
201 | 201 |
202 test/dtls_srtp_driver$(EXE): test/dtls_srtp_driver.c test/getopt_s.c | 202 test/dtls_srtp_driver$(EXE): test/dtls_srtp_driver.c test/getopt_s.c |
203 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) | 203 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
204 | 204 |
| 205 crypto/test/cipher_driver$(EXE): crypto/test/cipher_driver.c test/getopt_s.c |
| 206 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
| 207 |
| 208 crypto/test/kernel_driver$(EXE): crypto/test/kernel_driver.c test/getopt_s.c |
| 209 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
| 210 |
| 211 crypto/test/rand_gen$(EXE): crypto/test/rand_gen.c test/getopt_s.c |
| 212 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
| 213 |
| 214 crypto/test/rand_gen_soak$(EXE): crypto/test/rand_gen_soak.c test/getopt_s.c |
| 215 $(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB) |
| 216 |
205 test: $(testapp) | 217 test: $(testapp) |
206 @echo "Build done. Please run '$(MAKE) runtest' to run self tests." | 218 @echo "Build done. Please run '$(MAKE) runtest' to run self tests." |
207 | 219 |
208 memtest: test/srtp_driver | 220 memtest: test/srtp_driver |
209 @test/srtp_driver -v -d "alloc" > tmp | 221 @test/srtp_driver -v -d "alloc" > tmp |
210 @grep freed tmp | wc -l > freed | 222 @grep freed tmp | wc -l > freed |
211 @grep allocated tmp | wc -l > allocated | 223 @grep allocated tmp | wc -l > allocated |
212 @echo "checking for memory leaks (only works with --enable-stdout)" | 224 @echo "checking for memory leaks (only works with --enable-stdout)" |
213 cmp -s allocated freed | 225 cmp -s allocated freed |
214 @echo "passed (same number of alloc() and dealloc() calls found)" | 226 @echo "passed (same number of alloc() and dealloc() calls found)" |
(...skipping 30 matching lines...) Expand all Loading... |
245 # libsrtp | 257 # libsrtp |
246 | 258 |
247 libsrtpdoc: | 259 libsrtpdoc: |
248 $(MAKE) -C doc | 260 $(MAKE) -C doc |
249 | 261 |
250 .PHONY: clean superclean distclean install | 262 .PHONY: clean superclean distclean install |
251 | 263 |
252 install: | 264 install: |
253 $(INSTALL) -d $(DESTDIR)$(includedir)/srtp | 265 $(INSTALL) -d $(DESTDIR)$(includedir)/srtp |
254 $(INSTALL) -d $(DESTDIR)$(libdir) | 266 $(INSTALL) -d $(DESTDIR)$(libdir) |
255 $(INSTALL) -d $(DESTDIR)$(bindir) | |
256 cp $(srcdir)/include/*.h $(DESTDIR)$(includedir)/srtp | 267 cp $(srcdir)/include/*.h $(DESTDIR)$(includedir)/srtp |
257 cp $(srcdir)/crypto/include/*.h $(DESTDIR)$(includedir)/srtp | 268 cp $(srcdir)/crypto/include/*.h $(DESTDIR)$(includedir)/srtp |
258 if [ "$(srcdir)" != "." ]; then cp crypto/include/*.h $(DESTDIR)$(includ
edir)/srtp; fi | 269 if [ "$(srcdir)" != "." ]; then cp crypto/include/*.h $(DESTDIR)$(includ
edir)/srtp; fi |
259 if [ -f libsrtp.a ]; then cp libsrtp.a $(DESTDIR)$(libdir)/; fi | 270 if [ -f libsrtp.a ]; then cp libsrtp.a $(DESTDIR)$(libdir)/; fi |
260 if [ -f libsrtp.dll.a ]; then cp libsrtp.dll.a $(DESTDIR)$(libdir)/; fi | 271 if [ -f libsrtp.dll.a ]; then cp libsrtp.dll.a $(DESTDIR)$(libdir)/; fi |
261 if [ -f libsrtp.$(SHAREDLIBSUFFIX) ]; then \ | 272 if [ -f libsrtp.$(SHAREDLIBSUFFIX) ]; then \ |
| 273 $(INSTALL) -d $(DESTDIR)$(SHAREDLIB_DIR); \ |
262 cp libsrtp.$(SHAREDLIBSUFFIX) $(DESTDIR)$(SHAREDLIB_DIR)/; \ | 274 cp libsrtp.$(SHAREDLIBSUFFIX) $(DESTDIR)$(SHAREDLIB_DIR)/; \ |
263 » » cp libsrtp.$(SHAREDLIBSUFFIXNOVER) $(DESTDIR)$(SHAREDLIB_DIR)/;
\ | 275 » » ln -sfn libsrtp.$(SHAREDLIBSUFFIX) $(DESTDIR)$(SHAREDLIB_DIR)/li
bsrtp.$(SHAREDLIBSUFFIXNOVER); \ |
264 fi | 276 fi |
265 if [ "$(pkgconfig_DATA)" != "" ]; then \ | 277 if [ "$(pkgconfig_DATA)" != "" ]; then \ |
266 $(INSTALL) -d $(DESTDIR)$(pkgconfigdir); \ | 278 $(INSTALL) -d $(DESTDIR)$(pkgconfigdir); \ |
267 cp $(top_builddir)/$(pkgconfig_DATA) $(DESTDIR)$(pkgconfigdir)/;
\ | 279 cp $(top_builddir)/$(pkgconfig_DATA) $(DESTDIR)$(pkgconfigdir)/;
\ |
268 fi | 280 fi |
269 | 281 |
270 uninstall: | 282 uninstall: |
271 rm -f $(DESTDIR)$(includedir)/srtp/*.h | 283 rm -f $(DESTDIR)$(includedir)/srtp/*.h |
272 rm -f $(DESTDIR)$(libdir)/libsrtp.* | 284 rm -f $(DESTDIR)$(libdir)/libsrtp.* |
273 -rmdir $(DESTDIR)$(includedir)/srtp | 285 -rmdir $(DESTDIR)$(includedir)/srtp |
(...skipping 25 matching lines...) Expand all Loading... |
299 distname = libsrtp-$(shell cat VERSION) | 311 distname = libsrtp-$(shell cat VERSION) |
300 | 312 |
301 distribution: runtest superclean | 313 distribution: runtest superclean |
302 if ! [ -f VERSION ]; then exit 1; fi | 314 if ! [ -f VERSION ]; then exit 1; fi |
303 if [ -f ../$(distname).tgz ]; then \ | 315 if [ -f ../$(distname).tgz ]; then \ |
304 mv ../$(distname).tgz ../$(distname).tgz.bak; \ | 316 mv ../$(distname).tgz ../$(distname).tgz.bak; \ |
305 fi | 317 fi |
306 cd ..; tar cvzf $(distname).tgz libsrtp | 318 cd ..; tar cvzf $(distname).tgz libsrtp |
307 | 319 |
308 # EOF | 320 # EOF |
OLD | NEW |