[netcdf] 01/01: Add patch to use SOURCE_DATE_EPOCH instead of current date.
Sebastiaan Couwenberg
sebastic at moszumanska.debian.org
Tue May 17 04:35:46 UTC 2016
This is an automated email from the git hooks/post-receive script.
sebastic pushed a commit to branch master
in repository netcdf.
commit 8140f53a3e78de53b487f2f01b9571ceee8b77d9
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date: Sun May 15 17:05:58 2016 +0200
Add patch to use SOURCE_DATE_EPOCH instead of current date.
---
debian/changelog | 6 +++++
debian/patches/series | 1 +
debian/patches/source_date_epoch.patch | 44 ++++++++++++++++++++++++++++++++++
3 files changed, 51 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 190243b..e643686 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+netcdf (1:4.4.1~rc2-1~exp3) UNRELEASED; urgency=medium
+
+ * Add patch to use SOURCE_DATE_EPOCH instead of current date.
+
+ -- Bas Couwenberg <sebastic at debian.org> Sun, 15 May 2016 17:05:23 +0200
+
netcdf (1:4.4.1~rc2-1~exp2) experimental; urgency=medium
* Drop SOVERSION patch, SONAME bump in RC1 was not required.
diff --git a/debian/patches/series b/debian/patches/series
index dac6fb5..f3bf16c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@ link-private.patch
privacy-breach-logo.patch
hdf5-library-path.patch
tst_fileinfo-link-hdf5.patch
+source_date_epoch.patch
diff --git a/debian/patches/source_date_epoch.patch b/debian/patches/source_date_epoch.patch
new file mode 100644
index 0000000..857a914
--- /dev/null
+++ b/debian/patches/source_date_epoch.patch
@@ -0,0 +1,44 @@
+Description: Use SOURCE_DATE_EPOCH instead of current date.
+Author: Bas Couwenberg <sebastic at debian.org>
+Forwarded: https://github.com/Unidata/netcdf-c/pull/263
+Applied-Upstream: https://github.com/Unidata/netcdf-c/commit/aa8f23c5bbed9892a65f27fb8854e649f4ed1c1f
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -124,10 +124,17 @@ STRING(TOUPPER ${CMAKE_BUILD_TYPE} CMAKE
+
+ # Determine the configure date.
+
+-EXECUTE_PROCESS(
+- COMMAND date
+- OUTPUT_VARIABLE CONFIG_DATE
+- )
++IF(DEFINED ENV{SOURCE_DATE_EPOCH})
++ EXECUTE_PROCESS(
++ COMMAND "date" "-u" "-d" "@$ENV{SOURCE_DATE_EPOCH}"
++ OUTPUT_VARIABLE CONFIG_DATE
++ )
++ELSE()
++ EXECUTE_PROCESS(
++ COMMAND date
++ OUTPUT_VARIABLE CONFIG_DATE
++ )
++ENDIF()
+ IF(CONFIG_DATE)
+ string(STRIP ${CONFIG_DATE} CONFIG_DATE)
+ ENDIF()
+--- a/configure.ac
++++ b/configure.ac
+@@ -45,7 +45,11 @@ AC_MSG_NOTICE([netCDF AC_PACKAGE_VERSION
+ AC_CONFIG_MACRO_DIR([m4])
+
+ # Configuration Date
+-AC_SUBST([CONFIG_DATE]) CONFIG_DATE="`date`"
++if test -n ${SOURCE_DATE_EPOCH}; then
++ AC_SUBST([CONFIG_DATE]) CONFIG_DATE="`date -u -d "@${SOURCE_DATE_EPOCH}"`"
++else
++ AC_SUBST([CONFIG_DATE]) CONFIG_DATE="`date`"
++fi
+
+ # Find out about the host we're building on.
+ AC_CANONICAL_HOST
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/netcdf.git
More information about the Pkg-grass-devel
mailing list