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

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

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


Revision 1.25 - (hide annotations) (download)
Tue Dec 1 15:41:56 2009 UTC (15 years ago) by slords
Branch: MAIN
CVS Tags: ppp-kmod-1_0_2-6_el4_sme
Changes since 1.24: +14 -3 lines
* Tue Dec 1 2009 Shad L. Lords <slords@mail.com> 1.0.2-6.sme
- Update kmod to fix buffer too small errors [SME: 5628]

1 slords 1.25 # $Id: ppp-kmod.spec,v 1.24 2009/10/28 18:42:41 slords Exp $
2 slords 1.23
3     # Define the kmod package name here.
4     %define kmod_name ppp
5 slords 1.10
6 slords 1.1 # 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 slords 1.25 %{!?kversion: %define kversion 2.6.9-89.0.16.EL}
9 slords 1.1
10 slords 1.23 Name: %{kmod_name}-kmod
11     Version: 1.0.2
12 slords 1.25 Release: 6%{?dist}
13 slords 1.23 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 slords 1.1
24 slords 1.25 # Patches.
25     Patch1: ppp-725ad2a8f1358bff885414f5e91d253c99921ddc.patch
26     Patch2: ppp-44315cc76567e2d911d56091665637e305af182d.patch
27     Patch3: ppp-kmod-1.0.2-padfix.patch
28    
29 slords 1.23 # Define the variants for each architecture.
30 slords 1.1 %define upvar ""
31 slords 1.23 %define smpvar smp
32 slords 1.1 %ifarch i686
33     %define hugememvar hugemem
34     %define xenvar xenU
35     %endif
36     %ifarch x86_64
37     %define largesmpvar largesmp
38     %define xenvar xenU
39     %endif
40 slords 1.23
41     # If kvariants isn't defined on the rpmbuild line, build all variants for this architecture.
42     %{!?kvariants: %define kvariants %{?upvar} %{?smpvar} %{?xenvar} %{?hugememvar} %{?largesmpvar}}
43    
44     # Magic hidden here.
45     %define kmodtool sh %{SOURCE10}
46     %{expand:%(%{kmodtool} rpmtemplate_kmp %{kmod_name} %{kversion} %{kvariants} 2>/dev/null)}
47 slords 1.1
48     %description
49     %{summary}.
50    
51     %prep
52     %setup -q -c
53 slords 1.23 pushd kernel_ppp_mppe-%{version}
54     ./pre_build.sh lib/modules/"%{kversion}${kvariant:+$kvariant}"/build . . %{kversion}${kvariant:+$kvariant}
55 slords 1.25 %patch1 -p3
56     %patch2 -p3
57     %patch3
58 slords 1.1 patch -p1 < patches/linux-2.6.2-pad.patch
59     patch -p1 < patches/02-ppp_generic.c.patch
60     patch -p1 < patches/03-ppp_mppe_compress.c.patch
61     patch -p1 < patches/04-ppp_mppe_compress.c_license.patch
62 slords 1.23 popd
63 slords 1.1 for kvariant in %{kvariants} ; do
64     cp -a kernel_ppp_mppe-%{version} _kmod_build_$kvariant
65     done
66    
67     %build
68     for kvariant in %{kvariants} ; do
69 slords 1.23 # ksrc=%{_usrsrc}/kernels/%{kversion}${kvariant:+-$kvariant}-%{_target_cpu}
70     # pushd _kmod_build_$kvariant
71     # make -C "${ksrc}" modules M=$PWD
72     # popd
73     ksrc=/lib/modules/"%{kversion}${kvariant:+$kvariant}"/build
74     cd _kmod_build_$kvariant
75     # make TOPDIR=${ksrc} modules %{?_smp_mflags}
76     make -C "${ksrc}" SUBDIRS=${PWD} modules %{?_smp_mflags}
77     cd ..
78     done
79    
80     %install
81     export INSTALL_MOD_PATH=$RPM_BUILD_ROOT
82     export INSTALL_MOD_DIR=extra/%{kmod_name}
83     for kvariant in %{kvariants} ; do
84     # ksrc=%{_usrsrc}/kernels/%{kversion}${kvariant:+-$kvariant}-%{_target_cpu}
85     # pushd _kmod_build_$kvariant
86     # make -C "${ksrc}" modules_install M=$PWD
87     # install -d ${INSTALL_MOD_PATH}/usr/lib/debug
88     # popd
89     ksrc=/lib/modules/"%{kversion}${kvariant:+$kvariant}"/build
90     cd _kmod_build_$kvariant
91     make -C ${ksrc} SUBDIRS=`pwd` INSTALL_MOD_PATH=$RPM_BUILD_ROOT modinst_dir='$(MODLIB)/extra/'%{kmod_name} modules_install
92     # make TOPDIR=${ksrc} INSTALL_MOD_PATH=$RPM_BUILD_ROOT INSTALL_MOD_DIR=extra/%{kmod_name}/ modules_install %{?_smp_mflags}
93     cd ..
94 slords 1.1 done
95 slords 1.23
96     # Strip the module(s).
97     find ${INSTALL_MOD_PATH} -type f -name \*.ko -exec strip --strip-debug \{\} \;
98     #
99 slords 1.1
100     %clean
101     rm -rf $RPM_BUILD_ROOT
102    
103     %changelog
104 slords 1.25 * Tue Dec 1 2009 Shad L. Lords <slords@mail.com> 1.0.2-6.sme
105     - Update kmod to fix buffer too small errors [SME: 5628]
106    
107 slords 1.24 * Tue Oct 26 2009 Shad L. Lords <slords@mail.com> 1.0.2-5.sme
108     - Make preuninstall script not fail on upgrade
109    
110     * Tue May 26 2009 Shad L. Lords <slords@mail.com> 1.0.2-4.sme
111 slords 1.23 - Initial build of the kABI-tracking version from 1.0.4.
112     - Modified spec and kmodtool(-ppp)
113     - Note: weak-modules became available as of CentOS-4.7
114     - Strip the module(s) added
115    
116 snetram 1.20 * Thu Feb 5 2009 Shad L. Lords <slords@mail.com>
117     - Fix post scripts [SME: 4864]
118    
119 slords 1.1 * Mon May 7 2007 Shad L. Lords <slords@mail.com>
120     - Update to use kmodtool
121    
122     * Fri Dec 01 2006 Shad L. Lords <slords@mail.com>
123     - Initial package.

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