/[smeserver]/rpms/ppp-kmod/sme7/ppp-kmod.spec
ViewVC logotype

Contents of /rpms/ppp-kmod/sme7/ppp-kmod.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.24 - (show annotations) (download)
Wed Oct 28 18:42:41 2009 UTC (15 years ago) by slords
Branch: MAIN
CVS Tags: ppp-kmod-1_0_2-5_el4_sme
Changes since 1.23: +7 -4 lines
* Tue Oct 26 2009 Shad L. Lords <slords@mail.com> 1.0.2-5.sme
- Make preuninstall script not fail on upgrade

1 # $Id: ppp-kmod.spec,v 1.23 2009/05/26 17:12:09 slords Exp $
2
3 # Define the kmod package name here.
4 %define kmod_name ppp
5
6 # hint: this can he overridden with "--define kversion foo" on the rpmbuild command line, e.g.
7 # --define "kversion 2.6.16-1.2096_FC5"
8 %{!?kversion: %define kversion 2.6.9-89.0.15.EL}
9
10 Name: %{kmod_name}-kmod
11 Version: 1.0.2
12 Release: 5%{?dist}
13 Group: System Environment/Kernel
14 License: GPL
15 Summary: %{kmod_name} kernel modules
16
17 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
18 ExclusiveArch: i586 i686 x86_64
19
20 # Sources.
21 Source0: kernel_ppp_mppe-%{version}-src.tgz
22 Source10: kmodtool-%{kmod_name}
23
24 # Define the variants for each architecture.
25 %define upvar ""
26 %define smpvar smp
27 %ifarch i686
28 %define hugememvar hugemem
29 %define xenvar xenU
30 %endif
31 %ifarch x86_64
32 %define largesmpvar largesmp
33 %define xenvar xenU
34 %endif
35
36 # If kvariants isn't defined on the rpmbuild line, build all variants for this architecture.
37 %{!?kvariants: %define kvariants %{?upvar} %{?smpvar} %{?xenvar} %{?hugememvar} %{?largesmpvar}}
38
39 # Magic hidden here.
40 %define kmodtool sh %{SOURCE10}
41 %{expand:%(%{kmodtool} rpmtemplate_kmp %{kmod_name} %{kversion} %{kvariants} 2>/dev/null)}
42
43 %description
44 %{summary}.
45
46 %prep
47 %setup -q -c
48 pushd kernel_ppp_mppe-%{version}
49 ./pre_build.sh lib/modules/"%{kversion}${kvariant:+$kvariant}"/build . . %{kversion}${kvariant:+$kvariant}
50 patch -p1 < patches/linux-2.6.2-pad.patch
51 patch -p1 < patches/02-ppp_generic.c.patch
52 patch -p1 < patches/03-ppp_mppe_compress.c.patch
53 patch -p1 < patches/04-ppp_mppe_compress.c_license.patch
54 popd
55 for kvariant in %{kvariants} ; do
56 cp -a kernel_ppp_mppe-%{version} _kmod_build_$kvariant
57 done
58
59 %build
60 for kvariant in %{kvariants} ; do
61 # ksrc=%{_usrsrc}/kernels/%{kversion}${kvariant:+-$kvariant}-%{_target_cpu}
62 # pushd _kmod_build_$kvariant
63 # make -C "${ksrc}" modules M=$PWD
64 # popd
65 ksrc=/lib/modules/"%{kversion}${kvariant:+$kvariant}"/build
66 cd _kmod_build_$kvariant
67 # make TOPDIR=${ksrc} modules %{?_smp_mflags}
68 make -C "${ksrc}" SUBDIRS=${PWD} modules %{?_smp_mflags}
69 cd ..
70 done
71
72 %install
73 export INSTALL_MOD_PATH=$RPM_BUILD_ROOT
74 export INSTALL_MOD_DIR=extra/%{kmod_name}
75 for kvariant in %{kvariants} ; do
76 # ksrc=%{_usrsrc}/kernels/%{kversion}${kvariant:+-$kvariant}-%{_target_cpu}
77 # pushd _kmod_build_$kvariant
78 # make -C "${ksrc}" modules_install M=$PWD
79 # install -d ${INSTALL_MOD_PATH}/usr/lib/debug
80 # popd
81 ksrc=/lib/modules/"%{kversion}${kvariant:+$kvariant}"/build
82 cd _kmod_build_$kvariant
83 make -C ${ksrc} SUBDIRS=`pwd` INSTALL_MOD_PATH=$RPM_BUILD_ROOT modinst_dir='$(MODLIB)/extra/'%{kmod_name} modules_install
84 # make TOPDIR=${ksrc} INSTALL_MOD_PATH=$RPM_BUILD_ROOT INSTALL_MOD_DIR=extra/%{kmod_name}/ modules_install %{?_smp_mflags}
85 cd ..
86 done
87
88 # Strip the module(s).
89 find ${INSTALL_MOD_PATH} -type f -name \*.ko -exec strip --strip-debug \{\} \;
90 #
91
92 %clean
93 rm -rf $RPM_BUILD_ROOT
94
95 %changelog
96 * Tue Oct 26 2009 Shad L. Lords <slords@mail.com> 1.0.2-5.sme
97 - Make preuninstall script not fail on upgrade
98
99 * Tue May 26 2009 Shad L. Lords <slords@mail.com> 1.0.2-4.sme
100 - Initial build of the kABI-tracking version from 1.0.4.
101 - Modified spec and kmodtool(-ppp)
102 - Note: weak-modules became available as of CentOS-4.7
103 - Strip the module(s) added
104
105 * Thu Feb 5 2009 Shad L. Lords <slords@mail.com>
106 - Fix post scripts [SME: 4864]
107
108 * Mon May 7 2007 Shad L. Lords <slords@mail.com>
109 - Update to use kmodtool
110
111 * Fri Dec 01 2006 Shad L. Lords <slords@mail.com>
112 - Initial package.

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed