# Note: GNUmakefile is built automatically from GNUmakefile.in
#
-# $Id: GNUmakefile.in,v 1.259 2017/05/04 14:35:02 fabiankeil Exp $
+# $Id: GNUmakefile.in,v 1.260 2017/05/20 09:27:07 fabiankeil Exp $
#
# Written by and Copyright (C) 2001-2017 members of the
# Privoxy team. https://www.privoxy.org/
VERSION = $(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_POINT)
SNAPVERSION = $(VERSION)-$(shell date "+%Y%m%d")
+SOURCE_DATE_EPOCH = @SOURCE_DATE_EPOCH@
+MTREE_SPEC_FILE = privoxy-$(VERSION)-$(CODE_STATUS).spec
#############################################################################
# "make install" directories and variables
$(GZIP_PROG) ../privoxy-$(VERSION)-$(CODE_STATUS)-src.tar
@$(ECHO) Tarball distribution created.
+# Create a mtree spec file that can be used to get a reproducible tar ball
+mtree-spec:
+ $(LN) -s `pwd` ../privoxy-$(VERSION)-$(CODE_STATUS)
+ $(ECHO) "#mtree 2.0" > $(MTREE_SPEC_FILE)
+ for i in `find . -type f -a -not \( -path "*/CVS*" -o -name ".*" \
+ -o -path "*/debian/*" -o -path "*/actions/*" -o -name "*.php" -o \
+ -name "PACKAGERS" -o -path "*.git/*" -o -name "*.spec" \) | env -i sort`; do \
+ $(ECHO) "privoxy-$(VERSION)-$(CODE_STATUS)/$$i time=$(SOURCE_DATE_EPOCH) type=file uname=privoxy gname=privoxy mode=0555"; \
+ done >> $(MTREE_SPEC_FILE)
+ $(RM) ../privoxy-$(VERSION)-$(CODE_STATUS)
+
+# Create a reproducible tarball.
+# Requires a tar implementation with mtree support.
+reproducible-tarball-dist: dist-check clean clobber mtree-spec
+ $(LN) -s `pwd` ../privoxy-$(VERSION)-$(CODE_STATUS)
+
+ $(TAR) cvhf privoxy-$(VERSION)-$(CODE_STATUS)-src.tar -C .. @privoxy-$(VERSION)-$(CODE_STATUS)/$(MTREE_SPEC_FILE)
+ $(GZIP_PROG) -n privoxy-$(VERSION)-$(CODE_STATUS)-src.tar
+ $(RM) ../privoxy-$(VERSION)-$(CODE_STATUS) $(MTREE_SPEC_FILE)
+ @$(ECHO) Reproducible tarball distribution created.
+
# anonymously ncftps the tarball to sourceforge
tarball-upload:
ncftpput -u anonymous -p ijbswa-developers@lists.sourceforge.net upload.sourceforge.net /incoming ../privoxy-$(VERSION)-$(CODE_STATUS)-src.tar.gz
dnl Process this file with autoconf to produce a configure script.
dnl
-dnl $Id: configure.in,v 1.209 2017/05/04 14:34:18 fabiankeil Exp $
+dnl $Id: configure.in,v 1.210 2017/05/04 14:34:28 fabiankeil Exp $
dnl
dnl Written by and Copyright (C) 2001-2017 the
dnl Privoxy team. https://www.privoxy.org/
dnl AutoConf Initialization
dnl =================================================================
-AC_REVISION($Revision: 1.209 $)
+AC_REVISION($Revision: 1.210 $)
AC_INIT(jcc.c)
if test ! -f config.h.in; then
VERSION_POINT=27
CODE_STATUS="UNRELEASED"
+dnl Timestamp (date +%s) used by the mtree-spec target.
+dnl Should be updated before releases but forgetting it isn't critical.
+SOURCE_DATE_EPOCH=1494070262
+
dnl CODE_STATUS can be "alpha", "beta", "stable" or "UNRELEASED",
dnl and will be used for CGI output. Increment version number and
dnl set status to "UNRELEASED" whenever CVS differs from the last
AC_SUBST(VERSION_MINOR)
AC_SUBST(VERSION_POINT)
AC_SUBST(CODE_STATUS)
+AC_SUBST(SOURCE_DATE_EPOCH)
dnl
AC_DEFINE_UNQUOTED(VERSION_MAJOR,${VERSION_MAJOR})