summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2012-09-12 06:24:13 +0000
committerJustin Lecher <jlec@gentoo.org>2012-09-12 06:24:13 +0000
commitfc770e9c5d1133e9597189785ef295be964fe569 (patch)
tree56cecb1a1f53ddcae36344c24c5f1cdc51163902 /app-benchmarks/i7z
parentEnable prefix support; bug #430090, thanks to Christoph Junghans and Gilles ... (diff)
downloadgentoo-2-fc770e9c5d1133e9597189785ef295be964fe569.tar.gz
gentoo-2-fc770e9c5d1133e9597189785ef295be964fe569.tar.bz2
gentoo-2-fc770e9c5d1133e9597189785ef295be964fe569.zip
app-benchmarks/i7z: Version Bump, drop old patches
(Portage version: 2.2.0_alpha125/cvs/Linux x86_64)
Diffstat (limited to 'app-benchmarks/i7z')
-rw-r--r--app-benchmarks/i7z/ChangeLog9
-rw-r--r--app-benchmarks/i7z/files/0.26-gcc46.patch19
-rw-r--r--app-benchmarks/i7z/files/0.26-gentoo.patch56
-rw-r--r--app-benchmarks/i7z/files/0.27-gentoo.patch56
-rw-r--r--app-benchmarks/i7z/files/i7z-0.27-cpuid.patch127
-rw-r--r--app-benchmarks/i7z/i7z-0.27.2.ebuild42
6 files changed, 50 insertions, 259 deletions
diff --git a/app-benchmarks/i7z/ChangeLog b/app-benchmarks/i7z/ChangeLog
index 0395e0c07a61..a9bd55340d20 100644
--- a/app-benchmarks/i7z/ChangeLog
+++ b/app-benchmarks/i7z/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for app-benchmarks/i7z
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-benchmarks/i7z/ChangeLog,v 1.13 2012/06/08 12:53:04 jlec Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-benchmarks/i7z/ChangeLog,v 1.14 2012/09/12 06:24:13 jlec Exp $
+
+*i7z-0.27.2 (12 Sep 2012)
+
+ 12 Sep 2012; Justin Lecher <jlec@gentoo.org> -files/0.26-gcc46.patch,
+ -files/i7z-0.27-cpuid.patch, -files/0.26-gentoo.patch, +i7z-0.27.2.ebuild,
+ -files/0.27-gentoo.patch:
+ Version Bump, drop old patches
08 Jun 2012; Justin Lecher <jlec@gentoo.org> -i7z-0.27-r1.ebuild:
Cleaned old
diff --git a/app-benchmarks/i7z/files/0.26-gcc46.patch b/app-benchmarks/i7z/files/0.26-gcc46.patch
deleted file mode 100644
index 08ad216566b4..000000000000
--- a/app-benchmarks/i7z/files/0.26-gcc46.patch
+++ /dev/null
@@ -1,19 +0,0 @@
---- /tmp/GUI_i7z-50.cpp
-+++ i7z/GUI/GUI_i7z.cpp
-@@ -48,10 +48,14 @@
- void Construct_Socket_Information_in_GUI(unsigned int *numCPUs) {
- socket_0.max_cpu=0;
- socket_0.socket_num=0;
-- socket_0.processor_num={-1,-1,-1,-1,-1,-1,-1,-1};
-+ int i;
-+ for(i=0;i < 8; i++)
-+ socket_0.processor_num[i]=-1;
- socket_1.max_cpu=0;
- socket_1.socket_num=1;
-- socket_1.processor_num={-1,-1,-1,-1,-1,-1,-1,-1};
-+
-+ for(i=0;i < 8; i++)
-+ socket_1.processor_num[i]=-1;
-
- construct_CPU_Heirarchy_info(&chi);
- construct_sibling_list(&chi);
diff --git a/app-benchmarks/i7z/files/0.26-gentoo.patch b/app-benchmarks/i7z/files/0.26-gentoo.patch
deleted file mode 100644
index 345fe505f80c..000000000000
--- a/app-benchmarks/i7z/files/0.26-gentoo.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-diff --git a/Makefile b/Makefile
-index fc4d262..e2347bf 100644
---- a/Makefile
-+++ b/Makefile
-@@ -17,18 +17,18 @@
-
- #makefile updated from patch by anestling
-
--CFLAGSANY = -g -O0 -fomit-frame-pointer -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -DBUILD_MAIN -Wall
-+CFLAGS += -O0 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -DBUILD_MAIN -Wall
-
- LBITS := $(shell getconf LONG_BIT)
- ifeq ($(LBITS),64)
-- CFLAGS = $(CFLAGSANY) -Dx64_BIT
-+ CFLAGS += -Dx64_BIT
- else
-- CFLAGS = $(CFLAGSANY) -Dx86
-+ CFLAGS += -Dx86
- endif
-
--CC = gcc
-+CC ?= gcc
-
--LDFLAGS = -lncurses -lpthread
-+LIBS = -lncurses -lpthread
- INCLUDEFLAGS =
-
- OBJS = helper_functions
-@@ -36,15 +36,15 @@ OBJS = helper_functions
- BIN = i7z
- SRC = i7z.c helper_functions.c i7z_Single_Socket.c i7z_Dual_Socket.c
-
--sbindir = /usr/sbin
-+sbindir = $(DESTDIR)/usr/sbin
-
--all: clean message bin
-+all: clean bin
-
- message:
- @echo "If the compilation complains about not finding ncurses.h, install ncurses (libncurses5-dev on ubuntu/debian)"
-
- bin:
-- $(CC) $(CFLAGS) $(LDFLAGS) $(INCLUDEFLAGS) $(SRC) -o $(BIN)
-+ $(CC) $(CFLAGS) $(LDFLAGS) $(INCLUDEFLAGS) $(SRC) -o $(BIN) $(LIBS)
-
- clean:
- rm -f *.o $(BIN)
-@@ -52,6 +52,6 @@ clean:
- distclean: clean
- rm -f *~ \#*
-
--install: all
-- install -m 755 $(BIN) $(sbindir)
-+install:
-+ install -D -m 755 $(BIN) $(sbindir)/$(BIN)
-
diff --git a/app-benchmarks/i7z/files/0.27-gentoo.patch b/app-benchmarks/i7z/files/0.27-gentoo.patch
deleted file mode 100644
index fe65a16caf9c..000000000000
--- a/app-benchmarks/i7z/files/0.27-gentoo.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-diff --git a/Makefile b/Makefile
-index fc4d262..e2347bf 100644
---- a/Makefile
-+++ b/Makefile
-@@ -17,18 +17,18 @@
-
- #makefile updated from patch by anestling
-
--CFLAGSANY = -g -O0 -fomit-frame-pointer -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -DBUILD_MAIN -Wall
-+CFLAGS += -O0 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -DBUILD_MAIN -Wall
-
- LBITS := $(shell getconf LONG_BIT)
- ifeq ($(LBITS),64)
-- CFLAGS = $(CFLAGSANY) -Dx64_BIT
-+ CFLAGS += -Dx64_BIT
- else
-- CFLAGS = $(CFLAGSANY) -Dx86
-+ CFLAGS += -Dx86
- endif
-
--CC = gcc
-+CC ?= gcc
-
--LDFLAGS = -lncurses -lpthread -lrt
-+LIBS = -lncurses -lpthread -lrt
- INCLUDEFLAGS =
-
- OBJS = helper_functions
-@@ -36,15 +36,15 @@ OBJS = helper_functions
- BIN = i7z
- SRC = i7z.c helper_functions.c i7z_Single_Socket.c i7z_Dual_Socket.c
-
--sbindir = /usr/sbin
-+sbindir = $(DESTDIR)/usr/sbin
-
--all: clean message bin
-+all: clean bin
-
- message:
- @echo "If the compilation complains about not finding ncurses.h, install ncurses (libncurses5-dev on ubuntu/debian)"
-
- bin:
-- $(CC) $(CFLAGS) $(LDFLAGS) $(INCLUDEFLAGS) $(SRC) -o $(BIN)
-+ $(CC) $(CFLAGS) $(LDFLAGS) $(INCLUDEFLAGS) $(SRC) -o $(BIN) $(LIBS)
-
- clean:
- rm -f *.o $(BIN)
-@@ -52,6 +52,6 @@ clean:
- distclean: clean
- rm -f *~ \#*
-
--install: all
-- install -m 755 $(BIN) $(sbindir)
-+install:
-+ install -D -m 755 $(BIN) $(sbindir)/$(BIN)
-
diff --git a/app-benchmarks/i7z/files/i7z-0.27-cpuid.patch b/app-benchmarks/i7z/files/i7z-0.27-cpuid.patch
deleted file mode 100644
index 16b5a097234f..000000000000
--- a/app-benchmarks/i7z/files/i7z-0.27-cpuid.patch
+++ /dev/null
@@ -1,127 +0,0 @@
-http://code.google.com/p/i7z/issues/detail?id=31
-
-this makes cpuid work on 32bit and 64bit systems, both PIC and non-PIC
-
-the things it fixes:
- - no more silent clobbering of ebx/ecx/edx
- - works under 32bit pic builds (gcc doesnt like to clobber ebx)
- - ebx gets saved/restored via edi register
- - get_vendor incorrectly used ebx,ecx,edx when it should be ebx,edx,ecx
- - unify all the cpuid implementations to make usage much simpler
-
-I WROTE THIS
-
---- a/helper_functions.c
-+++ b/helper_functions.c
-@@ -87,41 +87,40 @@ print_family_info (struct family_info *proc_info)
- // printf(" Extended Family %d\n", proc_info->extended_family);
- }
-
-+static inline void cpuid (unsigned int info, unsigned int *eax, unsigned int *ebx,
-+ unsigned int *ecx, unsigned int *edx)
-+{
-+ unsigned int _eax = info, _ebx, _ecx, _edx;
-+ asm volatile ("mov %%ebx, %%edi;" // save ebx (for PIC)
-+ "cpuid;"
-+ "mov %%ebx, %%esi;" // pass to caller
-+ "mov %%edi, %%ebx;" // restore ebx
-+ :"+a" (_eax), "=S" (_ebx), "=c" (_ecx), "=d" (_edx)
-+ : /* inputs: eax is handled above */
-+ :"edi" /* clobbers: we hit edi directly */);
-+ if (eax) *eax = _eax;
-+ if (ebx) *ebx = _ebx;
-+ if (ecx) *ecx = _ecx;
-+ if (edx) *edx = _edx;
-+}
-
--#ifdef x64_BIT
- void get_vendor (char *vendor_string)
- {
- //get vendor name
-- unsigned int b, c, d, e;
-- // int i;
-- asm volatile ("mov %4, %%eax; " // 0 into eax
-- "cpuid;" "mov %%eax, %0;" // eeax into b
-- "mov %%ebx, %1;" // eebx into c
-- "mov %%edx, %2;" // eeax into d
-- "mov %%ecx, %3;" // eeax into e
-- :"=r" (b), "=r" (c), "=r" (d), "=r" (e) /* output */
-- :"r" (0) /* input */
-- :"%eax", "%ebx", "%ecx", "%edx" /* clobbered register, will be modifying inside the asm routine so dont use them */
-- );
-- memcpy (vendor_string, &c, 4);
-+ unsigned int a, b, c, d;
-+ cpuid (0, &a, &b, &c, &d);
-+ memcpy (vendor_string, &b, 4);
- memcpy (vendor_string + 4, &d, 4);
-- memcpy (vendor_string + 8, &e, 4);
-+ memcpy (vendor_string + 8, &c, 4);
- vendor_string[12] = '\0';
- // printf("Vendor %s\n",vendor_string);
- }
--#endif
-
- int turbo_status ()
- {
- //turbo state flag
- unsigned int eax;
-- // int i;
-- asm volatile ("mov %1, %%eax; " // 0 into eax
-- "cpuid;" "mov %%eax, %0;" // eeax into b
-- :"=r" (eax) /* output */
-- :"r" (6) /* input */
-- :"%eax" /* clobbered register, will be modifying inside the asm routine so dont use them */
-- );
-+ cpuid (6, &eax, NULL, NULL, NULL);
-
- //printf("eax %d\n",(eax&0x2)>>1);
-
-@@ -132,12 +131,7 @@ void get_familyinformation (struct family_info *proc_info)
- {
- //get info about CPU
- unsigned int b;
-- asm volatile ("mov %1, %%eax; " // 0 into eax
-- "cpuid;" "mov %%eax, %0;" // eeax into b
-- :"=r" (b) /* output */
-- :"r" (1) /* input */
-- :"%eax" /* clobbered register, will be modifying inside the asm routine so dont use them */
-- );
-+ cpuid (1, &b, NULL, NULL, NULL);
- // printf ("eax %x\n", b);
- proc_info->stepping = b & 0x0000000F; //bits 3:0
- proc_info->model = (b & 0x000000F0) >> 4; //bits 7:4
-@@ -348,7 +342,6 @@ void Print_Information_Processor(bool* nehalem, bool* sandy_bridge)
- {
- struct family_info proc_info;
-
--#ifdef x64_BIT
- char vendor_string[13];
- get_vendor (vendor_string);
- if (strcmp (vendor_string, "GenuineIntel") == 0)
-@@ -359,14 +352,6 @@ void Print_Information_Processor(bool* nehalem, bool* sandy_bridge)
- ("this was designed to be a intel proc utility. You can perhaps mod it for your machine?\n");
- exit (1);
- }
--#endif
--
--#ifndef x64_BIT
-- //anecdotal evidence: get_vendor doesnt seem to work on 32-bit
-- printf
-- ("I dont know the CPUID code to check on 32-bit OS, so i will assume that you have an Intel processor\n");
-- printf ("Don't worry if i don't find a nehalem next, i'll quit anyways\n");
--#endif
-
- get_familyinformation (&proc_info);
- print_family_info (&proc_info);
---- a/i7z.h
-+++ b/i7z.h
-@@ -106,9 +106,7 @@ __asm__ __volatile__ ("rdtsc":"=a" (lo), "=d" (hi));
-
- void print_family_info (struct family_info *proc_info);
-
--#ifdef x64_BIT
- void get_vendor (char *vendor_string);
--#endif
-
- int turbo_status ();
- double cpufreq_info();
diff --git a/app-benchmarks/i7z/i7z-0.27.2.ebuild b/app-benchmarks/i7z/i7z-0.27.2.ebuild
new file mode 100644
index 000000000000..01af82e2e5f7
--- /dev/null
+++ b/app-benchmarks/i7z/i7z-0.27.2.ebuild
@@ -0,0 +1,42 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-benchmarks/i7z/i7z-0.27.2.ebuild,v 1.1 2012/09/12 06:24:13 jlec Exp $
+
+EAPI=4
+
+inherit eutils flag-o-matic qt4-r2 toolchain-funcs
+
+DESCRIPTION="A better i7 (and now i3, i5) reporting tool for Linux"
+HOMEPAGE="http://code.google.com/p/i7z/"
+SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="X"
+
+RDEPEND="
+ sys-libs/ncurses
+ X? ( x11-libs/qt-gui:4 )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ tc-export CC
+}
+
+src_compile() {
+ default
+ if use X; then
+ cd GUI
+ eqmake4 ${PN}_GUI.pro
+ emake clean && emake
+ fi
+}
+
+src_install() {
+ emake DESTDIR="${ED}" install
+ if use X; then
+ dosbin GUI/i7z_GUI
+ fi
+ dodoc put_cores_o*line.sh MAKEDEV-cpuid-msr
+}