[libmnl/el5: 2/2] fixes to build for el5

Hushan Jia hushan at fedoraproject.org
Wed Aug 24 16:59:39 UTC 2011


commit de6d7d6a5d01ac919458e7b4b8b191a9311d4ddd
Author: Hushan Jia <hushan.jia at gmail.com>
Date:   Thu Aug 25 00:58:24 2011 +0800

    fixes to build for el5

 libmnl.spec |   15 +++++++++++++--
 1 files changed, 13 insertions(+), 2 deletions(-)
---
diff --git a/libmnl.spec b/libmnl.spec
index 39becee..c787c1c 100644
--- a/libmnl.spec
+++ b/libmnl.spec
@@ -1,12 +1,13 @@
 Name:           libmnl
 Version:        1.0.1
-Release:        4%{?dist}
+Release:        5%{?dist}
 Summary:        A minimalistic Netlink library
 
 Group:          System Environment/Libraries
 License:        LGPLv2+
 URL:            http://netfilter.org/projects/libmnl
 Source0:        http://netfilter.org/projects/libmnl/files/%{name}-%{version}.tar.bz2
+BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 %description
 libmnl is a minimalistic user-space library oriented to Netlink developers.
@@ -19,7 +20,8 @@ to avoid re-inventing the wheel.
 %package        devel
 Summary:        Development files for %{name}
 Group:          Development/Libraries
-Requires:       %{name}%{_isa} = %{version}-%{release}
+Requires:       pkgconfig
+Requires:       %{name}%{?_isa} = %{version}-%{release}
 
 %description    devel
 The %{name}-devel package contains libraries and header files for
@@ -36,22 +38,28 @@ make CFLAGS="%{optflags}" %{?_smp_mflags}
 
 
 %install
+rm -rf $RPM_BUILD_ROOT
 make install DESTDIR=$RPM_BUILD_ROOT
 find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
 find examples '(' -name 'Makefile.am' -o -name 'Makefile.in' ')' -exec rm -f {} ';'
 find examples -type d -name '.deps' -prune -exec rm -rf {} ';'
 
 
+%clean
+rm -rf $RPM_BUILD_ROOT
+
 %post -p /sbin/ldconfig
 
 %postun -p /sbin/ldconfig
 
 
 %files
+%defattr(-,root,root,-)
 %doc COPYING README
 %{_libdir}/*.so.*
 
 %files devel
+%defattr(-,root,root,-)
 %doc COPYING
 %doc examples
 %{_includedir}/*
@@ -60,6 +68,9 @@ find examples -type d -name '.deps' -prune -exec rm -rf {} ';'
 
 
 %changelog
+* Thu Aug 25 2011 Hushan Jia <hushan.jia at gmail.com> 1.0.1-5
+- several changes to build for el5
+
 * Wed Aug 24 2011 Hushan Jia <hushan.jia at gmail.com> 1.0.1-4
 - fix require of devel package
 - add example source files to docs


More information about the scm-commits mailing list