take date from spec file
[platform/upstream/elfutils.git] / packaging / elfutils.spec
index 27edee0..f91e3f0 100644 (file)
@@ -117,7 +117,7 @@ to develop applications that require these.
 %setup -q -n elfutils-%{version}
 
 %build
-modified="$(sed -n '/^----/n;s/ - .*$//;p;q' "%{_sourcedir}/%{name}.spec")"
+modified="$(sed -n '/^----/n;s/ - .*$//;p;q' "%{_sourcedir}/%{name}.changed")"
 DATE="\"$(date -d "${modified}" "+%%b %%e %%Y")\""
 TIME="\"$(date -d "${modified}" "+%%R")\""
 find . -type f -regex ".*\.c\|.*\.cpp\|.*\.h" -exec sed -i "s/__DATE__/${DATE}/g;s/__TIME__/${TIME}/g" {} +