File reproducible-qrc-time.patch of Package libqt5-qtbase

commit aa0241031c93086737d82d5c3e917a8816a77fc4
Author: Bernhard M. Wiedemann <bwiedemann@suse.de>
Date:   Wed Jul 11 10:05:55 2018 +0200

    Use SOURCE_DATE_EPOCH
    
    Use the standard variable name in addition to the QT-specific one
    to make builds reproducible out-of-the-box
    
    Change-Id: I401a2a9d258e751b83ae7b83f4100d9088b9ad71

diff --git a/src/tools/rcc/rcc.cpp b/src/tools/rcc/rcc.cpp
index 1a7cab01df..26fc3efea2 100644
--- a/src/tools/rcc/rcc.cpp
+++ b/src/tools/rcc/rcc.cpp
@@ -211,6 +211,9 @@ void RCCFileInfo::writeDataInfo(RCCResourceLibrary &lib)
         static const quint64 sourceDate = 1000 * qgetenv("QT_RCC_SOURCE_DATE_OVERRIDE").toULongLong();
         if (sourceDate != 0)
             lastmod = sourceDate;
+        static const quint64 sourceDate2 = 1000 * qgetenv("SOURCE_DATE_EPOCH").toULongLong();
+        if (sourceDate2 != 0)
+            lastmod = sourceDate2;
         lib.writeNumber8(lastmod);
         if (text || pass1)
             lib.writeChar('\n');

openSUSE Build Service is sponsored by