SPECS: ipp2p.spec - use %build_kernel_modules and %install_kernel_...
sparky
sparky at pld-linux.org
Thu Nov 23 22:55:56 CET 2006
Author: sparky Date: Thu Nov 23 21:55:56 2006 GMT
Module: SPECS Tag: HEAD
---- Log message:
- use %build_kernel_modules and %install_kernel_modules
- use gcc for linking (we have -Wl, in ldflags)
---- Files affected:
SPECS:
ipp2p.spec (1.49 -> 1.50)
---- Diffs:
================================================================
Index: SPECS/ipp2p.spec
diff -u SPECS/ipp2p.spec:1.49 SPECS/ipp2p.spec:1.50
--- SPECS/ipp2p.spec:1.49 Thu Nov 23 21:14:46 2006
+++ SPECS/ipp2p.spec Thu Nov 23 22:55:50 2006
@@ -27,7 +27,7 @@
BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.7
%endif
%endif
-BuildRequires: rpmbuild(macros) >= 1.308
+BuildRequires: rpmbuild(macros) >= 1.330
BuildRequires: sed >= 4.0
Buildroot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -185,31 +185,12 @@
IPTABLES_VERSION="%{iptables_ver}"
%{__cc} %{rpmcflags} -DIPTABLES_VERSION=\"$IPTABLES_VERSION\" -fPIC -c libipt_ipp2p.c
#vim: "
-ld %{rpmldflags} -shared -o libipt_ipp2p.so libipt_ipp2p.o
+%{__cc} %{rpmldflags} -shared -o libipt_ipp2p.so libipt_ipp2p.o
%endif
%if %{with kernel}
# kernel module(s)
-for cfg in %{?with_dist_kernel:%{?with_smp:smp} up}%{!?with_dist_kernel:nondist}; do
- if [ ! -r "%{_kernelsrcdir}/config-$cfg" ]; then
- exit 1
- fi
- install -d o/include/linux
- ln -sf %{_kernelsrcdir}/config-$cfg o/.config
- ln -sf %{_kernelsrcdir}/Module.symvers-$cfg o/Module.symvers
- ln -sf %{_kernelsrcdir}/include/linux/autoconf-$cfg.h o/include/linux/autoconf.h
- %{__make} -j1 -C %{_kernelsrcdir} O=$PWD/o prepare scripts
-
- %{__make} -C %{_kernelsrcdir} clean \
- RCS_FIND_IGNORE="-name '*.ko' -o" \
- M=$PWD O=$PWD/o \
- %{?with_verbose:V=1}
- %{__make} -C %{_kernelsrcdir} modules \
- CC="%{__cc}" CPP="%{__cpp}" \
- M=$PWD O=$PWD/o \
- %{?with_verbose:V=1}
- mv ipt_%{name}{,-$cfg}.ko
-done
+%build_kernel_modules -m ipt_%{name}
%endif
%install
@@ -221,13 +202,7 @@
%endif
%if %{with kernel}
-install -d $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}{,smp}/kernel/net/ipv4/netfilter
-install ipt_%{name}-%{?with_dist_kernel:up}%{!?with_dist_kernel:nondist}.ko \
- $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/kernel/net/ipv4/netfilter/ipt_%{name}.ko
-%if %{with smp} && %{with dist_kernel}
-install ipt_%{name}-smp.ko \
- $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}smp/kernel/net/ipv4/netfilter/ipt_%{name}.ko
-%endif
+%install_kernel_modules -m ipt_%{name} -d kernel/net/ipv4/netfilter
%endif
%clean
@@ -248,12 +223,12 @@
%if %{with kernel}
%files -n kernel%{_alt_kernel}-net-ipp2p
%defattr(644,root,root,755)
-/lib/modules/%{_kernel_ver}/kernel/net/ipv4/netfilter/*
+/lib/modules/%{_kernel_ver}/kernel/net/ipv4/netfilter/ipt_%{name}.ko*
%if %{with smp} && %{with dist_kernel}
%files -n kernel%{_alt_kernel}-smp-net-ipp2p
%defattr(644,root,root,755)
-/lib/modules/%{_kernel_ver}smp/kernel/net/ipv4/netfilter/*
+/lib/modules/%{_kernel_ver}smp/kernel/net/ipv4/netfilter/ipt_%{name}.ko*
%endif
%endif
@@ -269,6 +244,10 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.50 2006/11/23 21:55:50 sparky
+- use %build_kernel_modules and %install_kernel_modules
+- use gcc for linking (we have -Wl, in ldflags)
+
Revision 1.49 2006/11/23 20:14:46 hawk
- update to 0.8.2
@@ -408,7 +387,7 @@
- fixed INCPATH.
Revision 1.8 2004/03/14 17:34:37 pluto
-- s/%%{_kernel_ver_str}/%%{_kernel_ver}/
+- s/%{_kernel_ver_str}/%{_kernel_ver}/
Revision 1.7 2004/03/11 12:51:57 pluto
- fixed build with non-dist kernel.
@@ -438,14 +417,14 @@
- fixed cflags.
Revision 1.1.2.6 2004/03/03 22:37:57 pluto
-- %%desc, NFY...
+- %desc, NFY...
Revision 1.1.2.5 2004/03/03 21:57:31 pluto
-- fixed %%build, %%install, %%files
+- fixed %build, %install, %files
Revision 1.1.2.4 2004/03/03 09:13:25 cieciwa
-- fixed %%build, %%install, %%files,
-- %%description and %%summary not updated.
+- fixed %build, %install, %files,
+- %description and %summary not updated.
Revision 1.1.2.3 2004/03/03 08:32:26 cieciwa
- updated
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SPECS/ipp2p.spec?r1=1.49&r2=1.50&f=u
More information about the pld-cvs-commit
mailing list