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