packages: UFconfig/UFconfig-config.patch, UFconfig/UFconfig.spec, UFconfig/...
qboosh
qboosh at pld-linux.org
Mon Jan 9 17:01:39 CET 2012
Author: qboosh Date: Mon Jan 9 16:01:39 2012 GMT
Module: packages Tag: HEAD
---- Log message:
- added INSTALL_{LIB,INCLUDE} adjustment to config patch
- added shared patch
- libufconfig library (-libs/-devel/-static subpackages); basic package still contains just
make macros and header file (still useful without library)
---- Files affected:
packages/UFconfig:
UFconfig-config.patch (1.6 -> 1.7) , UFconfig.spec (1.10 -> 1.11) , UFconfig-shared.patch (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: packages/UFconfig/UFconfig-config.patch
diff -u packages/UFconfig/UFconfig-config.patch:1.6 packages/UFconfig/UFconfig-config.patch:1.7
--- packages/UFconfig/UFconfig-config.patch:1.6 Sun Jan 1 12:02:45 2012
+++ packages/UFconfig/UFconfig-config.patch Mon Jan 9 17:01:33 2012
@@ -1,5 +1,5 @@
---- UFconfig/UFconfig.mk 2008-09-22 20:19:37.000000000 +0200
-+++ UFconfig-dud/UFconfig.mk 2009-01-23 12:25:23.482152935 +0100
+--- UFconfig/UFconfig.mk.orig 2011-12-08 20:19:48.000000000 +0100
++++ UFconfig/UFconfig.mk 2012-01-09 16:20:56.743005449 +0100
@@ -53,7 +53,7 @@
# default make environment.
@@ -9,7 +9,7 @@
# ranlib, and ar, for generating libraries. If you don't need ranlib,
# just change it to RANLAB = echo
-@@ -67,7 +67,7 @@
+@@ -67,15 +67,16 @@
# Fortran compiler (not required for 'make' or 'make library')
F77 = gfortran
@@ -18,7 +18,18 @@
F77LIB =
# C and Fortran libraries
-@@ -148,8 +148,8 @@
+ LIB = -lm
+
+ # For "make install"
+-INSTALL_LIB = /usr/local/lib
+-INSTALL_INCLUDE = /usr/local/include
++INSTALL_PREFIX = /usr
++INSTALL_LIB = $(INSTALL_PREFIX)/lib
++INSTALL_INCLUDE = $(INSTALL_PREFIX)/include
+
+ # For compiling MATLAB mexFunctions (MATLAB 7.5 or later)
+ MEX = mex -O -largeArrayDims -lmwlapack -lmwblas
+@@ -148,8 +149,8 @@
# The path is relative to where it is used, in CHOLMOD/Lib, CHOLMOD/MATLAB, etc.
# You may wish to use an absolute path. METIS is optional. Compile
# CHOLMOD with -DNPARTITION if you do not wish to use METIS.
================================================================
Index: packages/UFconfig/UFconfig.spec
diff -u packages/UFconfig/UFconfig.spec:1.10 packages/UFconfig/UFconfig.spec:1.11
--- packages/UFconfig/UFconfig.spec:1.10 Sat Dec 31 17:56:00 2011
+++ packages/UFconfig/UFconfig.spec Mon Jan 9 17:01:33 2012
@@ -9,6 +9,7 @@
Source0: http://www.cise.ufl.edu/research/sparse/UFconfig/%{name}-%{version}.tar.gz
# Source0-md5: ab8c355d683e8c5597a0824b32704c70
Patch0: %{name}-config.patch
+Patch1: %{name}-shared.patch
URL: http://www.cise.ufl.edu/research/sparse/UFconfig/
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -20,32 +21,103 @@
UFconfig jest wymagany przez prawie wszystkie pakiety do obliczeń na
macierzach rzadkich autorstwa Timothy'ego A. Davisa.
+%package libs
+Summary: UFconfig shared library
+Summary(pl.UTF-8): Biblioteka współdzielona UFconfig
+Group: Libraries
+
+%description libs
+UFconfig shared library, containing malloc/free wrappers.
+
+%description libs -l pl.UTF-8
+Biblioteka współdzielona UFconfig, zawierająca funkcje obudowujące
+malloc/free.
+
+%package devel
+Summary: Development files for UFconfig library
+Summary(pl.UTF-8): Pliki programistyczne biblioteki UFconfig
+Group: Development/Libraries
+Requires: %{name} = %{version}-%{release}
+Requires: %{name}-libs = %{version}-%{release}
+
+%description devel
+Development files for UFconfig library.
+
+%description devel -l pl.UTF-8
+Pliki programistyczne biblioteki UFconfig.
+
+%package static
+Summary: UFconfig static library
+Summary(pl.UTF-8): Biblioteka statyczna UFconfig
+Group: Libraries
+Requires: %{name}-devel = %{version}-%{release}
+
+%description static
+UFconfig static library.
+
+%description static -l pl.UTF-8
+Biblioteka statyczna UFconfig.
+
%prep
%setup -q -n %{name}
%patch0 -p1
+%patch1 -p1
+
+%build
+%{__make} \
+ CC="%{__cc}" \
+ CFLAGS="%{rpmcflags}" \
+ LDFLAGS="%{rpmldflags}" \
+ INSTALL_LIB=%{_libdir}
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_includedir},%{_datadir}/misc}
+install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir},%{_datadir}/misc}
+
+%{__make} install \
+ DESTDIR=$RPM_BUILD_ROOT \
+ INSTALL_LIB=%{_libdir}
-cp -a UFconfig.h $RPM_BUILD_ROOT%{_includedir}
cp -a UFconfig.mk $RPM_BUILD_ROOT%{_datadir}/misc
%clean
rm -rf $RPM_BUILD_ROOT
+%post libs -p /sbin/ldconfig
+%postun libs -p /sbin/ldconfig
+
%files
%defattr(644,root,root,755)
%doc README.txt
%{_includedir}/UFconfig.h
%{_datadir}/misc/UFconfig.mk
+%files libs
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libufconfig.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libufconfig.so.0
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libufconfig.so
+%{_libdir}/libufconfig.la
+
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libufconfig.a
+
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
* %{date} PLD Team <feedback at pld-linux.org>
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.11 2012/01/09 16:01:33 qboosh
+- added INSTALL_{LIB,INCLUDE} adjustment to config patch
+- added shared patch
+- libufconfig library (-libs/-devel/-static subpackages); basic package still contains just
+ make macros and header file (still useful without library)
+
Revision 1.10 2011/12/31 16:56:00 qboosh
- updated to 3.7.0
- updated config patch
================================================================
Index: packages/UFconfig/UFconfig-shared.patch
diff -u /dev/null packages/UFconfig/UFconfig-shared.patch:1.1
--- /dev/null Mon Jan 9 17:01:39 2012
+++ packages/UFconfig/UFconfig-shared.patch Mon Jan 9 17:01:33 2012
@@ -0,0 +1,43 @@
+--- UFconfig/Makefile.orig 2011-12-14 19:09:00.000000000 +0100
++++ UFconfig/Makefile 2012-01-09 16:45:18.549721061 +0100
+@@ -8,15 +8,13 @@
+
+ include UFconfig.mk
+
+-ccode: libufconfig.a
++ccode: libufconfig.la
+
+-all: libufconfig.a
++all: libufconfig.la
+
+-libufconfig.a: UFconfig.c UFconfig.h
+- $(CC) $(CF) -c UFconfig.c
+- $(ARCHIVE) libufconfig.a UFconfig.o
+- $(RANLIB) libufconfig.a
+- - $(RM) UFconfig.o
++libufconfig.la: UFconfig.c UFconfig.h
++ libtool --mode=compile --tag=CC $(CC) $(CF) -c UFconfig.c
++ libtool --mode=link --tag=CC $(CC) $(LDFLAGS) $(CFLAGS) -o libufconfig.la UFconfig.lo -rpath $(INSTALL_LIB)
+
+ distclean: purge
+
+@@ -28,14 +26,12 @@
+
+ # install UFconfig
+ install:
+- $(CP) libufconfig.a $(INSTALL_LIB)/libufconfig.$(VERSION).a
+- ( cd $(INSTALL_LIB) ; ln -sf libufconfig.$(VERSION).a libufconfig.a )
+- $(CP) UFconfig.h $(INSTALL_INCLUDE)
+- chmod 644 $(INSTALL_LIB)/libufconfig*.a
+- chmod 644 $(INSTALL_INCLUDE)/UFconfig.h
++ libtool --mode=install $(CP) libufconfig.la $(DESTDIR)$(INSTALL_LIB)
++ $(CP) UFconfig.h $(DESTDIR)$(INSTALL_INCLUDE)
++ chmod 644 $(DESTDIR)$(INSTALL_INCLUDE)/UFconfig.h
+
+ # uninstall UFconfig
+ uninstall:
+- $(RM) $(INSTALL_LIB)/libufconfig*.a
+- $(RM) $(INSTALL_INCLUDE)/UFconfig.h
++ $(RM) $(DESTDIR)$(INSTALL_LIB)/libufconfig.la $(DESTDIR)$(INSTALL_LIB)/libufconfig.so* $(DESTDIR)$(INSTALL_LIB)/libufconfig.a
++ $(RM) $(DESTDIR)$(INSTALL_INCLUDE)/UFconfig.h
+
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/UFconfig/UFconfig-config.patch?r1=1.6&r2=1.7&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/UFconfig/UFconfig.spec?r1=1.10&r2=1.11&f=u
More information about the pld-cvs-commit
mailing list