2015-04-06 09:29:48 +00:00
committed by Git OBS Bridge
parent af538b4466
commit 603aedd2b2
+9 -1
View File
@@ -23,7 +23,8 @@ Summary: A tool for measuring web server performance
License: GPL-2.0
Group: Productivity/Networking/Web/Utilities
Url: https://github.com/httperf/httperf
Source: ftp://ftp.hpl.hp.com/pub/httperf/httperf-%{version}.tar.gz
Source0: ftp://ftp.hpl.hp.com/pub/httperf/httperf-%{version}.tar.gz
Source1: %{name}.changes
BuildRequires: openssl-devel
BuildRequires: pkg-config
BuildRoot: %{_tmppath}/%{name}-%{version}-build
@@ -35,6 +36,13 @@ workloads and for measuring server performance.
%prep
%setup -q
# replace build date with date from changelog
modified="$(sed -n '/^----/n;s/ - .*$//;p;q' "%{SOURCE1}")"
DATE="\"$(date -d "${modified}" "+%%b %%e %%Y")\""
TIME="\"$(date -d "${modified}" "+%%R")\""
find . -name '*.[ch]' |\
xargs sed -i "s/__DATE__/${DATE}/g;s/__TIME__/${TIME}/g"
%build
%configure