Magellan Linux

Contents of /smage/branches/alx-0_6_0/core/mkinitrd/mkinitrd-6.3.5-r4.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3400 - (show annotations) (download)
Tue Apr 3 14:10:32 2012 UTC (12 years, 1 month ago) by niro
File size: 2431 byte(s)
-backport dev handling from upstream
1 # $Id$
2
3 PNAME="mkinitrd"
4 PVER="6.3.5"
5 PBUILD="r4"
6
7 PCATEGORIE="sys-apps"
8
9 DESCRIPTION="Mkinitrd creates filesystem images for use as initial ramdisk (initrd) images."
10 HOMEPAGE="http://magellan-linux.de/"
11
12 DEPEND=">= sys-apps/gawk-3
13 >= virtual/which
14 >= virtual/debianutils
15 >= sys-apps/module-init-tools-3.12
16 >= app-arch/cpio-2
17 >= virtual/gzip
18 >= sys-fs/e2fsprogs-1.41
19 >= dev-libs/popt-1.16
20 >= sys-apps/util-linux-2.19
21 >= sys-apps/v86d-0.1.10"
22
23 # nasm is needed to rebuild syslinux
24 SDEPEND=">= virtual/kernel-sources
25 >= sys-apps/findutils-4
26 >= virtual/sed
27 >= dev-lang/nasm-2"
28
29 SRCFILE="${PNAME}-${PVER}.tar.bz2"
30 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
31
32 REMOVE_DEPRECATED_MAGE_TARGETS=1
33 ALX_ONLY_KEEP="sbin usr/sbin usr/$(mlibdir)/mkinitrd etc/conf.d/mkinitrd"
34 sminclude mbuild alx-split
35
36 SRC_URI=(
37 mirror://${PNAME}/${SRCFILE}
38 mirror://${PNAME}/${PNAME}-${PVER}-no-glib2-dep.patch
39 mirror://${PNAME}/${PNAME}-${PVER}-respect-rootdelay-and-mount-devtmpfs-in-sysroot-if-supported.patch
40 mirror://${PNAME}/${PNAME}-${PVER}-add-linurc-symlink-to-sysroot.patch
41 mirror://${PNAME}/${PNAME}-${PVER}-fix-dev-handling.patch
42 )
43
44 src_prepare()
45 {
46 munpack ${SRCFILE} || die
47 cd ${SRCDIR}
48
49 # no need to link against glib2 - removed in later versions
50 mpatch ${PNAME}-${PVER}-no-glib2-dep.patch || die
51
52 # respect rootdelay given in cmdline and mount devtmpfs in sysroot before switch-root if supported
53 mpatch ${PNAME}-${PVER}-respect-rootdelay-and-mount-devtmpfs-in-sysroot-if-supported.patch || die
54
55 # add missinig /linuxrc -> /sbin/init symlink to sysroot
56 mpatch ${PNAME}-${PVER}-add-linurc-symlink-to-sysroot.patch || die
57
58 # fix broken devtmpfs handling of prior patch and only mount dev if really needed
59 # do not umount initrds dev,proc,sys but mount move it to real sysroot
60 mpatch ${PNAME}-${PVER}-fix-dev-handling.patch || die
61
62 # enable scsi,sata and pata checks for 2.6.29 as default
63 sed -i -e "s:^\(DOSCSI=\).*:\1yes:" \
64 -e "s:^\(DOSATA=\).*:\1yes:" \
65 -e "s:^\(DOPATA=\).*:\1yes:" \
66 livecd/linuxrc.sh || die
67
68 # fix version, we want ${PVER}-${PBUILD}
69 echo "${PVER}-${PBUILD}" > VERSION || die
70
71 # fix libdir on 64bit arches
72 sed -i "s:^\(LIBDIR =\).*:\1 /usr/$(mlibdir):" livecd/Makefile || die
73 sed -i "s:^\(LIBDIR.*=\).*:\1 /usr/$(mlibdir)/mkinitrd:" isolinux/Makefile || die
74 }
75
76 src_compile()
77 {
78 cd ${SRCDIR}
79 mmake ARCH=${ARCH/i*86/i386} || die
80 }
81
82 preinstall()
83 {
84 add_conf_prot_ignore /etc/conf.d/mkinitrd
85 }