[packages/cacti-spine] - fix building on x32 - rel 2

baggins baggins at pld-linux.org
Mon Apr 6 23:32:12 CEST 2015


commit 83b2035c4222baf05a24ed5dce9c44220f9b9ad5
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Mon Apr 6 21:31:52 2015 +0000

    - fix building on x32
    - rel 2

 cacti-spine.spec |  6 +++++-
 x32.patch        | 31 +++++++++++++++++++++++++++++++
 2 files changed, 36 insertions(+), 1 deletion(-)
---
diff --git a/cacti-spine.spec b/cacti-spine.spec
index 75406f8..97e3a33 100644
--- a/cacti-spine.spec
+++ b/cacti-spine.spec
@@ -2,12 +2,13 @@ Summary:	A backend data gatherer for Cacti
 Summary(pl.UTF-8):	Backend gromadzący dane dla Cacti
 Name:		cacti-spine
 Version:	0.8.8c
-Release:	1
+Release:	2
 License:	GPL
 Group:		Daemons
 Source0:	http://www.cacti.net/downloads/spine/%{name}-%{version}.tar.gz
 # Source0-md5:	448c813422f943dc09b237bd8022002a
 Patch0:		%{name}-paths.patch
+Patch1:		x32.patch
 # Official patches http://www.cacti.net/spine_download_patches.php
 URL:		http://www.cacti.net/
 BuildRequires:	autoconf
@@ -42,6 +43,9 @@ procesorem cmd.php.
 %prep
 %setup -q
 %patch0 -p1
+%ifarch x32
+%patch1 -p1
+%endif
 
 %build
 %{__libtoolize}
diff --git a/x32.patch b/x32.patch
new file mode 100644
index 0000000..1be2390
--- /dev/null
+++ b/x32.patch
@@ -0,0 +1,31 @@
+--- cacti-spine-0.8.8c/configure.ac~	2014-11-17 06:14:05.000000000 +0000
++++ cacti-spine-0.8.8c/configure.ac	2015-04-06 21:30:05.950921974 +0000
+@@ -226,6 +226,8 @@
+ fi
+ 
+ for i in $MYSQL_DIR /usr /usr/local /opt /opt/mysql /usr/pkg /usr/local/mysql; do
++  MYSQL_LIB_CHK($i/libx32)
++  MYSQL_LIB_CHK($i/libx32/mysql)
+   MYSQL_LIB_CHK($i/lib64)
+   MYSQL_LIB_CHK($i/lib64/mysql)
+   MYSQL_LIB_CHK($i/lib)
+@@ -257,6 +259,8 @@
+     test -f $SNMP_DIR/$i/net-snmp-config.h  && SNMP_INCDIR=$SNMP_DIR$i && break
+   done
+ 
++  test -f $SNMP_DIR/libx32/libsnmp.a -o -f $SNMP_DIR/libx32/libsnmp.$ShLib       && SNMP_LIBDIR=$SNMP_DIR/libx32
++  test -f $SNMP_DIR/libx32/libnetsnmp.a -o -f $SNMP_DIR/libx32/libnetsnmp.$ShLib && SNMP_LIBDIR=$SNMP_DIR/libx32
+   # Accomodate 64-Bit Libraries
+   test -f $SNMP_DIR/lib64/libsnmp.a -o -f $SNMP_DIR/lib64/libsnmp.$ShLib       && SNMP_LIBDIR=$SNMP_DIR/lib64
+   test -f $SNMP_DIR/lib64/libnetsnmp.a -o -f $SNMP_DIR/lib64/libnetsnmp.$ShLib && SNMP_LIBDIR=$SNMP_DIR/lib64
+@@ -278,6 +282,10 @@
+     test -f $i/snmp/include/net-snmp/net-snmp-config.h && SNMP_INCDIR=$i/snmp/include/net-snmp && break
+   done
+ 
++  for i in /usr /usr/local /usr/pkg /usr/snmp /opt /opt/net-snmp /opt/ucd-snmp /opt/snmp /usr/local/snmp; do
++    test -f $i/libx32/libsnmp.a -o -f $i/libx32/libsnmp.$ShLib       && SNMP_LIBDIR=$i/libx32 && break
++    test -f $i/libx32/libnetsnmp.a -o -f $i/libx32/libnetsnmp.$ShLib && SNMP_LIBDIR=$i/libx32 && break
++  done
+   # Accomodate 64-Bit Libraries
+   for i in /usr /usr/local /usr/pkg /usr/snmp /opt /opt/net-snmp /opt/ucd-snmp /opt/snmp /usr/local/snmp; do
+     test -f $i/lib64/libsnmp.a -o -f $i/lib64/libsnmp.$ShLib       && SNMP_LIBDIR=$i/lib64 && break
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/cacti-spine.git/commitdiff/83b2035c4222baf05a24ed5dce9c44220f9b9ad5



More information about the pld-cvs-commit mailing list