[FFmpeg-cvslog] configure: use ar and ranlib in deterministic mode if available

Andreas Cadhalpun git at videolan.org
Tue Jan 27 01:34:37 CET 2015


ffmpeg | branch: master | Andreas Cadhalpun <Andreas.Cadhalpun at googlemail.com> | Mon Jan 26 23:50:29 2015 +0100| [f8716d1e56d5019d070b30692d144c30a18fcf23] | committer: Michael Niedermayer

configure: use ar and ranlib in deterministic mode if available

this makes the static libraries binary reproducible

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun at googlemail.com>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f8716d1e56d5019d070b30692d144c30a18fcf23
---

 configure |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/configure b/configure
index 9fcdaee..c684d23 100755
--- a/configure
+++ b/configure
@@ -2702,7 +2702,11 @@ ln_s="ln -s -f"
 nm_default="nm -g"
 objformat="elf"
 pkg_config_default=pkg-config
-ranlib_default="ranlib"
+if ranlib 2>&1 | grep -q "\-D "; then
+    ranlib_default="ranlib -D"
+else
+    ranlib_default="ranlib"
+fi
 strip_default="strip"
 yasmexe_default="yasm"
 windres_default="windres"
@@ -3600,6 +3604,9 @@ elif $ar 2>&1 | grep -q 'Texas Instruments'; then
 elif $ar 2>&1 | grep -q 'Usage: ar.*-X.*any'; then
     arflags='-Xany -r -c'
     ar_o='$@'
+elif $ar 2>&1 | grep -q "\[D\] "; then
+    arflags="rcD"
+    ar_o='$@'
 else
     arflags="rc"
     ar_o='$@'



More information about the ffmpeg-cvslog mailing list