commit e7bdd38e2c597ca81ada1d67bed92a4f86a17805
Author: Elan Ruusamäe <[email protected]>
Date:   Wed Jan 23 23:21:39 2013 +0200

    update pci.ids path (if exists, so it could update it)
    
    no changes, actually, it used inexistent path as well until now
    
    also misc fixes:
    - fix executable perms for shared libs
    - build with our optflags where possible
    - use our cc

 hardinfo.spec | 22 +++++++++++++++++-----
 hwdata.patch  | 13 +++++++++++++
 2 files changed, 30 insertions(+), 5 deletions(-)
---
diff --git a/hardinfo.spec b/hardinfo.spec
index 93ac730..367941b 100644
--- a/hardinfo.spec
+++ b/hardinfo.spec
@@ -2,16 +2,18 @@ Summary:      Hardinfo - benchmark tool
 Summary(pl.UTF-8):     Hardinfo - narzędzie informujące o sprzęcie i jego 
wydajności
 Name:          hardinfo
 Version:       0.5.1
-Release:       1
+Release:       2
 License:       GPL v2
 Group:         X11/Applications
 Source0:       http://download.berlios.de/hardinfo/%{name}-%{version}.tar.bz2
 # Source0-md5: 6fb38992e140f2fab16518ae1f38e188
 URL:           http://hardinfo.berlios.de/web/HomePage
+Patch0:                hwdata.patch
 BuildRequires: gtk+2-devel >= 2:2.6.0
 BuildRequires: libsoup-devel >= 2.2.104-2
 BuildRequires: pciutils
 BuildRequires: pkgconfig
+BuildRequires: sed >= 4.0
 Requires:      pciutils
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -19,7 +21,7 @@ BuildRoot:    %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 HardInfo is a system information and benchmark tool for Linux systems.
 This tool can gather information about your system's hardware and
 operating system, perform benchmarks and generate printable reports
-either in HTML or in plain text formats. 
+either in HTML or in plain text formats.
 
 %description -l pl.UTF-8
 HardInfo to narzędzie dla systemów linuksowych informujące o systemie
@@ -29,14 +31,20 @@ druku raporty w formacie HTML lub czystym tekście.
 
 %prep
 %setup -q
+%patch0 -p1
+
+# XXX: code requires -O0 here
+%{__sed} -i -re '/(md5|sha1)\.c/ s/-c/-O0 -c/' Makefile.in
 
 %build
 %configure
-%{__make}
+%{__make} \
+       CCFLAGS="%{rpmcflags} -fPIC" \
+       CC="%{__cc} %{rpmldflags}" \
+       CCSLOW="%{__cc} %{rpmldflags}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
-
 %{__make} install \
        DESTDIR=$RPM_BUILD_ROOT
 
@@ -47,6 +55,10 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/hardinfo
 %dir %{_libdir}/hardinfo
-%{_libdir}/hardinfo/*
+%dir %{_libdir}/hardinfo/modules
+%attr(755,root,root) %{_libdir}/hardinfo/modules/benchmark.so
+%attr(755,root,root) %{_libdir}/hardinfo/modules/computer.so
+%attr(755,root,root) %{_libdir}/hardinfo/modules/devices.so
+%attr(755,root,root) %{_libdir}/hardinfo/modules/network.so
 %{_datadir}/hardinfo
 %{_desktopdir}/hardinfo.desktop
diff --git a/hwdata.patch b/hwdata.patch
new file mode 100644
index 0000000..152fb9d
--- /dev/null
+++ b/hwdata.patch
@@ -0,0 +1,13 @@
+--- hardinfo-0.5.1/devices.c~  2009-04-06 16:43:15.000000000 +0300
++++ hardinfo-0.5.1/devices.c   2013-01-23 23:12:38.859124115 +0200
+@@ -423,7 +423,9 @@
+ 
+ void hi_module_init(void)
+ {
+-    if (!g_file_test("/usr/share/misc/pci.ids", G_FILE_TEST_EXISTS)) {
++    // probably they don't have SOAP entry for gz compressed action
++    // but URL exists for that: http://pci-ids.ucw.cz/v2.2/pci.ids.gz
++    if (!g_file_test("/lib/hwdata/pci.ids", G_FILE_TEST_EXISTS)) {
+         static SyncEntry se = {
+              .fancy_name = "Update PCI ID listing",
+              .name = "GetPCIIds",
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/hardinfo.git/commitdiff/e7bdd38e2c597ca81ada1d67bed92a4f86a17805

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to