[packages/fio] - updated to 2.2.7 - removed outdated makefile patch - dropped crc32c-intel patch; too much effort i

qboosh qboosh at pld-linux.org
Fri Apr 24 18:27:33 CEST 2015


commit bc626f258c9a17f48fabc667cf4a86af355dd3c6
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Fri Apr 24 18:29:41 2015 +0200

    - updated to 2.2.7
    - removed outdated makefile patch
    - dropped crc32c-intel patch; too much effort in porting it, just exclude i[34]86 until sb needs it

 fio-crc32c-intel.patch | 58 ---------------------------------
 fio-makefile.patch     | 11 -------
 fio.spec               | 87 ++++++++++++++++++++++++++++++++++++++++++--------
 3 files changed, 74 insertions(+), 82 deletions(-)
---
diff --git a/fio.spec b/fio.spec
index 506b297..6968355 100644
--- a/fio.spec
+++ b/fio.spec
@@ -1,16 +1,39 @@
+# TODO: HDFS (--enable-libhdfs, requires also java), guasi, fusion-aw (nvm-primitives)
+#
+# Conditional build:
+%bcond_without	ceph		# RDB (CephFS) support
+%bcond_without	glusterfs	# GFAPI support
+%bcond_without	gtk		# GTK+ based GUI (gfio)
+%bcond_without	numa		# NUMA support
+#
 Summary:	I/O tool for benchmark and stress/hardware verification
 Summary(pl.UTF-8):	Narzędzie do mierzenia wydajności I/O i sprawdzania sprawności sprzętu
 Name:		fio
-Version:	2.0.3
+Version:	2.2.7
 Release:	1
 License:	GPL v2+
-Group:		Applications
+Group:		Applications/System
 Source0:	http://brick.kernel.dk/snaps/%{name}-%{version}.tar.bz2
-# Source0-md5:	e3b878ab0a4cba072d99e222d86287ed
-Patch0:		%{name}-makefile.patch
-Patch1:		%{name}-crc32c-intel.patch
+# Source0-md5:	0c30299c4e37cd3ae9657c2e4a363092
 URL:		http://git.kernel.dk/?p=fio.git;a=summary
+BuildRequires:	bison
+%{?with_ceph:BuildRequires:	ceph-devel}
+BuildRequires:	flex
+%{?with_glusterfs:BuildRequires:	glusterfs-devel}
 BuildRequires:	libaio-devel
+BuildRequires:	libibverbs-devel
+BuildRequires:	librdmacm-devel
+BuildRequires:	numactl-devel
+BuildRequires:	sed >= 4.0
+BuildRequires:	zlib-devel
+%if %{with gtk}
+BuildRequires:	cairo-devel
+BuildRequires:	glib2-devel >= 2.0
+BuildRequires:	gtk+2-devel >= 2:2.18.0
+BuildRequires:	pkgconfig
+%endif
+# x86 features detection relies on cpuid
+ExcludeArch:	i386 i486
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -36,15 +59,38 @@ załączone kilka przykładowych plików zadań. Wyświetla wszystkie
 rodzaje informacji o wydajności I/O. Obsługuje Linuksa, FreeBSD i
 OpenSolarisa.
 
+%package -n gfio
+Summary:	GTK+ based graphical front-end for fio
+Summary(pl.UTF-8):	Oparty na GTK+ graficzny interfejs do fio
+Group:		X11/Applications
+Requires:	%{name} = %{version}-%{release}
+
+%description -n gfio
+gfio is a GTK+ based graphical front-end for fio. It is often
+installed on the testers workstation whereas fio would be installed on
+the server.
+
+%description -n gfio -l pl.UTF-8
+gfio to oparty na GTK+ graficzny interfejs do fio. Zwykle jest
+instalowany na komputerze testerów, podczas gdy fio jest zainstalowany
+na serwerze.
+
 %prep
 %setup -q
-%patch0 -p1
-%patch1 -p1
+
+%{__sed} -i -e '1s,/usr/bin/env bash,/bin/bash,' tools/genfio
+%{__sed} -i -e '1s,/usr/bin/env python,/usr/bin/python,' tools/plot/fio2gnuplot
 
 %build
+./configure \
+	--cc="%{__cc}" \
+	--extra-cflags="%{rpmcflags} %{rpmcppflags}" \
+	%{!?with_glusterfs:--enable-gfapi} \
+	%{?with_gtk:--enable-gfio} \
+	%{!?with_numa:--disable-numa} \
+	%{!?with_ceph:--disable-rdb} \
+
 %{__make} \
