diff options
Diffstat (limited to 'packages/nslu2-binary-only')
18 files changed, 195 insertions, 228 deletions
diff --git a/packages/nslu2-binary-only/nslu2-linksys-firmware_2.3r25.bb b/packages/nslu2-binary-only/nslu2-linksys-firmware_2.3r25.bb deleted file mode 100644 index afbb782252..0000000000 --- a/packages/nslu2-binary-only/nslu2-linksys-firmware_2.3r25.bb +++ /dev/null @@ -1,24 +0,0 @@ -SECTION = "base" -DEPENDS = "slugimage-native unzip-native" -PACKAGES = "" -LICENSE = "GPL" -INHIBIT_DEFAULT_DEPS = "1" -PR = "r3" - -SRC_URI = "ftp://ftp.linksys.com/pub/network/nslu2-fw-2.3r25.zip" -S = "${WORKDIR}" - -python () { - # Don't build unless we're targeting an nslu2 - if bb.data.getVar("MACHINE", d, 1) != "nslu2": - raise bb.parse.SkipPackage("NSLU2 firmware only builds for the Linksys NSLU2") -} - -do_compile () { - slugimage -u -i NSLU2_V23R25.bin -b RedBoot -s SysConf -r ramdisk.ext2.gz -t Trailer - install -d ${STAGING_LIBDIR}/nslu2-binaries - install -m 0755 RedBoot ${STAGING_LIBDIR}/nslu2-binaries/ - install -m 0755 SysConf ${STAGING_LIBDIR}/nslu2-binaries/ - install -m 0755 ramdisk.ext2.gz ${STAGING_LIBDIR}/nslu2-binaries/ - install -m 0755 Trailer ${STAGING_LIBDIR}/nslu2-binaries/ -} diff --git a/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r25.bb b/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r25.bb deleted file mode 100644 index b9fd20ac49..0000000000 --- a/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r25.bb +++ /dev/null @@ -1,23 +0,0 @@ -DESCRIPTION = "Linksys NSLU2 Stock Firmware Libraries." -PACKAGE_ARCH = "nslu2" -SECTION = "base" -PRIORITY = "required" -PR = "r2" - -SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r25.tar.bz2" - -S = "${WORKDIR}/nslu2-linksys-ramdisk-2.3r25" - -do_install () { - ( cd ${S} ; rm -rf bin dev home mnt proc sbin share tmp upload usr var ) - ( cd ${S} ; tar cvf - . ) | ( cd ${D} ; tar xvf - ) -} - -PACKAGES = "${PN}" -FILES_${PN} = "/lib" - -python () { - # Don't build unless we're targeting an nslu2 - if bb.data.getVar("MACHINE", d, 1) != "nslu2": - raise bb.parse.SkipPackage("NSLU2 stock firmware libraries only builds for the Linksys NSLU2") -} diff --git a/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r63.bb b/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r63.bb index 2955f19ad0..1843de069c 100644 --- a/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r63.bb +++ b/packages/nslu2-binary-only/nslu2-linksys-libs_2.3r63.bb @@ -2,9 +2,9 @@ DESCRIPTION = "Linksys NSLU2 Stock Firmware Libraries." PACKAGE_ARCH = "nslu2" SECTION = "base" PRIORITY = "required" -PR = "r1" +PR = "r2" -SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r63.tar.bz2" +SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r63-2.tar.bz2" S = "${WORKDIR}/nslu2-linksys-ramdisk-2.3r63" diff --git a/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r25.bb b/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r25.bb deleted file mode 100644 index f20a2779a3..0000000000 --- a/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r25.bb +++ /dev/null @@ -1,20 +0,0 @@ -DESCRIPTION = "Linksys NSLU2 Stock Firmware Ramdisk." -PACKAGE_ARCH = "nslu2" -SECTION = "base" -PRIORITY = "required" -PR = "r1" - -SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r25.tar.bz2" - -do_install () { - ( cd ${S} ; tar cvf - . ) | ( cd ${D} ; tar xvf - ) -} - -PACKAGES = "${PN}" -FILES_${PN} = "/" - -python () { - # Don't build unless we're targeting an nslu2 - if bb.data.getVar("MACHINE", d, 1) != "nslu2": - raise bb.parse.SkipPackage("NSLU2 ramdisk only builds for the Linksys NSLU2") -} diff --git a/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r63.bb b/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r63.bb index 0fa7d69d54..007b19cbb2 100644 --- a/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r63.bb +++ b/packages/nslu2-binary-only/nslu2-linksys-ramdisk_2.3r63.bb @@ -2,9 +2,9 @@ DESCRIPTION = "Linksys NSLU2 Stock Firmware Ramdisk." PACKAGE_ARCH = "nslu2" SECTION = "base" PRIORITY = "required" -PR = "r1" +PR = "r2" -SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r63.tar.bz2" +SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r63-2.tar.bz2" do_install () { ( cd ${S} ; tar cvf - . ) | ( cd ${D} ; tar xvf - ) diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/ipkg-fl b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/ipkg-fl new file mode 100755 index 0000000000..514ccd4ec8 --- /dev/null +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/ipkg-fl @@ -0,0 +1,11 @@ +#! /bin/sh +echo +echo "Error: The ipkg command cannot currently be used because this" +echo "system is running from its internal flash; it is not currently" +echo "\"uNSLUng\" to an external disk or flash device." +echo +echo "Please complete the process of \"unslinging\" this system, or" +echo "resolve the issues that did not permit it to boot from the" +echo "external device before installing any ipkg packages or updates." +echo +exit 1 diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/linuxrc b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/linuxrc index cc53d447c3..d8a0e5d06c 100755 --- a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/linuxrc +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/linuxrc @@ -15,8 +15,8 @@ cnt=20 while [ $cnt -gt 0 ] ; do echo -ne "\r$cnt " sleep 1 - [ -f /proc/hdd_sdb ] && cnt=0 - [ -f /proc/hdd_sda ] && cnt=0 + [ -e /.sda1root -a -f /proc/hdd_sda ] && cnt=0 + [ -e /.sdb1root -a -f /proc/hdd_sdb ] && cnt=0 cnt=`expr $cnt - 1` done echo @@ -25,10 +25,10 @@ sleep 5 mounted= -for prefroot in sdb1 sda1 ; do - if [ -z "$mounted" ] ; then +for prefroot in sda1 sdb1 ; do + if [ -z "$mounted" -a -e /.${prefroot}root ] ; then if /bin/mount -rt ext3 /dev/$prefroot /mnt ; then - if [ -x /mnt/bin/init ] ; then + if [ -e /mnt/.${prefroot}root -a -x /mnt/bin/init ] ; then /bin/echo "Root filesystem will be mounted from /dev/$prefroot ..." mounted=/mnt else diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/motd-fl b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/motd-fl new file mode 100644 index 0000000000..aafcd21cb5 --- /dev/null +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/motd-fl @@ -0,0 +1,11 @@ + +Welcome to Unslung @v@ + + -------- NOTE: RUNNING FROM INTERNAL FLASH -------- + +This system is currently running from the internal flash memory, +it has NOT booted up into "unslung" mode from an external drive. + +In this mode, very few services are running, and available disk +space is extremely limited. This mode is normally only used +for initial installation, and system maintenance and recovery. diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/motd-un b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/motd-un new file mode 100644 index 0000000000..5439b08be6 --- /dev/null +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/motd-un @@ -0,0 +1,4 @@ + +Welcome to Unslung @v@ + + ---------- NOTE: THIS SYSTEM IS CURRENTLY UNSLUNG ---------- diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/unsling b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/unsling index bed1789a6f..3c25316751 100755 --- a/packages/nslu2-binary-only/unslung-rootfs-2.3r63/unsling +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r63/unsling @@ -1,23 +1,30 @@ #!/bin/sh -usage="Usage: $0 disk1|disk2" - -# Set target disk +usage="Usage: $0 [-nopw] disk1|disk2" +nopw=0 if [ $# -gt 1 ] ; then - echo $usage - exit 1 + if [ "$1" = "-nopw" ] ; then + nopw=1 + shift + fi fi +# Set target disk + if [ $# -eq 1 ] ; then if [ "$1" = "disk1" ] ; then mtch="/dev/sdb1 /share/hdd/data ext3 rw 0 0" targ=/share/hdd/data - flag=.sda1root + targconf=/share/hdd/conf + flag=.sdb1root + htmlinfo="disk1, /dev/sdb1" elif [ "$1" = "disk2" ] ; then mtch="/dev/sda1 /share/flash/data ext3 rw 0 0" targ=/share/flash/data - flag=.sdb1root + targconf=/share/flash/conf + flag=.sda1root + htmlinfo="disk2, /dev/sda1" else echo $usage exit 1 @@ -27,13 +34,57 @@ else exit 1 fi +# Check that we can unsling at all! An unsling operation creates a new +# rootfs, but it also marks the flash rootfs (with a flag file such as +# ".sda1root") so that subsequent boots do not create the "var.state" +# and "dev.state" mounts. Without those mounts, though, an attempt to +# unsling will write a new rootfs on the target with an empty /dev +# directory, which doesnt' work really well. So this check is all about +# making sure that we are in a state in which we are capable of +# performing the unsling operation. + +echo "Checking if able to unsling..." +echo +m1="/dev/root /dev.state jffs2 rw 0 0" +m2="/dev/root /var.state jffs2 rw 0 0" +if ! grep "$m1" /proc/mounts >/dev/null 2>&1 || ! grep "$m2" /proc/mounts >/dev/null 2>&1 ; then + echo "Error: This system is unable to properly unsling because certain" + echo "required mounts (dev.state and/or var.state) are not available." + echo "This is most probably because you have already unslung this system." + echo + + if [ -f /.sda1root ] ; then + rm -f /.sda1root + elif [ -f /.sdb1root ] ; then + rm -f /.sdb1root + elif [ -f /.sda2root ] ; then + rm -f /.sda2root + elif [ -f /.sdb2root ] ; then + rm -f /.sdb2root + else + echo "However, in this case, the flags that indicate an already-unslung" + echo "system seem to be missing. Try restarting your NSLU2 to correct," + echo "but if the problem persists, try re-flashing your NSLU2." + exit 1 + fi + echo "The flags that indicate an already-unslung system have now been" + echo "removed and the required mounts should now become present after" + echo "reboot of the NSLU2." + echo + echo "1) Please unplug all drives from the NSLU2," + echo "2) reboot," + echo "3) and retry the unslinging process." + exit 1 +fi + # Check it's a real mount point -echo "Waiting for $targ" +echo "Waiting for $targ ..." CNT=120 while [ $CNT -gt 0 ] do if grep "$mtch" /proc/mounts >/dev/null 2>&1 ; then + echo echo "Target disk is $targ" CNT=-1 else @@ -43,10 +94,52 @@ do fi done if [ $CNT -eq 0 ] ; then - echo "Error: $targ is not a mounted disk" + echo + echo "Error: $targ ($htmlinfo) is not a mounted disk" exit 1 fi +# Do a quick sanity check to make sure we're unslinging to a disk that's been +# formatted by the Linksys code. + +echo "Checking that $targ has been properly formatted..." +if ! [ -d $targ/public ] || ! [ -f $targconf/.dongle ] || ! [ -f $targconf/passwd ] ; then + echo + echo "Error: $targ does not appear to have been formatted by the" + echo "Linksys formatting utility. Please go to the web interface," + echo "and format the drive before unslinging." + exit 1 +fi + +echo "Checking that $targ is clean..." +if [ -f $targ/.unslung ] ; then + echo + echo "Error: $targ appears to have already been unslung to:" + cat $targ/.unslung + echo "Please go to the web interface, and format the drive before" + echo "unslinging." + echo + echo "(Or, if you wish to unsling without removing the current root" + echo "filesystem, simply remove the file $targ/.unslung and retry" + echo "the unsling -- but beware, you enter uncharted territory!)" + exit 1 +fi + +# Change the root password +if [ "$nopw" = 0 ] ; then + echo + echo "Please enter the new root password. This will be the new root" + echo "password used when the NSLU2 boots up with or without disks" + echo + passwd + if [ $? != 0 ] ; then + echo "Error setting password." + exit 1 + fi + cp /etc/passwd /usr/local/passwd + cp /etc/passwd $targconf/passwd +fi + # Start at the root directory cd / @@ -60,7 +153,8 @@ fi # Copy the complete rootfs to the target. -echo "Copying the complete rootfs from / to $targ." +echo +echo "Copying the complete rootfs from / to $targ ..." /usr/bin/find / -print0 -mount | /usr/bin/cpio -p -0 -d -m -u $targ rm -rf $targ/dev ; mv $targ/dev.state $targ/dev rm -rf $targ/var ; mv $targ/var.state $targ/var @@ -75,6 +169,16 @@ fi echo "Linking /usr/bin/ipkg executable on target disk." rm -f $targ/usr/bin/ipkg ; ln -s /usr/bin/ipkg-cl $targ/usr/bin/ipkg +echo "Linking /etc/motd to the unslung motd on target disk." +rm -f $targ/etc/motd ; ln -s /etc/motd-un $targ/etc/motd + +echo "Updating /home/httpd/html/home.htm with target disk info." +sedcommand="s#Running.from.Internal.Flash#Unslung to $htmlinfo#" +rm -f $targ/home/httpd/html/home.htm_bak +cp $targ/home/httpd/html/home.htm $targ/home/httpd/html/home.htm_bak +sed "$sedcommand" $targ/home/httpd/html/home.htm_bak > $targ/home/httpd/html/home.htm +chmod 644 $targ/home/httpd/html/home.htm + # Create the boot flag file. rm -f /.sd??root $targ/.sd??root @@ -83,4 +187,12 @@ echo "Creating /$flag to direct switchbox to boot from $targ." echo > /$flag echo > $targ/$flag +# Done + +echo +echo "Unsling complete." +echo +echo "Leave the device $htmlinfo plugged in, and reboot" +echo "in order to boot this system up into unslung mode." + exit 0 diff --git a/packages/nslu2-binary-only/unslung-rootfs/rc.1-diversion.patch b/packages/nslu2-binary-only/unslung-rootfs/rc.1-diversion.patch index 8d9f1f6353..35015d6c82 100644 --- a/packages/nslu2-binary-only/unslung-rootfs/rc.1-diversion.patch +++ b/packages/nslu2-binary-only/unslung-rootfs/rc.1-diversion.patch @@ -12,7 +12,7 @@ /bin/echo "Starting Crond :"; . /etc/rc.d/rc.crond /bin/echo "Starting Rest Task :"; . /etc/rc.d/rc.local -+/bin/echo "Starting UNSLUNG Packages:"; ( . /etc/rc.d/rc.unslung-start ) ++/bin/echo "Starting Optware Packages:"; ( . /etc/rc.d/rc.optware-start ) + /usr/bin/Set_Led ready /usr/bin/Set_Led beep1 diff --git a/packages/nslu2-binary-only/unslung-rootfs/rc.halt-diversion.patch b/packages/nslu2-binary-only/unslung-rootfs/rc.halt-diversion.patch index 4723dfad82..3702c3d137 100644 --- a/packages/nslu2-binary-only/unslung-rootfs/rc.halt-diversion.patch +++ b/packages/nslu2-binary-only/unslung-rootfs/rc.halt-diversion.patch @@ -5,7 +5,7 @@ + +if ( [ -r /unslung/rc.halt ] && . /unslung/rc.halt ) ; then return 0 ; fi + -+/bin/echo "Stopping UNSLUNG Packages:"; ( . /etc/rc.d/rc.unslung-stop ) ++/bin/echo "Stopping Optware Packages:"; ( . /etc/rc.d/rc.optware-stop ) + /bin/killall -2 upnpd &>/dev/null /bin/killall nmbd &>/dev/null diff --git a/packages/nslu2-binary-only/unslung-rootfs/rc.unslung-start b/packages/nslu2-binary-only/unslung-rootfs/rc.optware-start index f738761644..53fe7e8262 100755 --- a/packages/nslu2-binary-only/unslung-rootfs/rc.unslung-start +++ b/packages/nslu2-binary-only/unslung-rootfs/rc.optware-start @@ -1,6 +1,6 @@ #!/bin/sh -if ( [ -f /unslung/rc.unslung-start ] && . /unslung/rc.unslung-start ) ; then return 0 ; fi +if ( [ -f /unslung/rc.optware-start ] && . /unslung/rc.optware-start ) ; then return 0 ; fi # Start all init scripts in /opt/etc/init.d # executing them in numerical order. diff --git a/packages/nslu2-binary-only/unslung-rootfs/rc.unslung-stop b/packages/nslu2-binary-only/unslung-rootfs/rc.optware-stop index cf5c6ede67..3668aaf351 100755 --- a/packages/nslu2-binary-only/unslung-rootfs/rc.unslung-stop +++ b/packages/nslu2-binary-only/unslung-rootfs/rc.optware-stop @@ -1,6 +1,6 @@ #!/bin/sh -if ( [ -f /unslung/rc.unslung-stop ] && . /unslung/rc.unslung-stop ) ; then return 0 ; fi +if ( [ -f /unslung/rc.optware-stop ] && . /unslung/rc.optware-stop ) ; then return 0 ; fi # Stop all init scripts in /opt/etc/init.d # executing them in numerical order. diff --git a/packages/nslu2-binary-only/unslung-rootfs/rc.reboot-diversion.patch b/packages/nslu2-binary-only/unslung-rootfs/rc.reboot-diversion.patch index 2b8bf64c76..3e73b941c1 100644 --- a/packages/nslu2-binary-only/unslung-rootfs/rc.reboot-diversion.patch +++ b/packages/nslu2-binary-only/unslung-rootfs/rc.reboot-diversion.patch @@ -5,7 +5,7 @@ + +if ( [ -r /unslung/rc.reboot ] && . /unslung/rc.reboot ) ; then return 0 ; fi + -+/bin/echo "Stopping UNSLUNG Packages:"; ( . /etc/rc.d/rc.unslung-stop ) ++/bin/echo "Stopping Optware Packages:"; ( . /etc/rc.d/rc.optware-stop ) + /bin/killall -2 upnpd 2>/dev/null sleep 4 diff --git a/packages/nslu2-binary-only/unslung-rootfs/unslung.gif b/packages/nslu2-binary-only/unslung-rootfs/unslung.gif Binary files differnew file mode 100644 index 0000000000..998beeda50 --- /dev/null +++ b/packages/nslu2-binary-only/unslung-rootfs/unslung.gif diff --git a/packages/nslu2-binary-only/unslung-rootfs_2.3r25.bb b/packages/nslu2-binary-only/unslung-rootfs_2.3r25.bb deleted file mode 100644 index d80da29d46..0000000000 --- a/packages/nslu2-binary-only/unslung-rootfs_2.3r25.bb +++ /dev/null @@ -1,117 +0,0 @@ -SECTION = "base" - -PR = "r66" - -UNSLUNG_VERSION = "4.21-beta" - -DEPENDS = "nslu2-linksys-libs" - -SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r25.tar.bz2 \ - file://README \ - file://NOTES \ - file://unsling \ - file://resling \ - file://slingover \ - file://linuxrc \ - file://nsswitch.conf \ - file://rc.unslung-start \ - file://rc.unslung-stop \ - file://rc-diversion.patch;patch=1 \ - file://rc.1-diversion.patch;patch=1 \ - file://rc.crond-diversion.patch;patch=1 \ - file://rc.halt-diversion.patch;patch=1 \ - file://rc.local-diversion.patch;patch=1 \ - file://rc.modules-diversion.patch;patch=1 \ - file://rc.network-diversion.patch;patch=1 \ - file://rc.quickset-diversion.patch;patch=1 \ - file://rc.quota-diversion.patch;patch=1 \ - file://rc.reboot-diversion.patch;patch=1 \ - file://rc.reset_usrgrpshare-diversion.patch;patch=1 \ - file://rc.rstimezone-diversion.patch;patch=1 \ - file://rc.samba-diversion.patch;patch=1 \ - file://rc.sysinit-diversion.patch;patch=1 \ - file://rc.thttpd-diversion.patch;patch=1 \ - file://rc.xinetd-diversion.patch;patch=1 \ - file://root-passwd.patch;patch=1 \ - file://tmp-handling.patch;patch=1 \ - file://create-ramdisks.patch;patch=1 \ - file://remount-noatime.patch;patch=1 \ - file://initialise-mtab.patch;patch=1 \ - file://wait-for-quotacheck.patch;patch=1 \ - file://mount_usbdevfs.patch;patch=1 \ - file://maintmode.cgi file://upgrade-maint.htm \ - file://upgrade-nomaint.htm file://upgrade-inhibit.htm \ - file://rc.bootbin \ - " - -S = "${WORKDIR}/nslu2-linksys-ramdisk-2.3r25" - -python () { - # Don't build unslung images unless we're targeting an nslu2 - mach = bb.data.getVar("MACHINE", d, 1) - dist = bb.data.getVar("DISTRO", d, 1) - if mach != 'nslu2' or dist != 'unslung': - raise bb.parse.SkipPackage("Unslung only builds for the Linksys NSLU2") -} - -do_compile () { - echo "V2.3R25-uNSLUng-${UNSLUNG_VERSION}" > ${S}/.unslung - - sed -i -e s/@version#/@version#-uNSLUng-${UNSLUNG_VERSION}/ ${S}/home/httpd/html/home.htm - sed -i -e 's|> <|><a href="Unslung" class="mainmenu" target="_top">Unslung Doco</a><|' \ - ${S}/home/httpd/html/manhead.htm - - # Somehow these two slipped through - this is easier than updating the tar file. - rm -f ${S}/etc/rc.orig - rm -f ${S}/etc/rc.d/rc.1.orig - - install -m 755 ${WORKDIR}/linuxrc ${S}/linuxrc - - # Allow rc.bootbin to be diverted. - mv ${S}/etc/rc.d/rc.bootbin ${S}/sbin/rc.bootbin - install -m 755 ${WORKDIR}/rc.bootbin ${S}/etc/rc.d/rc.bootbin - - install -d ${S}/initrd - - install -m 755 ${WORKDIR}/unsling ${S}/sbin/unsling - install -m 755 ${WORKDIR}/resling ${S}/sbin/resling - install -m 755 ${WORKDIR}/slingover ${S}/sbin/slingover - install -m 755 ${WORKDIR}/rc.unslung-start ${S}/etc/rc.d/rc.unslung-start - install -m 755 ${WORKDIR}/rc.unslung-stop ${S}/etc/rc.d/rc.unslung-stop - - install -m 644 ${WORKDIR}/nsswitch.conf ${S}/etc/nsswitch.conf - - install -d ${S}/opt/doc - install -m 755 ${WORKDIR}/README ${S}/opt/doc/README - install -m 755 ${WORKDIR}/NOTES ${S}/opt/doc/NOTES - ln -s /opt/doc ${S}/home/httpd/html/Unslung - - # Add the diversion script directory - install -d ${S}/unslung - - # Remove the libraries, because they are in nslu2-linksys-libs now - rm -rf ${S}/lib - - # Install maintenance mode files - install -m 755 ${WORKDIR}/maintmode.cgi ${S}/home/httpd/html/Management - install -m 644 ${WORKDIR}/upgrade-maint.htm ${S}/home/httpd/html/Management/upgrade-maint.htm - install -m 644 ${WORKDIR}/upgrade-nomaint.htm ${S}/home/httpd/html/Management/upgrade-nomaint.htm - install -m 644 ${WORKDIR}/upgrade-inhibit.htm ${S}/home/httpd/html/Management/upgrade-inhibit.htm - install -m 644 ${WORKDIR}/upgrade-nomaint.htm ${S}/home/httpd/html/Management/upgrade.htm - sed -i -e s/@ds_sw_version#/@ds_sw_version#-uNSLUng-${UNSLUNG_VERSION}/ \ - ${S}/home/httpd/html/Management/upgrade-maint.htm - sed -i -e s/@ds_sw_version#/@ds_sw_version#-uNSLUng-${UNSLUNG_VERSION}/ \ - ${S}/home/httpd/html/Management/upgrade-nomaint.htm - sed -i -e s/@ds_sw_version#/@ds_sw_version#-uNSLUng-${UNSLUNG_VERSION}/ \ - ${S}/home/httpd/html/Management/upgrade-inhibit.htm - sed -i -e s/@ds_sw_version#/@ds_sw_version#-uNSLUng-${UNSLUNG_VERSION}/ \ - ${S}/home/httpd/html/Management/upgrade.htm -} - -do_install () { - ( cd ${S} ; tar -c -v -f - --exclude '.pc' . ) | ( cd ${D} ; tar xvf - ) -} - -PACKAGES = "${PN}" -FILES_${PN} = "/" -RDEPENDS_${PN} = "nslu2-linksys-libs" diff --git a/packages/nslu2-binary-only/unslung-rootfs_2.3r63.bb b/packages/nslu2-binary-only/unslung-rootfs_2.3r63.bb index 7749db06d5..d45e4103b8 100644 --- a/packages/nslu2-binary-only/unslung-rootfs_2.3r63.bb +++ b/packages/nslu2-binary-only/unslung-rootfs_2.3r63.bb @@ -1,19 +1,23 @@ SECTION = "base" -PR = "r4" +PR = "r8" DEPENDS = "nslu2-linksys-libs" -SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r63.tar.bz2 \ +SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r63-2.tar.bz2 \ file://README \ file://NOTES \ + file://ipkg-fl \ + file://motd-fl \ + file://motd-un \ file://unsling \ file://resling \ file://slingover \ file://linuxrc \ + file://unslung.gif \ file://nsswitch.conf \ - file://rc.unslung-start \ - file://rc.unslung-stop \ + file://rc.optware-start \ + file://rc.optware-stop \ file://rc-diversion.patch;patch=1 \ file://rc.1-diversion.patch;patch=1 \ file://rc.crond-diversion.patch;patch=1 \ @@ -54,9 +58,31 @@ python () { do_compile () { echo "V2.3R63-uNSLUng-${DISTRO_VERSION}" > ${S}/.unslung - sed -i -e s/@version#/@version#-uNSLUng-${DISTRO_VERSION}/ ${S}/home/httpd/html/home.htm + install -m 644 ${WORKDIR}/unslung.gif ${S}/home/httpd/html/linksys.gif + + sed -i -e 's/@version#</@version#-uNSLUng-'${DISTRO_VERSION}'</' ${S}/home/httpd/html/home.htm + sed -i -e s/@ds_sw_version#/@ds_sw_version#-uNSLUng-${DISTRO_VERSION}/ \ + ${S}/home/httpd/html/Management/upgrade.htm + + install -m 755 ${WORKDIR}/ipkg-fl ${S}/usr/bin/ipkg-fl + install -m 644 ${WORKDIR}/motd-fl ${S}/etc/motd-fl + sed -i -e s/@v@/V2.3R63-uNSLUng-${DISTRO_VERSION}/ ${S}/etc/motd-fl + install -m 644 ${WORKDIR}/motd-un ${S}/etc/motd-un + sed -i -e s/@v@/V2.3R63-uNSLUng-${DISTRO_VERSION}/ ${S}/etc/motd-un + rm -f ${S}/etc/motd + ln -s motd-fl ${S}/etc/motd + sed -i -e 's+@public_2#</td>+@public_2# <span class="divider"> | </span><a href="Management/telnet.cgi" class="submenu">\ Manage Telnet</a></td>+' \ + ${S}/home/httpd/html/home.htm + sed -i -e 's+<td bgcolor="#6666cc" align="right" height="33" valign="middle"> </td>+<td bgcolor="#6666cc" fgcolor="#ffffff" align="right" height="33" valign="middle"><center><span class=mainmenu>uNSLUng status: \ Running from Internal Flash</span></center></td>+' \ + ${S}/home/httpd/html/home.htm + sed -i -e 's|> <|><a href="Unslung" class="mainmenu" target="_top">Unslung Doco</a><|' \ ${S}/home/httpd/html/manhead.htm + install -d ${S}/opt/doc + install -m 755 ${WORKDIR}/README ${S}/opt/doc/README + install -m 755 ${WORKDIR}/NOTES ${S}/opt/doc/NOTES + rm -f ${S}/home/httpd/html/Unslung + ln -s /opt/doc ${S}/home/httpd/html/Unslung install -m 755 ${WORKDIR}/linuxrc ${S}/linuxrc @@ -69,29 +95,16 @@ do_compile () { install -m 755 ${WORKDIR}/unsling ${S}/sbin/unsling install -m 755 ${WORKDIR}/resling ${S}/sbin/resling install -m 755 ${WORKDIR}/slingover ${S}/sbin/slingover - install -m 755 ${WORKDIR}/rc.unslung-start ${S}/etc/rc.d/rc.unslung-start - install -m 755 ${WORKDIR}/rc.unslung-stop ${S}/etc/rc.d/rc.unslung-stop + install -m 755 ${WORKDIR}/rc.optware-start ${S}/etc/rc.d/rc.optware-start + install -m 755 ${WORKDIR}/rc.optware-stop ${S}/etc/rc.d/rc.optware-stop install -m 644 ${WORKDIR}/nsswitch.conf ${S}/etc/nsswitch.conf - install -d ${S}/opt/doc - install -m 755 ${WORKDIR}/README ${S}/opt/doc/README - install -m 755 ${WORKDIR}/NOTES ${S}/opt/doc/NOTES - ln -s /opt/doc ${S}/home/httpd/html/Unslung - # Add the diversion script directory install -d ${S}/unslung # Remove the libraries, because they are in nslu2-linksys-libs now rm -rf ${S}/lib - - # Install upgrade mode files -# mv ${S}/home/httpd/html/Management/upgrade.htm ${S}/home/httpd/html/Management/upgrade-old.htm -# mv ${S}/home/httpd/html/Management/upgrade.cgi ${S}/home/httpd/html/Management/upgrade-old.cgi -# install -m 644 ${WORKDIR}/upgrade.htm ${S}/home/httpd/html/Management -# install -m 755 ${WORKDIR}/upgrade.cgi ${S}/home/httpd/html/Management - sed -i -e s/@ds_sw_version#/@ds_sw_version#-uNSLUng-${DISTRO_VERSION}/ \ - ${S}/home/httpd/html/Management/upgrade.htm } do_install () { |