1 # Copyright (c) 2001-2004, Roger Dingledine
2 # Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson
3 # Copyright (c) 2007-2011, The Tor Project, Inc.
4 # See LICENSE for licensing information
6 # "foreign" means we don't follow GNU package layout standards
7 # 1.7 means we require automake vesion 1.7
8 AUTOMAKE_OPTIONS = foreign 1.7
10 SUBDIRS = src doc contrib
12 DIST_SUBDIRS = src doc contrib
25 # $(INSTALL) -m 755 -d $(LOCALSTATEDIR)/lib/tor
27 # Allows to override rpmbuild with rpmbuild-md5 from fedora-packager so that
28 # building for EL5 won't fail on https://bugzilla.redhat.com/show_bug.cgi?id=490613
31 # Use automake's dist-gzip target to build the tarball
33 TIMESTAMP=$$(date +"%Y-%m-%d_%H.%M.%S"); \
34 RPM_BUILD_DIR=$$(mktemp -d "/tmp/tor-rpm-build-$$TIMESTAMP-XXXX"); \
35 mkdir -p "$$RPM_BUILD_DIR"/{BUILD,RPMS,SOURCES/"tor-$(VERSION)",SPECS,SRPMS}; \
36 cp -fa "$(distdir).tar.gz" "$$RPM_BUILD_DIR"/SOURCES/; \
37 LIBS=-lrt $(RPMBUILD) -ba --define "_topdir $$RPM_BUILD_DIR" tor.spec; \
38 cp -fa "$$RPM_BUILD_DIR"/SRPMS/* .; \
39 cp -fa "$$RPM_BUILD_DIR"/RPMS/* .; \
40 rm -rf "$$RPM_BUILD_DIR"; \
41 echo "RPM build finished"; \
47 doxygen && cd doc/doxygen/latex && make
52 # Avoid strlcpy.c, strlcat.c, aes.c, OpenBSD_malloc_Linux.c, sha256.c,
53 # eventdns.[hc], tinytest*.[ch]
55 ./contrib/checkSpace.pl -C \
57 src/common/[^asO]*.c \
58 src/common/address.c \
60 src/or/eventdns_tor.h \
64 src/tools/tor-fw-helper/*.[ch]
67 ./contrib/checkOptionDocs.pl
70 ./contrib/checkLogs.pl \
71 src/*/*.[ch] | sort -n
75 @if test -d "$(top_srcdir)/.git" && test -x "`which git 2>&1;true`"; then \
77 (cd "$(top_srcdir)" && git rev-parse --short=16 HEAD); \