Magellan Linux

Contents of /smage/trunk/core/module-init-tools/module-init-tools-3.12-r2.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1546 - (show annotations) (download)
Thu Mar 3 14:29:45 2011 UTC (13 years, 1 month ago) by niro
File size: 2056 byte(s)
-rev bump for mass rebuild
1 # $Id: module-init-tools-3.10-r1.smage2 3065 2009-10-07 21:52:46Z niro $
2
3 PNAME="module-init-tools"
4 PVER="3.12"
5 PBUILD="r2"
6
7 PCATEGORIE="sys-apps"
8 STATE="unstable"
9
10 DESCRIPTION="Kernel module utilities for 2.6x kernel series."
11 HOMEPAGE="http://www.kerneltools.org/"
12
13 DEPEND=">= virtual/glibc
14 >= sys-libs/zlib-1.2.3
15 >= virtual/debianutils"
16
17 SRCFILE="${PNAME}-${PVER}.tar.bz2"
18 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
19
20 MCORE_ONLY_KEEP="bin/lsmod
21 sbin/depmod
22 sbin/insmod
23 sbin/lsmod
24 sbin/modprobe
25 sbin/rmmod"
26 sminclude mtools mcore-split
27
28 SRC_URI=(
29 http://www.kernel.org/pub/linux/utils/kernel/${PNAME}/${SRCFILE}
30 http://www.kernel.org/pub/linux/kernel/people/jcm/${PNAME}/${SRCFILE}
31 mirror://${PNAME}/${SRCFILE}
32 mirror://${PNAME}/${PNAME}-0.9.15-legacy-modext-support.patch
33 mirror://${PNAME}/${PNAME}-3.2.2-handle-dupliate-aliases.patch
34 )
35 # note: we dropped buildin modutils, *no* kernel-2.4 support anymore!
36
37 UP2DATE="updatecmd http://www.kernel.org/pub/linux/utils/kernel/${PNAME} | grep -v rc | lasttarball"
38
39 src_prepare()
40 {
41 munpack ${SRCFILE} || die
42 cd ${SRCDIR}
43
44 # support legacy .o modules
45 mpatch ${PNAME}-0.9.15-legacy-modext-support.patch || die
46
47 # fixes an endless loop
48 mpatch ${PNAME}-3.2.2-handle-dupliate-aliases.patch || die
49
50 # from gentoo:
51 # make sure we link dynamically with zlib; our zlib.so is in /lib vs
52 # /usr/lib so it's safe to link with. fixes ugly textrels as well.
53 sed -i 's:-Wl,-Bstatic -lz -Wl,-Bdynamic:-lz:' configure || die
54
55 [ -e ${SRCDIR}/missing ] && rm missing || die
56
57 export WANT_AUTOMAKE=1.10
58 autoreconf --verbose --install --force || die
59
60 # do not regenerate man-pages (needs docbook2man)
61 touch *.5 *.8 || die
62 }
63
64 src_compile()
65 {
66 cd ${SRCDIR}
67 DOCBOOKTOMAN=true mconfigure --prefix=/ --enable-zlib || die
68 mmake || die
69 }
70
71 mcore_generic_src_install()
72 {
73 cd ${SRCDIR}
74 mmake DESTDIR=${BINDIR} install || die
75
76 # installs compat symlinks
77 mlink ../bin/lsmod /sbin/lsmod || die
78 }
79
80 postinstall()
81 {
82 if [ -x /sbin/modules-update ]
83 then
84 echo "Updating module dependencies"
85 /sbin/modules-update
86 fi
87 }