4 IMAGE_BASENAME = "unslung"
9 DEPENDS = "unslung-kernel unslung-rootfs \
10 glibc slingbox ipkg wget cpio findutils portmap-unslung \
12 ${UNSLUNG_EXTRA_DEPENDS}"
14 IPKG_INSTALL = "unslung-rootfs \
15 libc6-unslung slingbox ipkg wget cpio findutils portmap-unslung \
17 ${UNSLUNG_EXTRA_INSTALL}"
19 IMAGE_PREPROCESS_COMMAND += "unslung_clean_image; "
23 # Note that anything in this function must be repeatable without having to rebuild the rootfs
24 unslung_clean_image () {
26 rm -rf ${IMAGE_ROOTFS}/patches
27 # Remove the kernel image
28 rm -rf ${IMAGE_ROOTFS}/boot
29 # Remove info from the local feed used to build the image
30 rm -f ${IMAGE_ROOTFS}${libdir}/ipkg/lists/*
31 rm -f ${IMAGE_ROOTFS}/${sysconfdir}/version
32 # Tidy up some thing which are in the wrong place
33 mv ${IMAGE_ROOTFS}${libdir}/libipkg* ${IMAGE_ROOTFS}/lib/
34 # Remove the ipkg symlink - unsling puts it back in
35 rm -f ${IMAGE_ROOTFS}${bindir}/ipkg
36 # Hack out the modutils stuff - it's too hard to make it work
37 rm -f ${IMAGE_ROOTFS}${libdir}/ipkg/info/update-modules.postinst
38 rm -rf ${IMAGE_ROOTFS}/etc/rcS.d
39 echo "#!/bin/sh" > ${IMAGE_ROOTFS}/usr/sbin/update-modules
40 echo "exit 0" >> ${IMAGE_ROOTFS}/usr/sbin/update-modules
41 chmod ugo+x ${IMAGE_ROOTFS}/usr/sbin/update-modules
42 echo "#!/bin/sh" > ${IMAGE_ROOTFS}/sbin/depmod
43 echo "exit 0" >> ${IMAGE_ROOTFS}/sbin/depmod
44 chmod ugo+x ${IMAGE_ROOTFS}/sbin/depmod
48 # Don't build unslung images unless we're targeting an nslu2
49 mach = bb.data.getVar("MACHINE", d, 1)
51 raise bb.parse.SkipPackage("Unslung only builds for the Linksys NSLU2")