From 928182dd9bfdb03819b76791387e2d796eb203c7 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Thu, 3 Sep 2009 14:53:51 +0200 Subject: [PATCH 1/6] New upstream version --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index 00eae0f0ac..3d9c71f677 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +tor (0.2.2.1-alpha-1) experimental; urgency=low + + * New upstream version. + + -- Peter Palfrader Thu, 03 Sep 2009 14:46:17 +0200 + tor (0.2.1.19-1) unstable; urgency=low * New upstream version. From 7dba7dcf718b8e4776c0003c90a8eb2e36428e96 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Thu, 3 Sep 2009 15:07:08 +0200 Subject: [PATCH 2/6] Forward port patches/03_tor_manpage_in_section_8.dpatch --- debian/changelog | 3 ++- debian/patches/03_tor_manpage_in_section_8.dpatch | 7 ++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/debian/changelog b/debian/changelog index 3d9c71f677..f6af5a4e01 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,9 @@ tor (0.2.2.1-alpha-1) experimental; urgency=low * New upstream version. + * Forward port patches/03_tor_manpage_in_section_8.dpatch. - -- Peter Palfrader Thu, 03 Sep 2009 14:46:17 +0200 + -- Peter Palfrader Thu, 03 Sep 2009 15:06:58 +0200 tor (0.2.1.19-1) unstable; urgency=low diff --git a/debian/patches/03_tor_manpage_in_section_8.dpatch b/debian/patches/03_tor_manpage_in_section_8.dpatch index 28bbf957c0..ece1fe67b2 100755 --- a/debian/patches/03_tor_manpage_in_section_8.dpatch +++ b/debian/patches/03_tor_manpage_in_section_8.dpatch @@ -26,20 +26,21 @@ exit 0 diff -urNad tor-0.1.1.5/contrib/torify.1 /tmp/dpep.fOA3Mm/tor-0.1.1.5/contrib/torify.1 --- tor-0.1.1.5/contrib/torify.1 +++ /tmp/dpep.fOA3Mm/tor-0.1.1.5/contrib/torify.1 -@@ -18,6 +18,6 @@ +@@ -35,7 +35,7 @@ to suid binaries. .SH SEE ALSO -.BR tor (1), +.BR tor (8), .BR tor-resolve (1), + .BR torsocks (1), .BR tsocks (1), diff -urNad tor-0.1.1.5/doc/tor.1.in /tmp/dpep.fOA3Mm/tor-0.1.1.5/doc/tor.1.in --- tor-0.1.1.5/doc/tor.1.in +++ /tmp/dpep.fOA3Mm/tor-0.1.1.5/doc/tor.1.in @@ -1,4 +1,4 @@ --.TH TOR 1 "January 2009" "TOR" -+.TH TOR 8 "January 2009" "TOR" +-.TH TOR 1 "August 2009" "TOR" ++.TH TOR 8 "August 2009" "TOR" .SH NAME tor \- The second-generation onion router .SH SYNOPSIS From 2bf59689a223fa026a2d2919f455ce100fe43480 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Thu, 3 Sep 2009 15:10:47 +0200 Subject: [PATCH 3/6] Forward port patches/06_add_compile_time_defaults.dpatch --- debian/changelog | 3 ++- .../06_add_compile_time_defaults.dpatch | 21 ++++++++++--------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/debian/changelog b/debian/changelog index f6af5a4e01..6673fe01b0 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,8 +2,9 @@ tor (0.2.2.1-alpha-1) experimental; urgency=low * New upstream version. * Forward port patches/03_tor_manpage_in_section_8.dpatch. + * Forward port patches/06_add_compile_time_defaults.dpatch. - -- Peter Palfrader Thu, 03 Sep 2009 15:06:58 +0200 + -- Peter Palfrader Thu, 03 Sep 2009 15:10:26 +0200 tor (0.2.1.19-1) unstable; urgency=low diff --git a/debian/patches/06_add_compile_time_defaults.dpatch b/debian/patches/06_add_compile_time_defaults.dpatch index a2472d1db8..e64d4618af 100755 --- a/debian/patches/06_add_compile_time_defaults.dpatch +++ b/debian/patches/06_add_compile_time_defaults.dpatch @@ -23,9 +23,9 @@ esac exit 0 @DPATCH@ -diff -urNad tor-trunk~/src/or/config.c tor-trunk/src/or/config.c ---- tor-trunk~/src/or/config.c 2009-01-18 01:47:33.000000000 +0100 -+++ tor-trunk/src/or/config.c 2009-02-05 00:25:17.614844812 +0100 +diff -urNad tor~/src/or/config.c tor/src/or/config.c +--- tor~/src/or/config.c 2009-09-03 15:05:41.000000000 +0200 ++++ tor/src/or/config.c 2009-09-03 15:09:37.662104166 +0200 @@ -12,6 +12,7 @@ #define CONFIG_PRIVATE @@ -34,16 +34,17 @@ diff -urNad tor-trunk~/src/or/config.c tor-trunk/src/or/config.c #ifdef MS_WINDOWS #include #endif -@@ -711,6 +712,8 @@ - #if defined(HAVE_EVENT_GET_VERSION) && defined(HAVE_EVENT_GET_METHOD) - static void check_libevent_version(const char *m, int server); - #endif +@@ -717,6 +718,9 @@ + static void init_libevent(void); + static int opt_streq(const char *s1, const char *s2); + +static int debian_running_as_debiantor(); +static int debian_config_fix_defaults(); - ++ /** Magic value for or_options_t. */ #define OR_OPTIONS_MAGIC 9090909 -@@ -3917,6 +3920,9 @@ + +@@ -4086,6 +4090,9 @@ char *command_arg = NULL; char *errmsg=NULL; @@ -53,7 +54,7 @@ diff -urNad tor-trunk~/src/or/config.c tor-trunk/src/or/config.c if (argv) { /* first time we're called. save command line args */ backup_argv = argv; backup_argc = argc; -@@ -5307,3 +5313,62 @@ +@@ -5304,3 +5311,62 @@ return 0; } From 20225895a36519139655be056138c0b1eb96f029 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Mon, 21 Sep 2009 13:16:05 +0200 Subject: [PATCH 4/6] New upstream version: 0.2.2.2-alpha --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index 6673fe01b0..77f4ee4347 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +tor (0.2.2.2-alpha-1) experimental; urgency=low + + * New upstream version. + + -- Peter Palfrader Mon, 21 Sep 2009 13:15:36 +0200 + tor (0.2.2.1-alpha-1) experimental; urgency=low * New upstream version. From 06211f2b9027b1a898c6de67468f1c627a281ca3 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Mon, 21 Sep 2009 13:39:40 +0200 Subject: [PATCH 5/6] Remove common_sha1.i and or_sha1.i in clean The files src/common/common_sha1.i src/or/or_sha1.i get changed during the build - they contain the checksums of the individual files that end up in the binary. Of couse changes only end up in the debian diff.gz after building a second time in the same directory. So, remove those files in clean to get both a cleaner diff.gz and idempotent builds. --- debian/changelog | 8 +++++++- debian/rules | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 77f4ee4347..73c63c9815 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,14 @@ tor (0.2.2.2-alpha-1) experimental; urgency=low * New upstream version. + * The files src/common/common_sha1.i src/or/or_sha1.i get changed + during the build - they contain the checksums of the individual + files that end up in the binary. Of couse changes only end up + in the debian diff.gz after building a second time in the same + directory. So, remove those files in clean to get both a cleaner + diff.gz and idempotent builds. - -- Peter Palfrader Mon, 21 Sep 2009 13:15:36 +0200 + -- Peter Palfrader Mon, 21 Sep 2009 13:37:30 +0200 tor (0.2.2.1-alpha-1) experimental; urgency=low diff --git a/debian/rules b/debian/rules index f5aaa95545..5b393484bf 100755 --- a/debian/rules +++ b/debian/rules @@ -129,6 +129,7 @@ clean: unpatch dh_testdir dh_testroot rm -f build-stamp + rm -f src/common/common_sha1.i src/or/or_sha1.i [ ! -f Makefile ] || $(MAKE) distclean From 6332c51f73e3722d899792fa5212befaf28be3b2 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Mon, 21 Sep 2009 14:51:26 +0200 Subject: [PATCH 6/6] Build debian's micro-revision into the binary If we have a debian/micro-revision.i, replace the one in src/or with our copy so that this will be the revision that ends up in the binary. This is an informational only version string, but it'd be kinda nice if it was (more) accurate nonetheless. Of course this won't help if people manually patch around but it's still preferable to claiming we are exactly upstream's source. If we are building directly out of a git tree, update debian/micro-revision.i in the clean target. --- .gitignore | 1 + debian/changelog | 12 +++++++++++- debian/rules | 7 +++++++ 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 9dcf3a4fe6..b7bb31a18e 100644 --- a/.gitignore +++ b/.gitignore @@ -80,6 +80,7 @@ # /debian/ /debian/files +/debian/micro-revision.i /debian/patched /debian/tor /debian/tor.postinst.debhelper diff --git a/debian/changelog b/debian/changelog index 73c63c9815..63fdec103f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -7,8 +7,18 @@ tor (0.2.2.2-alpha-1) experimental; urgency=low in the debian diff.gz after building a second time in the same directory. So, remove those files in clean to get both a cleaner diff.gz and idempotent builds. + * If we have a debian/micro-revision.i, replace the one in src/or + with our copy so that this will be the revision that ends up in + the binary. This is an informational only version string, but + it'd be kinda nice if it was (more) accurate nonetheless. + . + Of course this won't help if people manually patch around but + it's still preferable to claiming we are exactly upstream's source. + . + If we are building directly out of a git tree, update + debian/micro-revision.i in the clean target. - -- Peter Palfrader Mon, 21 Sep 2009 13:37:30 +0200 + -- Peter Palfrader Mon, 21 Sep 2009 14:51:20 +0200 tor (0.2.2.1-alpha-1) experimental; urgency=low diff --git a/debian/rules b/debian/rules index 5b393484bf..0de4103742 100755 --- a/debian/rules +++ b/debian/rules @@ -82,6 +82,7 @@ build: build-stamp build-stamp: config.status dh_testdir + ! [ debian/micro-revision.i ] || cp debian/micro-revision.i src/or/micro-revision.i $(MAKE) @echo @@ -130,9 +131,15 @@ clean: unpatch dh_testroot rm -f build-stamp rm -f src/common/common_sha1.i src/or/or_sha1.i + rm -f src/or/micro-revision.i [ ! -f Makefile ] || $(MAKE) distclean + # Normally the .deb wouldn't ship with a ../.git + if [ -d .git ] && which git >/dev/null; then \ + echo "\"`git rev-parse --short=16 HEAD`\"" > "debian/micro-revision.i" ; \ + fi + dh_clean install: build