rpms/ufsparse/devel ufsparse.spec,1.12,1.13

Quentin Spencer (qspencer) fedora-extras-commits at redhat.com
Wed Mar 8 15:17:57 UTC 2006


Author: qspencer

Update of /cvs/extras/rpms/ufsparse/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv11030

Modified Files:
	ufsparse.spec 
Log Message:
Disable building CSparse--see comments in %build section.


Index: ufsparse.spec
===================================================================
RCS file: /cvs/extras/rpms/ufsparse/devel/ufsparse.spec,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- ufsparse.spec	7 Mar 2006 18:54:03 -0000	1.12
+++ ufsparse.spec	8 Mar 2006 15:17:56 -0000	1.13
@@ -102,9 +102,13 @@
 %define cholmod_version_major 1
 ### CHOLMOD can also be compiled to use the METIS library, but it is not
 ### used here because its licensing terms exclude it from Fedora Extras.
-### To compile with METIS, change the definition below to
-### CHOLMOD_FLAGS="$RPM_OPT_FLAGS -I%{_includedir}/metis -fPIC"
+### To compile with METIS, define enable_metis as 1 below.
+%define enable_metis 0
+%if "%{?enable_metis}" == "1"
+CHOLMOD_FLAGS="$RPM_OPT_FLAGS -I%{_includedir}/metis -fPIC"
+%else
 CHOLMOD_FLAGS="$RPM_OPT_FLAGS -DNPARTITION -fPIC"
+%endif
 pushd CHOLMOD
   pushd Lib
     make -f Makefile CFLAGS="$CHOLMOD_FLAGS"
@@ -142,10 +146,12 @@
   ln -sf libcolamd.so.%{colamd_version} libcolamd.so
 popd
 
-## Don't install CSparse as the header file name conflicts with
-## CXSparse. CXSparse is a superset of CSparse, with the user needing
-## to link against -lcxsparse rather than -lcsparse. This is an
-## annoyance and not real issue.
+### CXSparse is a superset of CSparse, and the two share common header
+### names, so it does not make sense to build both. CXSparse is built
+### by default, but CSparse can be built instead by defining
+### enable_csparse as 1 below.
+%define enable_csparse 0
+%if "%{?enable_csparse}" == "1"
 %define csparse_version 1.2
 %define csparse_version_major 1
 pushd CSparse
@@ -153,16 +159,17 @@
     make -f Makefile CFLAGS="$RPM_OPT_FLAGS -fPIC" libcsparse.a
     gcc -shared -Wl,-soname,libcsparse.so.%{csparse_version_major} -o libcsparse.so.%{csparse_version} `ls *.o`
     cp *.a *.so* ../../Lib
-#    cp cs.h ../../Include
+    cp cs.h ../../Include
   popd
   mkdir ../Doc/CSparse/
- cp README.txt License.txt lesser.txt ../Doc/CSparse
+  cp README.txt License.txt lesser.txt ../Doc/CSparse
 popd
 pushd Lib
   ln -sf libcsparse.so.%{csparse_version} libcsparse.so.%{csparse_version_major}
   ln -sf libcsparse.so.%{csparse_version} libcsparse.so
 popd
 
+%else
 %define cxsparse_version 1.2
 %define cxsparse_version_major 1
 pushd CXSparse
@@ -179,6 +186,7 @@
   ln -sf libcxsparse.so.%{cxsparse_version} libcxsparse.so.%{cxsparse_version_major}
   ln -sf libcxsparse.so.%{cxsparse_version} libcxsparse.so
 popd
+%endif
 
 %define klu_version 0.7
 %define klu_version_major 0
@@ -274,7 +282,8 @@
 %changelog
 * Tue Mar  7 2006 Quentin Spencer <qspencer at users.sourceforge.net> 1.2-1
 - New release.
-- Build newly added libraries CSparse and CXSparse.
+- Build newly added library CXSparse (but not CSparse--see comments
+  in build section).
 
 * Wed Feb 15 2006 Quentin Spencer <qspencer at users.sourceforge.net> 0.93-2
 - Rebuild for Fedora Extras 5.




More information about the fedora-extras-commits mailing list