Contents of /trunk/core/kmod/kmod-24-r1.smage2
Parent Directory | Revision Log
Revision 29252 -
(show annotations)
(download)
Wed May 31 11:07:49 2017 UTC (7 years, 3 months ago) by niro
File size: 1430 byte(s)
Wed May 31 11:07:49 2017 UTC (7 years, 3 months ago) by niro
File size: 1430 byte(s)
auto added: ver bump to 24-r1
1 | # $Id$ |
2 | |
3 | PNAME="kmod" |
4 | PVER="24" |
5 | PBUILD="r1" |
6 | |
7 | PCAT="sys-apps" |
8 | |
9 | DESCRIPTION="Library and tools for managing linux kernel-modules." |
10 | HOMEPAGE="http://git.profusion.mobi/cgit.cgi/kmod.git" |
11 | |
12 | DEPEND=">= virtual/glibc |
13 | >= app-arch/xz-utils-5 |
14 | >= sys-libs/zlib-1.2.5" |
15 | |
16 | PROVIDE="virtual/module-tools" |
17 | |
18 | SRCFILE="${PNAME}-${PVER}.tar.xz" |
19 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
20 | |
21 | sminclude mbuild mtools multilib |
22 | msetfeature "!check" |
23 | |
24 | SRC_URI=( |
25 | http://www.kernel.org/pub/linux/utils/kernel/${PNAME}/${SRCFILE} |
26 | mirror://${PNAME}/${SRCFILE} |
27 | ) |
28 | |
29 | UP2DATE="updatecmd 'http://www.kernel.org/pub/linux/utils/kernel/${PNAME}/' | highesttarball xz" |
30 | |
31 | src_compile() |
32 | { |
33 | mconfigure --disable-debug --enable-tools --with-xz --with-zlib || die |
34 | mmake || die |
35 | } |
36 | |
37 | src_install() |
38 | { |
39 | mmake DESTDIR=${BINDIR} install || die |
40 | |
41 | # compat symlinks |
42 | minstalldir /usr/bin || die |
43 | minstalldir /usr/sbin || die |
44 | mlink kmod /usr/bin/lsmod || die |
45 | local i |
46 | for i in in {ins,rm,dep}mod mod{info,probe} |
47 | do |
48 | mlink ../bin/kmod /usr/sbin/${i} || die |
49 | done |
50 | |
51 | minstalldocs COPYING NEWS README TODO || die |
52 | } |
53 | |
54 | preinstall() |
55 | { |
56 | if [[ ! -z $(magequery -n module-init-tools) ]] |
57 | then |
58 | echo -e ${COLRED} |
59 | echo -e "Error: sys-apps/module-init-tools is installed!!" |
60 | echo -e "module-init-tools is now replaced by kmod and cannot be installed together." |
61 | echo -e "Please uninstall sys-apps/module-init-tools first!" |
62 | echo -e ${COLDEFAULT} |
63 | die "sys-apps/module-init-tools found!" |
64 | fi |
65 | } |