Magellan Linux

Contents of /branches/R11-stable/core/kmod/kmod-15-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 19413 - (show annotations) (download)
Mon Sep 16 08:55:54 2013 UTC (10 years, 7 months ago) by niro
File size: 1427 byte(s)
-release branches/R11-stable
1 # $Id$
2
3 PNAME="kmod"
4 PVER="15"
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://ftp.kernel.org/pub/linux/utils/kernel/${PNAME}/${SRCFILE}
26 mirror://${PNAME}/${SRCFILE}
27 )
28
29 UP2DATE="updatecmd 'http://ftp.kernel.org/pub/linux/utils/kernel/${PNAME}/' | lasttarball 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 }