MozillaFirefox/MozillaFirefox.spec
changeset 276 c9f36db0c1ca
parent 272 adc2b9141ad5
child 277 37db3d6540b8
--- a/MozillaFirefox/MozillaFirefox.spec	Thu May 19 08:07:57 2011 +0200
+++ b/MozillaFirefox/MozillaFirefox.spec	Sun May 29 13:23:11 2011 +0200
@@ -102,7 +102,7 @@
 %define desktop_file_name %{name}
 %endif
 ### build options
-%define branding 0
+%define branding 1
 %define localize 1
 %ifarch ppc ppc64 s390 s390x ia64
 %define crashreporter    0
@@ -220,6 +220,12 @@
 %patch41 -p1
 
 %build
+# no need to add build time to binaries
+modified="$(sed -n '/^----/n;s/ - .*$//;p;q' "%{_sourcedir}/%{name}.changes")"
+DATE="\"$(date -d "${modified}" "+%%b %%e %%Y")\""
+TIME="\"$(date -d "${modified}" "+%%R")\""
+find . -regex ".*\.c\|.*\.cpp\|.*\.h" -exec sed -i "s/__DATE__/${DATE}/g;s/__TIME__/${TIME}/g" {} +
+#
 kdehelperversion=$(cat toolkit/xre/nsKDEUtils.cpp | grep '#define KMOZILLAHELPER_VERSION' | cut -d ' ' -f 3)
 if test "$kdehelperversion" != %{kde_helper_version}; then
   echo fix kde helper version in the .spec file