[Matroska-devel] [Patches] Portability, support for CloudABI, etc.

Ed Schouten ed at nuxi.nl
Wed Nov 18 22:44:33 CET 2015


2015-11-18 21:42 GMT+01:00 Ed Schouten <ed at nuxi.nl>:
> Here are already some patches to unexpose the build date string from
> libebml and libmatroska. We need to retain the declaration to suppress
> warnings ( -Wmissing-variable-declarations).

And of course I overlooked that libmatroska uses libebml's build date
string. Attached is an updated diff.

-- 
Ed Schouten <ed at nuxi.nl>
Nuxi, 's-Hertogenbosch, the Netherlands
KvK-nr.: 62051717
-------------- next part --------------
diff --git a/matroska/KaxVersion.h b/matroska/KaxVersion.h
index e98f687..d99c1e8 100644
--- a/matroska/KaxVersion.h
+++ b/matroska/KaxVersion.h
@@ -43,7 +43,6 @@ START_LIBMATROSKA_NAMESPACE
 #define LIBMATROSKA_VERSION 0x010404
 
 extern const std::string KaxCodeVersion;
-extern const std::string KaxCodeDate;
 
 /*!
   \todo Improve the CRC/ECC system (backward and forward possible ?) to fit streaming/live writing/simple reading
diff --git a/src/KaxVersion.cpp b/src/KaxVersion.cpp
index edc99dc..b2ba93a 100644
--- a/src/KaxVersion.cpp
+++ b/src/KaxVersion.cpp
@@ -38,6 +38,11 @@
 START_LIBMATROSKA_NAMESPACE
 
 const std::string KaxCodeVersion = "1.4.4";
-const std::string KaxCodeDate    = __TIMESTAMP__;
+
+// Up to version 1.4.4 this library exported a build date string. As
+// this made the build non-reproducible, replace it by a placeholder to
+// remain binary compatible.
+extern const std::string KaxCodeDate;
+const std::string KaxCodeDate = "Unknown";
 
 END_LIBMATROSKA_NAMESPACE
diff --git a/test/ebml/test00.cpp b/test/ebml/test00.cpp
index a0b5a86..d33a32f 100644
--- a/test/ebml/test00.cpp
+++ b/test/ebml/test00.cpp
@@ -65,7 +65,7 @@ const char RW_FILENAME[] = "test.kax";
 */
 int main(void)
 {
-  printf("Test00 :\nEBML %s %s / Matroska %s %s\n", EbmlCodeVersion.c_str(), EbmlCodeDate.c_str(), KaxCodeVersion.c_str(), KaxCodeDate.c_str());
+  printf("Test00 :\nEBML %s / Matroska %s\n", EbmlCodeVersion.c_str(), KaxCodeVersion.c_str());
   StdIOCallback Ebml_file(RW_FILENAME, ::MODE_CREATE);
 
   ///// Writing test


More information about the Matroska-devel mailing list