-	CC="%{__cc}" \
-	OPTFLAGS="%{rpmcflags} %{rpmcppflags}" \
 	LDFLAGS="%{rpmldflags}" \
 	V=1
 
@@ -61,7 +107,22 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%doc HOWTO README
-%doc examples
-%attr(755,root,root) %{_bindir}/*
-%{_mandir}/man1/fio*.1*
+%doc HOWTO MORAL-LICENSE README REPORTING-BUGS SERVER-TODO examples
+%attr(755,root,root) %{_bindir}/fio
+%attr(755,root,root) %{_bindir}/fio-btrace2fio
+%attr(755,root,root) %{_bindir}/fio-dedupe
+%attr(755,root,root) %{_bindir}/fio-genzipf
+%attr(755,root,root) %{_bindir}/fio2gnuplot
+%attr(755,root,root) %{_bindir}/fio_generate_plots
+%attr(755,root,root) %{_bindir}/genfio
+%{_datadir}/fio
+%{_mandir}/man1/fio.1*
+%{_mandir}/man1/fio2gnuplot.1*
+%{_mandir}/man1/fio_generate_plots.1*
+
+%if %{with gtk}
+%files -n gfio
+%defattr(644,root,root,755)
+%doc GFIO-TODO
+%attr(755,root,root) %{_bindir}/gfio
+%endif
diff --git a/fio-crc32c-intel.patch b/fio-crc32c-intel.patch
deleted file mode 100644
index b2b29d9..0000000
--- a/fio-crc32c-intel.patch
+++ /dev/null
@@ -1,58 +0,0 @@
---- fio-1.41.6/crc/crc32c-intel.c	2010-07-09 13:48:14.000000000 +0200
-+++ fio-1.41.4/crc/crc32c-intel.c	2010-06-24 10:39:02.000000000 +0200
-@@ -74,30 +74,37 @@
- 	return crc;
- }
- 
--static void do_cpuid(unsigned int *eax, unsigned int *ebx, unsigned int *ecx,
--		     unsigned int *edx)
-+static void sig_ill(int sig)
- {
--	int id = *eax;
--
--	asm("movl %4, %%eax;"
--	    "cpuid;"
--	    "movl %%eax, %0;"
--	    "movl %%ebx, %1;"
--	    "movl %%ecx, %2;"
--	    "movl %%edx, %3;"
--		: "=r" (*eax), "=r" (*ebx), "=r" (*ecx), "=r" (*edx)
--		: "r" (id)
--		: "eax", "ebx", "ecx", "edx");
- }
- 
--int crc32c_intel_works(void)
-+static void crc32c_test(void)
- {
--	unsigned int eax, ebx, ecx, edx;
-+	unsigned char buf[4] = { 1, 2, 3, 4 };
-+	struct sigaction act;
-+
-+	/*
-+	 * Check if hw accelerated crc32c is available
-+	 */
-+	memset(&act, 0, sizeof(act));
-+	act.sa_handler = sig_ill;
-+	act.sa_flags = SA_RESETHAND;
-+	sigaction(SIGILL, &act, NULL);
- 
--	eax = 1;
-+	(void) crc32c_intel(buf, sizeof(buf));
-+}
- 
--	do_cpuid(&eax, &ebx, &ecx, &edx);
--	return (ecx & (1 << 20)) != 0;
-+int crc32c_intel_works(void)
-+{
-+	if (!fork()) {
-+		crc32c_test();
-+		exit(0);
-+	} else {
-+		int status;
-+
-+		wait(&status);
-+		return !WIFSIGNALED(status);
-+	}
- }
- 
- #endif /* ARCH_HAVE_SSE */
diff --git a/fio-makefile.patch b/fio-makefile.patch
deleted file mode 100644
index f089d1c..0000000
--- a/fio-makefile.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- fio-1.60/Makefile~	2011-10-13 16:33:51.000000000 +0200
-+++ fio-1.60/Makefile	2011-10-18 08:56:00.789652095 +0200
-@@ -2,7 +2,7 @@
- DEBUGFLAGS = -D_FORTIFY_SOURCE=2 -DFIO_INC_DEBUG
- CPPFLAGS= -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 \
- 	$(DEBUGFLAGS)
--OPTFLAGS= -O3 -fno-omit-frame-pointer -g $(EXTFLAGS)
-+OPTFLAGS= $(EXTFLAGS)
- CFLAGS	= -std=gnu99 -Wwrite-strings -Wall $(OPTFLAGS)
- LIBS	= -lm $(EXTLIBS)
- PROGS	= fio
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/fio.git/commitdiff/bc626f258c9a17f48fabc667cf4a86af355dd3c6



More information about the pld-cvs-commit mailing list