SPECS: ltmodem.spec - builds with current kernel build system
mmazur
mmazur at pld-linux.org
Tue Aug 29 20:43:30 CEST 2006
Author: mmazur Date: Tue Aug 29 18:43:30 2006 GMT
Module: SPECS Tag: HEAD
---- Log message:
- builds with current kernel build system
---- Files affected:
SPECS:
ltmodem.spec (1.43 -> 1.44)
---- Diffs:
================================================================
Index: SPECS/ltmodem.spec
diff -u SPECS/ltmodem.spec:1.43 SPECS/ltmodem.spec:1.44
--- SPECS/ltmodem.spec:1.43 Thu Jun 22 10:25:58 2006
+++ SPECS/ltmodem.spec Tue Aug 29 20:43:25 2006
@@ -3,6 +3,7 @@
# Conditional build:
%bcond_without dist_kernel # without kernel from distribution
%bcond_without smp # build the SMP driver
+%bcond_with verbose # verbose build (V=1)
%define _corever 8.31
%define maintainer alk
@@ -98,35 +99,41 @@
if [ \! -f ltmdmobj.o-%{_corever} ]; then exit 1; fi
%build
-for cfg in up %{?with_smp:smp}; do
+for cfg in %{?with_dist_kernel:%{?with_smp:smp} up}%{!?with_dist_kernel:nondist}; do
if [ ! -r "%{_kernelsrcdir}/config-$cfg" ]; then
exit 1
fi
- rm -rf include
- install -d modules
- install -d include/{linux,config}
- ln -sf %{_kernelsrcdir}/config-$cfg .config
- ln -sf %{_kernelsrcdir}/include/linux/autoconf-$cfg.h include/linux/autoconf.h
- ln -sf %{_kernelsrcdir}/include/asm-%{_target_base_arch} include/asm
- ln -sf %{_kernelsrcdir}/Module.symvers-$cfg Module.symvers
- touch include/config/MARKER
-
+ rm -f *.o
+ 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
+%if %{with dist_kernel}
+ %{__make} -C %{_kernelsrcdir} O=$PWD/o prepare scripts
+%else
+ install -d o/include/config
+ touch o/include/config/MARKER
+ ln -sf %{_kernelsrcdir}/scripts o/scripts
+%endif
%{__make} -C %{_kernelsrcdir} clean \
RCS_FIND_IGNORE="-name '*.ko' -o" \
- M=$PWD O=$PWD
+ M=$PWD O=$PWD/o \
+ %{?with_verbose:V=1}
+ ln -s ltmdmobj.o-%{_corever} ltmdmobj.o
%{__make} -C %{_kernelsrcdir} modules \
CC="%{__cc}" CPP="%{__cpp}" \
- M=$PWD O=$PWD V=1
- for mod in *.ko; do
- mod=$(echo "$mod" | sed -e 's#\.ko##g')
- mv -v $mod.ko modules/$mod-$cfg.ko
+ M=$PWD O=$PWD/o \
+ %{?with_verbose:V=1}
+ for i in ltmodem ltserial; do
+ mv $i{,-$cfg}.ko
done
done
+
%install
rm -rf $RPM_BUILD_ROOT
+
install -d $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}{,smp}/misc
-cd modules
%if %{with smp}
for mod in *smp.ko; do
nmod=$(echo "$mod" | sed -e 's#-smp##g')
@@ -172,6 +179,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.44 2006/08/29 18:43:25 mmazur
+- builds with current kernel build system
+
Revision 1.43 2006/06/22 08:25:58 jasw
- up to 8.31.alk.8
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SPECS/ltmodem.spec?r1=1.43&r2=1.44&f=u
More information about the pld-cvs-commit
mailing list