diff options
author | Stefan Schmidt <stefan@datenfreihafen.org> | 2009-01-27 10:12:58 +0000 |
---|---|---|
committer | Stefan Schmidt <stefan@datenfreihafen.org> | 2009-01-27 10:12:58 +0000 |
commit | 3f298b0d3342d1fbbbc1830528698fb4dd640d34 (patch) | |
tree | e3ed4b4b06030722ff2f0628e5af27aa7695d736 | |
parent | df756c10617bb375929b672e9d6a26952dbb31b9 (diff) | |
download | openembedded-3f298b0d3342d1fbbbc1830528698fb4dd640d34.tar.gz |
Revert "Merge commit 'origin/john_lee/fastboot-devel' into org.openembedded.dev"
This reverts commit 366bf6043abfbbbfa98168548f42aa9aaf6c28b9.
This did broke all image for !om-gta02. Reverted and PRs bumped.
58 files changed, 170 insertions, 1158 deletions
diff --git a/conf/distro/include/angstrom-2007-for-openmoko.inc b/conf/distro/include/angstrom-2007-for-openmoko.inc index 5675e75723..34fbc52cfe 100644 --- a/conf/distro/include/angstrom-2007-for-openmoko.inc +++ b/conf/distro/include/angstrom-2007-for-openmoko.inc @@ -230,6 +230,8 @@ DISTRO_EXTRA_RRECOMMENDS += " \ kernel-module-vfat \ kernel-module-ext2 \ kernel-module-af-packet \ + avahi-daemon \ + avahi-autoipd \ openssh-sftp-server \ " diff --git a/conf/distro/openmoko.conf b/conf/distro/openmoko.conf index c038096231..a1a65410f5 100644 --- a/conf/distro/openmoko.conf +++ b/conf/distro/openmoko.conf @@ -30,18 +30,6 @@ DISTRO_FEED_URI ?= "http://downloads.openmoko.org/repository/testing" AB_DEPLOY_EXTRA ?= "" DEPLOY_DIR_IMAGE = "${DEPLOY_DIR}/images/${MACHINE_ARCH}/${AB_DEPLOY_EXTRA}" -DISTRO_INITSCRIPTS = "initscripts-openmoko" - -# We try to minimize the distro features in the default image. -DISTRO_FEATURES = "wifi ppp alsa ext2 vfat usbhost" - -# Some features (bluetooth, usbgadget) include packages we do not like. -# Pick some of the packages manually. -DISTRO_EXTRA_RDEPENDS += " \ - bluez4 \ - kernel-module-g-ether \ - " - # 2.18 seems to break badly on 64-bit systems PREFERRED_VERSION_binutils ?= "2.17.50.0.12" PREFERRED_VERSION_binutils-cross ?= "2.17.50.0.12" diff --git a/conf/machine/om-gta02.conf b/conf/machine/om-gta02.conf index c31828aafe..c7b06dc3cd 100644 --- a/conf/machine/om-gta02.conf +++ b/conf/machine/om-gta02.conf @@ -24,7 +24,6 @@ MACHINE_EXTRA_RRECOMMENDS = "\ # no need to bypass this as in om-gta01, since this model is not using a multiplexed ttySAC0 SERIAL_CONSOLE = "115200 ttySAC2" -USE_VT = "0" # used by some images ROOT_FLASH_SIZE = "256" diff --git a/packages/alsa/alsa-state.bb b/packages/alsa/alsa-state.bb index 9e7f157059..ba030e4aab 100644 --- a/packages/alsa/alsa-state.bb +++ b/packages/alsa/alsa-state.bb @@ -7,7 +7,7 @@ DESCRIPTION = "Alsa Scenario Files" LICENSE = "MIT" PV = "0.2.0" -PR = "r1" +PR = "r0" SRC_URI = "\ file://asound.conf \ @@ -19,7 +19,7 @@ SRC_URI = "\ inherit update-rc.d INITSCRIPT_NAME = "alsa-state" -INITSCRIPT_PARAMS = "start 39 S ." +INITSCRIPT_PARAMS = "defaults 10" do_install() { install -d ${D}${sysconfdir}/init.d @@ -50,9 +50,5 @@ pkg_postinst_${PN}() { then /usr/sbin/alsactl -f ${sysconfdir}/asound.state restore fi - # INITSCRIPT_PARAMS changed, so remove the old and - # install the new setting. - update-rc.d -f ${INITSCRIPT_NAME} remove - update-rc.d ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS} fi } diff --git a/packages/alsa/alsa-state/alsa-state b/packages/alsa/alsa-state/alsa-state index 84cdf03750..c6bc1fd494 100755 --- a/packages/alsa/alsa-state/alsa-state +++ b/packages/alsa/alsa-state/alsa-state @@ -11,7 +11,7 @@ asound_restore(){ echo "ALSA: Restoring mixer settings..." if test -x /usr/sbin/alsactl -a -e /etc/asound.state then - /usr/sbin/alsactl -f /etc/asound.state restore & + /usr/sbin/alsactl -f /etc/asound.state restore fi } diff --git a/packages/base-files/base-files/om-gta01/fstab b/packages/base-files/base-files/om-gta01/fstab index 426d83e4d8..e5acb6a1eb 100644 --- a/packages/base-files/base-files/om-gta01/fstab +++ b/packages/base-files/base-files/om-gta01/fstab @@ -1,5 +1,16 @@ -/dev/mtdblock4 / jffs2 rw,noatime 1 1 -proc /proc proc defaults 0 0 +# Root and Pseudo +/dev/mtdblock4 / jffs2 rw,noatime 1 1 +proc /proc proc defaults 0 0 + +# devpts? +# usb? + +# Temporary +tmpfs /var/volatile tmpfs mode=0755 0 0 +tmpfs /dev/shm tmpfs mode=0777 0 0 # microSD slot -/dev/mmcblk0p1 /media/card auto defaults,async 0 0 +/dev/mmcblk0p1 /media/card auto defaults,async,noauto 0 0 + +# USB Storage +/dev/sda1 /media/hdd vfat noauto,umask=000,noatime,iocharset=utf8,codepage=932 0 0 diff --git a/packages/base-files/base-files/om-gta02/fstab b/packages/base-files/base-files/om-gta02/fstab index 61c7cdcafd..e5acb6a1eb 100644 --- a/packages/base-files/base-files/om-gta02/fstab +++ b/packages/base-files/base-files/om-gta02/fstab @@ -1,5 +1,16 @@ -/dev/mtdblock6 / jffs2 rw,noatime 1 1 -proc /proc proc defaults 0 0 +# Root and Pseudo +/dev/mtdblock4 / jffs2 rw,noatime 1 1 +proc /proc proc defaults 0 0 + +# devpts? +# usb? + +# Temporary +tmpfs /var/volatile tmpfs mode=0755 0 0 +tmpfs /dev/shm tmpfs mode=0777 0 0 # microSD slot -/dev/mmcblk0p1 /media/card auto defaults,async 0 0 +/dev/mmcblk0p1 /media/card auto defaults,async,noauto 0 0 + +# USB Storage +/dev/sda1 /media/hdd vfat noauto,umask=000,noatime,iocharset=utf8,codepage=932 0 0 diff --git a/packages/initscripts/files/arm/alignment.sh b/packages/initscripts/initscripts-1.0/arm/alignment.sh index 32a9eaace2..32a9eaace2 100644 --- a/packages/initscripts/files/arm/alignment.sh +++ b/packages/initscripts/initscripts-1.0/arm/alignment.sh diff --git a/packages/initscripts/files/devpts b/packages/initscripts/initscripts-1.0/devpts index e10e371662..4a0978b404 100644 --- a/packages/initscripts/files/devpts +++ b/packages/initscripts/initscripts-1.0/devpts @@ -1,5 +1,5 @@ # GID of the `tty' group TTYGRP=5 - + # Set to 600 to have `mesg n' be the default TTYMODE=620 diff --git a/packages/initscripts/files/finish.sh b/packages/initscripts/initscripts-1.0/finish index 4f9f75f47c..4f9f75f47c 100644..100755 --- a/packages/initscripts/files/finish.sh +++ b/packages/initscripts/initscripts-1.0/finish diff --git a/packages/initscripts/files/functions b/packages/initscripts/initscripts-1.0/functions index fb9a914e4d..fb9a914e4d 100644 --- a/packages/initscripts/files/functions +++ b/packages/initscripts/initscripts-1.0/functions diff --git a/packages/initscripts/files/halt b/packages/initscripts/initscripts-1.0/halt index d8cab222ca..d8cab222ca 100644..100755 --- a/packages/initscripts/files/halt +++ b/packages/initscripts/initscripts-1.0/halt diff --git a/packages/initscripts/files/hostname.sh b/packages/initscripts/initscripts-1.0/hostname.sh index 0f3d374286..0f3d374286 100644..100755 --- a/packages/initscripts/files/hostname.sh +++ b/packages/initscripts/initscripts-1.0/hostname.sh diff --git a/packages/initscripts/files/reboot b/packages/initscripts/initscripts-1.0/reboot index 56278199be..56278199be 100644..100755 --- a/packages/initscripts/files/reboot +++ b/packages/initscripts/initscripts-1.0/reboot diff --git a/packages/initscripts/files/rmnologin b/packages/initscripts/initscripts-1.0/rmnologin index 444145a26a..444145a26a 100644..100755 --- a/packages/initscripts/files/rmnologin +++ b/packages/initscripts/initscripts-1.0/rmnologin diff --git a/packages/initscripts/files/save-rtc.sh b/packages/initscripts/initscripts-1.0/save-rtc.sh index e786073051..e786073051 100644 --- a/packages/initscripts/files/save-rtc.sh +++ b/packages/initscripts/initscripts-1.0/save-rtc.sh diff --git a/packages/initscripts/files/sendsigs b/packages/initscripts/initscripts-1.0/sendsigs index c62a5cd37d..c62a5cd37d 100644..100755 --- a/packages/initscripts/files/sendsigs +++ b/packages/initscripts/initscripts-1.0/sendsigs diff --git a/packages/initscripts/files/umountfs b/packages/initscripts/initscripts-1.0/umountfs index ec75b0c4a4..ec75b0c4a4 100644..100755 --- a/packages/initscripts/files/umountfs +++ b/packages/initscripts/initscripts-1.0/umountfs diff --git a/packages/initscripts/files/umountnfs.sh b/packages/initscripts/initscripts-1.0/umountnfs.sh index f5fe48aa74..f5fe48aa74 100644..100755 --- a/packages/initscripts/files/umountnfs.sh +++ b/packages/initscripts/initscripts-1.0/umountnfs.sh diff --git a/packages/initscripts/files/volatiles b/packages/initscripts/initscripts-1.0/volatiles index fbcc858226..fbcc858226 100644 --- a/packages/initscripts/files/volatiles +++ b/packages/initscripts/initscripts-1.0/volatiles diff --git a/packages/initscripts/initscripts-openmoko/bootmisc.sh b/packages/initscripts/initscripts-openmoko/bootmisc.sh deleted file mode 100644 index 4511e12fc1..0000000000 --- a/packages/initscripts/initscripts-openmoko/bootmisc.sh +++ /dev/null @@ -1,47 +0,0 @@ -# -# bootmisc.sh Miscellaneous things to be done during bootup. -# - -. /etc/default/rcS -# -# Put a nologin file in /etc to prevent people from logging in before -# system startup is complete. -# -if test "$DELAYLOGIN" = yes -then - echo "System bootup in progress - please wait" > /etc/nologin - cp /etc/nologin /etc/nologin.boot -fi - -# -# Update /etc/motd. -# -if test "$EDITMOTD" != no -then - uname -a > /etc/motd.tmp - sed 1d /etc/motd >> /etc/motd.tmp - mv /etc/motd.tmp /etc/motd -fi - -# -# Update dynamic library cache -# -#/sbin/ldconfig - -# Set the system clock from hardware clock -# If the timestamp is 1 day or more recent than the current time, -# use the timestamp instead. -[ "$UTC" = yes ] || /etc/init.d/hwclock.sh start - -if ! test -f /etc/.configured && test -e /etc/timestamp -then - SYSTEMDATE=`date "+%Y%m%d"` - TIMESTAMP=`cat /etc/timestamp | awk '{ print substr($0,9,4) substr($0,1,4);}'` - NEEDUPDATE=`expr \( $TIMESTAMP \> $SYSTEMDATE \)` - if [ $NEEDUPDATE -eq 1 ]; then - date `cat /etc/timestamp` - /etc/init.d/hwclock.sh stop - fi -fi - -: exit 0 diff --git a/packages/initscripts/initscripts-openmoko/campgsm b/packages/initscripts/initscripts-openmoko/campgsm deleted file mode 100644 index 5be67086c2..0000000000 --- a/packages/initscripts/initscripts-openmoko/campgsm +++ /dev/null @@ -1,128 +0,0 @@ -#!/bin/sh - -VERBOSE=no - -PIDS=`pidof -x "$0"` - -# make sure pidof sees us -if [ -z "$PIDS" ]; then - exec "$0" - exit 1 -fi - -GSM_DEVICE="/dev/ttySAC0" -GSM_POWER="/sys/devices/platform/neo1973-pm-gsm.0/power_on" -GSM_RESET="/sys/devices/platform/neo1973-pm-gsm.0/reset" - -GSM_COMMANDS="Z E0V1 +CFUN=1 +COPS=0" - -gsm_running () { - if [ "$PIDS" != "$$" ]; then - return 0 - else - return 1 - fi -} - -gsm_send () { - cmd="$1" - echo -ne "AT${cmd}\r" > "$GSM_DEVICE" -} - -# this function might block forever -gsm_wait () { - ret="UNKNOWN" - - while read status; do - case "$status" in - OK*) - ret="OK" - ;; - ERROR*) - ret="ERROR" - ;; - *) - ret="UNKNOWN" - ;; - esac - if [ "x$ret" != "xUNKNOWN" ]; then - break - fi - done < "$GSM_DEVICE" - - if [ "x$ret" != "xOK" ]; then - return 1 - fi - - return 0 -} - -gsm_setup () { - [ $VERBOSE == "yes" ] && echo -n "Powering up GSM modem..." - echo 0 > "$GSM_POWER"; sleep 1 - echo 1 > "$GSM_POWER"; sleep 1 - echo 1 > "$GSM_RESET"; sleep 1 - echo 0 > "$GSM_RESET"; sleep 4 - [ $VERBOSE == "yes" ] && echo "done" - - stty -F "$GSM_DEVICE" cooked -opost -echo crtscts 115200 -} - -gsm_wakeup () { - [ $VERBOSE == "yes" ] && echo "Waking up GSM modem" - - # there is at most one OK/ERROR even if we send multiple commands - gsm_send "" - gsm_send "" - gsm_send "" - - if gsm_wait; then - [ $VERBOSE == "yes" ] && echo "GSM modem awake" - return 0 - else - echo "failed to wake up GSM modem" - return 1 - fi -} - -start () { - gsm_setup - - if gsm_wakeup; then - for cmd in $GSM_COMMANDS - do - [ $VERBOSE == "yes" ] && echo "Sending AT$cmd" - gsm_send "$cmd" - - if ! gsm_wait; then - echo "AT$cmd failed" - break - fi - done - fi -} - -set -e - -case "$1" in - start) - if gsm_running; then - echo "Another instance is already running" - exit 1 - fi - - start & - ;; - stop) - if gsm_running; then - PIDS=`pidof -x -o "$$" "$0"` - echo -n "Stopping other instances..." - kill $PIDS - echo "done" - fi - ;; - *) - echo "Usage: $0 {start|stop}" - exit 1 - ;; -esac diff --git a/packages/initscripts/initscripts-openmoko/checkroot.sh b/packages/initscripts/initscripts-openmoko/checkroot.sh deleted file mode 100644 index 029ae9b405..0000000000 --- a/packages/initscripts/initscripts-openmoko/checkroot.sh +++ /dev/null @@ -1,43 +0,0 @@ -# -# checkroot.sh Check to root filesystem. -# -# Version: @(#)checkroot.sh 2.84 25-Jan-2002 miquels@cistron.nl -# - -. /etc/default/rcS - -# -# Set SULOGIN in /etc/default/rcS to yes if you want a sulogin to be spawned -# from this script *before anything else* with a timeout, like SCO does. -# -test "$SULOGIN" = yes && sulogin -t 30 $CONSOLE - -# -# If the root filesystem was not marked as read-only in /etc/fstab, -# remount the rootfs rw but do not try to change mtab because it -# is on a ro fs until the remount succeeded. Then clean up old mtabs -# and finally write the new mtab. -# This part is only needed if the rootfs was mounted ro. -# -ROOTFSDEV="/dev/root" -if grep -q "^$ROOTFSDEV .* rw" /proc/mounts; then - echo "Root filesystem already read-write, not remounting" -else - rootmode=rw - - echo "Remounting root file system..." - mount -n -o remount,noatime,$rootmode / - if test "$rootmode" = rw - then - if test ! -L /etc/mtab - then - rm -f /etc/mtab~ /etc/nologin - : > /etc/mtab - fi - mount -f -o remount / - mount -f /proc - test "$devfs" && grep -q '^devfs /dev' /proc/mounts && mount -f "$devfs" - fi -fi - -: exit 0 diff --git a/packages/initscripts/initscripts-openmoko/led-trigger.sh b/packages/initscripts/initscripts-openmoko/led-trigger.sh deleted file mode 100644 index 9583ce9331..0000000000 --- a/packages/initscripts/initscripts-openmoko/led-trigger.sh +++ /dev/null @@ -1,6 +0,0 @@ -#! /bin/sh -sys_led_trigger="/sys/devices/platform/gta02-led.0/leds/gta02-aux:red/trigger" -if test -e $sys_led_trigger ;then - echo bat-charging > $sys_led_trigger -fi - diff --git a/packages/initscripts/initscripts-openmoko/mountall.sh b/packages/initscripts/initscripts-openmoko/mountall.sh deleted file mode 100644 index 4bd7bbb02c..0000000000 --- a/packages/initscripts/initscripts-openmoko/mountall.sh +++ /dev/null @@ -1,52 +0,0 @@ -# -# mountall.sh Mount all filesystems. -# -# Version: @(#)mountall.sh 2.83-2 01-Nov-2001 miquels@cistron.nl -# -. /etc/default/rcS -if test -f /etc/default/mountall; then - . /etc/default/mountall -fi - -# -# Mount local filesystems in /etc/fstab. For some reason, people -# might want to mount "proc" several times, and mount -v complains -# about this. So we mount "proc" filesystems without -v. -# -test "$VERBOSE" != no && echo "Mounting local filesystems..." -mount -a $MOUNTALL - -# -# We might have mounted something over /dev, see if /dev/initctl is there. -# -if test ! -p /dev/initctl -then - rm -f /dev/initctl - mknod -m 600 /dev/initctl p -fi -kill -USR1 1 - -# -# Execute swapon command again, in case we want to swap to -# a file on a now mounted filesystem. -# -doswap=yes -if test $doswap = yes -then - swapon -a 2> /dev/null -fi - -# A missing homedirectory for root can cause all sorts of problems. -# This can happen after user formats his /home partition for example - -if test -e /etc/passwd -then - ROOT_HOME="`grep root /etc/passwd | cut -d: -f6`" - - if test -n "$ROOT_HOME" - then - ! test -d "$ROOT_HOME" && mkdir -p "$ROOT_HOME" - fi -fi -: exit 0 - diff --git a/packages/initscripts/initscripts-openmoko/mountdevsubfs.sh b/packages/initscripts/initscripts-openmoko/mountdevsubfs.sh deleted file mode 100644 index c6cfb05af2..0000000000 --- a/packages/initscripts/initscripts-openmoko/mountdevsubfs.sh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh - -. /etc/default/devpts - -test -c /dev/ptmx || mknod -m 666 /dev/ptmx c 5 2 - -if [ -d /dev/pts ]; then - mount -n -t devpts devpts /dev/pts -ogid=${TTYGRP},mode=${TTYMODE} -fi - - -if [ -d /dev/shm ]; then - mount -n -t tmpfs shmfs /dev/shm -omode=0777 -fi diff --git a/packages/initscripts/initscripts-openmoko/mountkernfs.sh b/packages/initscripts/initscripts-openmoko/mountkernfs.sh deleted file mode 100644 index 1ed09fcf05..0000000000 --- a/packages/initscripts/initscripts-openmoko/mountkernfs.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh - -supported_kernel() { - case "$(uname -r)" in - 2.[012345].*|2.6.[0-9]|2.6.[0-9][!0-9]*) return 1 ;; - 2.6.1[0-7]|2.6.1[0-7][!0-9]*) return 1 ;; - esac - return 0 -} - -check_kernel() { - if ! supported_kernel; then - echo "WARNING: kernel < 2.6.18" - fi - - if ! grep -qs devpts /proc/filesystems; then - echo "WARNING: kernel does not support devpts" - fi - - if ! grep -qs tmpfs /proc/filesystems; then - echo "WARNING: kernel does not support tmpfs" - fi -} - -if [ -d /proc ]; then - mount -n -t proc proc /proc -fi - -check_kernel - -if [ -d /sys ]; then - mount -n -t sysfs sysfs /sys -fi diff --git a/packages/initscripts/initscripts-openmoko/mountnfs.sh b/packages/initscripts/initscripts-openmoko/mountnfs.sh deleted file mode 100644 index 2631392483..0000000000 --- a/packages/initscripts/initscripts-openmoko/mountnfs.sh +++ /dev/null @@ -1,87 +0,0 @@ -# -# mountnfs.sh Now that TCP/IP is configured, mount the NFS file -# systems in /etc/fstab if needed. If possible, -# start the portmapper before mounting (this is needed for -# Linux 2.1.x and up). -# -# Also mounts SBM filesystems now, so the name of -# this script is getting increasingly inaccurate. -# -# Version: @(#)mountnfs.sh 2.83 05-Oct-2001 miquels@cistron.nl -# - -. /etc/default/rcS - -# -# Run in a subshell because of I/O redirection. -# -test -x /sbin/portmap && test -f /etc/fstab && ( - -# -# Read through fstab line by line. If it is NFS, set the flag -# for mounting NFS filesystems. If any NFS partition is found and it -# not mounted with the nolock option, we start the portmapper. -# -portmap=no -mount_nfs=no -mount_smb=no -mount_ncp=no -while read device mountpt fstype options -do - case "$device" in - ""|\#*) - continue - ;; - esac - - case "$options" in - *noauto*) - continue - ;; - esac - - if test "$fstype" = nfs - then - mount_nfs=yes - case "$options" in - *nolock*) - ;; - *) - portmap=yes - ;; - esac - fi - if test "$fstype" = smbfs - then - mount_smb=yes - fi - if test "$fstype" = ncpfs - then - mount_ncp=yes - fi -done - -exec 0>&1 - -if test "$portmap" = yes -then - if test -x /sbin/portmap - then - echo -n "Starting portmapper... " - start-stop-daemon --start --quiet --exec /sbin/portmap - sleep 2 - fi -fi - -if test "$mount_nfs" = yes || test "$mount_smb" = yes || test "$mount_ncp" = yes -then - echo "Mounting remote filesystems..." - test "$mount_nfs" = yes && mount -a -t nfs - test "$mount_smb" = yes && mount -a -t smbfs - test "$mount_ncp" = yes && mount -a -t ncpfs -fi - -) < /etc/fstab - -: exit 0 - diff --git a/packages/initscripts/initscripts-openmoko/populate-volatile.sh b/packages/initscripts/initscripts-openmoko/populate-volatile.sh deleted file mode 100644 index 6fb23d758d..0000000000 --- a/packages/initscripts/initscripts-openmoko/populate-volatile.sh +++ /dev/null @@ -1,248 +0,0 @@ -#!/bin/sh - -. /etc/default/rcS - -CFGDIR="/etc/default/volatiles" -TMPROOT="/var/tmp" -COREDEF="00_core" - -[ "${VERBOSE}" != "no" ] && echo "Populating volatile Filesystems." - -create_file() { - EXEC=" - touch \"$1\"; - chown ${TUSER}.${TGROUP} $1 || echo \"Failed to set owner -${TUSER}- for -$1-.\" >/dev/tty0 2>&1; - chmod ${TMODE} $1 || echo \"Failed to set mode -${TMODE}- for -$1-.\" >/dev/tty0 2>&1 " - - test "$VOLATILE_ENABLE_CACHE" = yes && echo "$EXEC" >> /etc/volatile.cache - - [ -e "$1" ] && { - [ "${VERBOSE}" != "no" ] && echo "Target already exists. Skipping." - } || { - eval $EXEC - } -} - -mk_dir() { - EXEC=" - mkdir -p \"$1\"; - chown ${TUSER}.${TGROUP} $1 || echo \"Failed to set owner -${TUSER}- for -$1-.\" >/dev/tty0 2>&1; - chmod ${TMODE} $1 || echo \"Failed to set mode -${TMODE}- for -$1-.\" >/dev/tty0 2>&1 " - - test "$VOLATILE_ENABLE_CACHE" = yes && echo "$EXEC" >> /etc/volatile.cache - - [ -e "$1" ] && { - [ "${VERBOSE}" != "no" ] && echo "Target already exists. Skipping." - } || { - eval $EXEC - } -} - -link_file() { - EXEC="test -e \"$2\" -o -L $2 || ln -s \"$1\" \"$2\" >/dev/tty0 2>&1" - - test "$VOLATILE_ENABLE_CACHE" = yes && echo " $EXEC" >> /etc/volatile.cache - - [ -e "$2" ] && { - echo "Cannot create link over existing -${TNAME}-." >&2 - } || { - eval $EXEC - } -} - -check_requirements() { - - cleanup() { - rm "${TMP_INTERMED}" - rm "${TMP_DEFINED}" - rm "${TMP_COMBINED}" - } - - CFGFILE="$1" - - [ `basename "${CFGFILE}"` = "${COREDEF}" ] && return 0 - - TMP_INTERMED="${TMPROOT}/tmp.$$" - TMP_DEFINED="${TMPROOT}/tmpdefined.$$" - TMP_COMBINED="${TMPROOT}/tmpcombined.$$" - - - cat /etc/passwd | sed 's@\(^:\)*:.*@\1@' | sort | uniq > "${TMP_DEFINED}" - cat ${CFGFILE} | grep -v "^#" | cut -d " " -f 2 > "${TMP_INTERMED}" - cat "${TMP_DEFINED}" "${TMP_INTERMED}" | sort | uniq > "${TMP_COMBINED}" - - NR_DEFINED_USERS="`cat "${TMP_DEFINED}" | wc -l`" - NR_COMBINED_USERS="`cat "${TMP_COMBINED}" | wc -l`" - - [ "${NR_DEFINED_USERS}" -ne "${NR_COMBINED_USERS}" ] && { - echo "Undefined users:" - diff "${TMP_DEFINED}" "${TMP_COMBINED}" | grep "^>" - cleanup - return 1 - } - - - cat /etc/group | sed 's@\(^:\)*:.*@\1@' | sort | uniq > "${TMP_DEFINED}" - cat ${CFGFILE} | grep -v "^#" | cut -d " " -f 3 > "${TMP_INTERMED}" - cat "${TMP_DEFINED}" "${TMP_INTERMED}" | sort | uniq > "${TMP_COMBINED}" - - NR_DEFINED_GROUPS="`cat "${TMP_DEFINED}" | wc -l`" - NR_COMBINED_GROUPS="`cat "${TMP_COMBINED}" | wc -l`" - - [ "${NR_DEFINED_GROUPS}" -ne "${NR_COMBINED_GROUPS}" ] && { - echo "Undefined groups:" - diff "${TMP_DEFINED}" "${TMP_COMBINED}" | grep "^>" - cleanup - return 1 - } - - # Add checks for required directories here - - cleanup - return 0 - } - -apply_cfgfile() { - - CFGFILE="$1" - - check_requirements "${CFGFILE}" || { - echo "Skipping ${CFGFILE}" - return 1 - } - - cat ${CFGFILE} | grep -v "^#" | \ - while read LINE; do - - eval `echo "$LINE" | sed -n "s/\(.*\)\ \(.*\) \(.*\)\ \(.*\)\ \(.*\)\ \(.*\)/TTYPE=\1 ; TUSER=\2; TGROUP=\3; TMODE=\4; TNAME=\5 TLTARGET=\6/p"` - - [ "${VERBOSE}" != "no" ] && echo "Checking for -${TNAME}-." - - - [ "${TTYPE}" = "l" ] && { - TSOURCE="$TLTARGET" - [ -L "${TNAME}" ] || { - [ "${VERBOSE}" != "no" ] && echo "Creating link -${TNAME}- pointing to -${TSOURCE}-." - link_file "${TSOURCE}" "${TNAME}" - } - continue - } - - [ -L "${TNAME}" ] && { - [ "${VERBOSE}" != "no" ] && echo "Found link." - NEWNAME=`ls -l "${TNAME}" | sed -e 's/^.*-> \(.*\)$/\1/'` - echo ${NEWNAME} | grep -v "^/" >/dev/null && { - TNAME="`echo ${TNAME} | sed -e 's@\(.*\)/.*@\1@'`/${NEWNAME}" - [ "${VERBOSE}" != "no" ] && echo "Converted relative linktarget to absolute path -${TNAME}-." - } || { - TNAME="${NEWNAME}" - [ "${VERBOSE}" != "no" ] && echo "Using absolute link target -${TNAME}-." - } - } - - case "${TTYPE}" in - "f") [ "${VERBOSE}" != "no" ] && echo "Creating file -${TNAME}-." - create_file "${TNAME}" - ;; - "d") [ "${VERBOSE}" != "no" ] && echo "Creating directory -${TNAME}-." - mk_dir "${TNAME}" - # Add check to see if there's an entry in fstab to mount. - ;; - *) [ "${VERBOSE}" != "no" ] && echo "Invalid type -${TTYPE}-." - continue - ;; - esac - - - done - - return 0 - - } - -SKEL_DIR="/etc/volatile/skel" - -skel_mount() { - VOLATILE="$1" - - [ -d "$VOLATILE" ] || mkdir -p "$VOLATILE" - - mount -t tmpfs volatile "$VOLATILE" -omode=0755 -} - -skel_load() { - VOLATILE="$1" - - if ! skel_mount "$VOLATILE"; then - echo "failed to mount $VOLATILE" - return 1 - fi - - cp -a "$SKEL_DIR"/* "$VOLATILE"/ -} - -skel_update() { - VOLATILE="$1" - - if ! skel_mount "$VOLATILE"; then - echo "failed to update" - return 1 - fi - - echo -n "Populating volatile directory..." - for file in `ls -1 "${CFGDIR}" | sort`; do - apply_cfgfile "${CFGDIR}/${file}" - done - echo "done" - - if [ -d "$SKEL_DIR" ]; then - rm -rf "$SKEL_DIR" - fi - - mkdir -p "$SKEL_DIR"/tmp - cp -a "$VOLATILE"/* "$SKEL_DIR"/ -} - -populate() { - if [ -d "$SKEL_DIR"/tmp ]; then - skel_load /var/volatile - else - skel_update /var/volatile - fi - - for d in /var/volatile/* - do - ln -sf "$d" /var - done - - if ! test -L /tmp; then - rm -rf /tmp - ln -sf /var/tmp /tmp - fi -} - -case "$1" in - start) - if grep -q "^volatile " /proc/mounts; then - echo "volatile directory is already mounted" - else - populate - fi - ;; - stop) - : # no-op - ;; - update) - if skel_update /var/volatile; then - umount /var/volatile - if grep -q "^volatile " /proc/mounts; then - cp -a "$SKEL_DIR"/* /var/volatile - fi - fi - ;; - *) - echo "Usage: /etc/init.d/populate-volatile {start|stop|update}" - ;; -esac - -: exit 0 diff --git a/packages/initscripts/initscripts-openmoko_1.0.bb b/packages/initscripts/initscripts-openmoko_1.0.bb deleted file mode 100644 index d6d233b535..0000000000 --- a/packages/initscripts/initscripts-openmoko_1.0.bb +++ /dev/null @@ -1,111 +0,0 @@ -DESCRIPTION = "Openmoko init scripts" -SECTION = "base" -PRIORITY = "required" -LICENSE = "GPL" -DEPENDS = "" -RDEPENDS = "" - -RCONFLICTS_${PN} = "initscripts" - -SRC_URI = "file://bootmisc.sh \ - file://campgsm \ - file://checkroot.sh \ - file://finish.sh \ - file://functions \ - file://hostname.sh \ - file://led-trigger.sh \ - file://mountall.sh \ - file://mountdevsubfs.sh \ - file://mountkernfs.sh \ - file://mountnfs.sh \ - file://populate-volatile.sh \ - file://devpts \ - file://volatiles \ - file://halt \ - file://reboot \ - file://rmnologin \ - file://save-rtc.sh \ - file://sendsigs \ - file://umountfs \ - file://umountnfs.sh \ - " - -SRC_URI_append_arm = " file://alignment.sh" - -inherit base - -do_install () { -# -# Create directories and install device independent scripts -# - install -d ${D}${sysconfdir}/init.d - install -d ${D}${sysconfdir}/rcS.d - install -d ${D}${sysconfdir}/rc0.d - install -d ${D}${sysconfdir}/rc1.d - install -d ${D}${sysconfdir}/rc2.d - install -d ${D}${sysconfdir}/rc3.d - install -d ${D}${sysconfdir}/rc4.d - install -d ${D}${sysconfdir}/rc5.d - install -d ${D}${sysconfdir}/rc6.d - install -d ${D}${sysconfdir}/default - install -d ${D}${sysconfdir}/default/volatiles - - if [ "${TARGET_ARCH}" = "arm" ]; then - install -m 0755 ${WORKDIR}/alignment.sh ${D}${sysconfdir}/init.d - fi - install -m 0755 ${WORKDIR}/bootmisc.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/campgsm ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/checkroot.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/finish.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/functions ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/hostname.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/led-trigger.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/mountall.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/mountnfs.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/mountdevsubfs.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/mountkernfs.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/populate-volatile.sh ${D}${sysconfdir}/init.d - - install -m 0644 ${WORKDIR}/devpts ${D}${sysconfdir}/default/devpts - install -m 0644 ${WORKDIR}/volatiles ${D}${sysconfdir}/default/volatiles/00_core - - install -m 0755 ${WORKDIR}/halt ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/reboot ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/rmnologin ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/save-rtc.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/sendsigs ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/umountfs ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/umountnfs.sh ${D}${sysconfdir}/init.d - -# -# Create runlevel links -# - ln -sf ../init.d/hostname.sh ${D}${sysconfdir}/rcS.d/S02hostname.sh - ln -sf ../init.d/mountkernfs.sh ${D}${sysconfdir}/rcS.d/S02mountkernfs.sh - ln -sf ../init.d/mountdevsubfs.sh ${D}${sysconfdir}/rcS.d/S04mountdevsubfs.sh - if [ "${TARGET_ARCH}" = "arm" ]; then - ln -sf ../init.d/alignment.sh ${D}${sysconfdir}/rcS.d/S06alignment - fi - #ln -sf ../init.d/campgsm ${D}${sysconfdir}/rcS.d/S07campgsm - ln -sf ../init.d/checkroot.sh ${D}${sysconfdir}/rcS.d/S10checkroot.sh - ln -sf ../init.d/mountall.sh ${D}${sysconfdir}/rcS.d/S35mountall.sh - ln -sf ../init.d/populate-volatile.sh ${D}${sysconfdir}/rcS.d/S37populate-volatile.sh - ln -sf ../init.d/mountnfs.sh ${D}${sysconfdir}/rcS.d/S45mountnfs.sh - ln -sf ../init.d/bootmisc.sh ${D}${sysconfdir}/rcS.d/S55bootmisc.sh - ln -sf ../init.d/led-trigger.sh ${D}${sysconfdir}/rcS.d/S97led-trigger.sh - ln -sf ../init.d/finish.sh ${D}${sysconfdir}/rcS.d/S99finish.sh - - ln -sf ../init.d/rmnologin ${D}${sysconfdir}/rc5.d/S99rmnologin - - ln -sf ../init.d/sendsigs ${D}${sysconfdir}/rc0.d/S20sendsigs - ln -sf ../init.d/save-rtc.sh ${D}${sysconfdir}/rc0.d/S25save-rtc.sh - ln -sf ../init.d/umountnfs.sh ${D}${sysconfdir}/rc6.d/S31umountnfs.sh - ln -sf ../init.d/umountfs ${D}${sysconfdir}/rc0.d/S40umountfs - ln -sf ../init.d/halt ${D}${sysconfdir}/rc0.d/S90halt - - ln -sf ../init.d/sendsigs ${D}${sysconfdir}/rc6.d/S20sendsigs - ln -sf ../init.d/save-rtc.sh ${D}${sysconfdir}/rc6.d/S25save-rtc.sh - ln -sf ../init.d/umountnfs.sh ${D}${sysconfdir}/rc6.d/S31umountnfs.sh - ln -sf ../init.d/umountfs ${D}${sysconfdir}/rc6.d/S40umountfs - ln -sf ../init.d/reboot ${D}${sysconfdir}/rc6.d/S90reboot -} diff --git a/packages/initscripts/initscripts-openprotium_1.0.bb b/packages/initscripts/initscripts-openprotium_1.0.bb index e787eede92..1ae398e962 100644 --- a/packages/initscripts/initscripts-openprotium_1.0.bb +++ b/packages/initscripts/initscripts-openprotium_1.0.bb @@ -74,7 +74,7 @@ do_install_append() { rm ${D}${sysconfdir}/rcS.d/S45mountnfs.sh rm ${D}${sysconfdir}/rcS.d/S55bootmisc.sh # rm ${D}${sysconfdir}/rcS.d/S55urandom - rm ${D}${sysconfdir}/rcS.d/S99finish.sh + rm ${D}${sysconfdir}/rcS.d/S99finish rm ${D}${sysconfdir}/rcS.d/S05devices # udev will run at S04 if installed rm ${D}${sysconfdir}/rcS.d/S03sysfs @@ -136,7 +136,7 @@ do_install_append() { # urandom is currently disabled from S 55 (and won't work with tmpfs /var) # ipkg-cl configure runs at S 98 - update-rc.d -r ${D} finish.sh start 99 S . + update-rc.d -r ${D} finish start 99 S . # # User (2-5) links - UNCHANGED diff --git a/packages/initscripts/initscripts-slugos_1.0.bb b/packages/initscripts/initscripts-slugos_1.0.bb index 41b1e97d9d..1b29e8f1af 100644 --- a/packages/initscripts/initscripts-slugos_1.0.bb +++ b/packages/initscripts/initscripts-slugos_1.0.bb @@ -66,7 +66,7 @@ do_install_append() { rm ${D}${sysconfdir}/rcS.d/S45mountnfs.sh rm ${D}${sysconfdir}/rcS.d/S55bootmisc.sh # rm ${D}${sysconfdir}/rcS.d/S55urandom - rm ${D}${sysconfdir}/rcS.d/S99finish.sh + rm ${D}${sysconfdir}/rcS.d/S99finish rm ${D}${sysconfdir}/rcS.d/S05devices # udev will run at S04 if installed rm ${D}${sysconfdir}/rcS.d/S03sysfs @@ -130,7 +130,7 @@ do_install_append() { # urandom is currently disabled from S 55 (and won't work with tmpfs /var) # ipkg-cl configure runs at S 98 - update-rc.d -r ${D} finish.sh start 99 S . + update-rc.d -r ${D} finish start 99 S . # # User (2-5) links - UNCHANGED diff --git a/packages/initscripts/initscripts_1.0.bb b/packages/initscripts/initscripts_1.0.bb index 51725f8708..ad3433a99c 100644 --- a/packages/initscripts/initscripts_1.0.bb +++ b/packages/initscripts/initscripts_1.0.bb @@ -16,7 +16,7 @@ SRC_URI = "file://functions \ file://hostname.sh \ file://mountall.sh \ file://banner \ - file://finish.sh \ + file://finish \ file://bootmisc.sh \ file://mountnfs.sh \ file://reboot \ @@ -56,7 +56,7 @@ do_install () { install -m 0755 ${WORKDIR}/functions ${D}${sysconfdir}/init.d install -m 0755 ${WORKDIR}/bootmisc.sh ${D}${sysconfdir}/init.d install -m 0755 ${WORKDIR}/checkroot.sh ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/finish.sh ${D}${sysconfdir}/init.d + install -m 0755 ${WORKDIR}/finish ${D}${sysconfdir}/init.d install -m 0755 ${WORKDIR}/halt ${D}${sysconfdir}/init.d install -m 0755 ${WORKDIR}/hostname.sh ${D}${sysconfdir}/init.d install -m 0755 ${WORKDIR}/mountall.sh ${D}${sysconfdir}/init.d @@ -113,7 +113,7 @@ do_install () { ln -sf ../init.d/mountnfs.sh ${D}${sysconfdir}/rcS.d/S45mountnfs.sh ln -sf ../init.d/bootmisc.sh ${D}${sysconfdir}/rcS.d/S55bootmisc.sh # ln -sf ../init.d/urandom ${D}${sysconfdir}/rcS.d/S55urandom - ln -sf ../init.d/finish.sh ${D}${sysconfdir}/rcS.d/S99finish.sh + ln -sf ../init.d/finish ${D}${sysconfdir}/rcS.d/S99finish ln -sf ../init.d/devices ${D}${sysconfdir}/rcS.d/S05devices # udev will run at S04 if installed ln -sf ../init.d/sysfs.sh ${D}${sysconfdir}/rcS.d/S03sysfs diff --git a/packages/modutils/files/modutils.sh b/packages/modutils/files/modutils.sh index 9514b1dd4f..89281276fd 100755 --- a/packages/modutils/files/modutils.sh +++ b/packages/modutils/files/modutils.sh @@ -1,26 +1,27 @@ #!/bin/sh LOAD_MODULE=modprobe +[ -f /proc/modules ] || exit 0 +[ -f /etc/modules ] || exit 0 [ -e /sbin/modprobe ] || LOAD_MODULE=insmod -if [ -e /sbin/depmod -a ! -f /lib/modules/`uname -r`/modules.dep ]; then +if [ ! -e /sbin/depmod ]; then + [ -f /lib/modules/`uname -r`/modules.dep ] || LOAD_MODULE=insmod +else [ "$VERBOSE" != no ] && echo "Calculating module dependencies ..." depmod -Ae fi -if [ -f /proc/modules ]; then - if [ -f /etc/modules ]; then - [ "$VERBOSE" != no ] && echo -n "Loading modules: " - while read module args - do - case "$module" in - \#*|"") continue ;; - esac - [ "$VERBOSE" != no ] && echo -n "$module " - eval "$LOAD_MODULE $module $args >/dev/null 2>&1" - done < /etc/modules - [ "$VERBOSE" != no ] && echo - fi -fi +[ "$VERBOSE" != no ] && echo -n "Loading modules: " +(cat /etc/modules; echo; ) | +while read module args +do + case "$module" in + \#*|"") continue ;; + esac + [ "$VERBOSE" != no ] && echo -n "$module " + eval "$LOAD_MODULE $module $args >/dev/null 2>&1" +done +[ "$VERBOSE" != no ] && echo -: exit 0 +exit 0 diff --git a/packages/modutils/modutils-initscripts.bb b/packages/modutils/modutils-initscripts.bb index 07f4810fc6..bf51ca87f6 100644 --- a/packages/modutils/modutils-initscripts.bb +++ b/packages/modutils/modutils-initscripts.bb @@ -2,7 +2,7 @@ SECTION = "base" DESCRIPTION = "modutils configuration files" LICENSE = "PD" SRC_URI = "file://modutils.sh" -PR = "r3" +PR = "r2" INITSCRIPT_NAME = "modutils.sh" INITSCRIPT_PARAMS = "start 20 S ." diff --git a/packages/netbase/netbase/init b/packages/netbase/netbase/init index acc26cba61..8d6b9aa426 100644 --- a/packages/netbase/netbase/init +++ b/packages/netbase/netbase/init @@ -62,12 +62,9 @@ doopt () { case "$1" in start) - # /etc/sysctl.conf is preferred - if [ ! -f /etc/sysctl.conf ]; then - doopt spoofprotect yes - doopt syncookies no - doopt ip_forward no - fi + doopt spoofprotect yes + doopt syncookies no + doopt ip_forward no echo -n "Configuring network interfaces... " ifup -a diff --git a/packages/netbase/netbase/options b/packages/netbase/netbase/options index a1f9d05f75..2000189d19 100644 --- a/packages/netbase/netbase/options +++ b/packages/netbase/netbase/options @@ -1,4 +1,3 @@ -# used only when /etc/sysctl.conf does not exist ip_forward=no spoofprotect=yes syncookies=no diff --git a/packages/netbase/netbase_4.21.bb b/packages/netbase/netbase_4.21.bb index 9d5f2c6826..a0baa81658 100644 --- a/packages/netbase/netbase_4.21.bb +++ b/packages/netbase/netbase_4.21.bb @@ -2,7 +2,7 @@ DESCRIPTION = "This package provides the necessary \ infrastructure for basic TCP/IP based networking." SECTION = "base" LICENSE = "GPL" -PR = "r30" +PR = "r29" inherit update-rc.d diff --git a/packages/procps/procps-3.2.7/procps.init b/packages/procps/procps-3.2.7/procps.init deleted file mode 100644 index 739dcf4be7..0000000000 --- a/packages/procps/procps-3.2.7/procps.init +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -SYSCTL_CONF="/etc/sysctl.conf" -if [ -f "${SYSCTL_CONF}" ]; then - /sbin/sysctl -q -p "${SYSCTL_CONF}" -fi diff --git a/packages/procps/procps-3.2.7/sysctl.conf b/packages/procps/procps-3.2.7/sysctl.conf deleted file mode 100644 index 34e7488bf7..0000000000 --- a/packages/procps/procps-3.2.7/sysctl.conf +++ /dev/null @@ -1,64 +0,0 @@ -# This configuration file is taken from Debian. -# -# /etc/sysctl.conf - Configuration file for setting system variables -# See sysctl.conf (5) for information. -# - -#kernel.domainname = example.com - -# Uncomment the following to stop low-level messages on console -#kernel.printk = 4 4 1 7 - -##############################################################3 -# Functions previously found in netbase -# - -# Uncomment the next two lines to enable Spoof protection (reverse-path filter) -# Turn on Source Address Verification in all interfaces to -# prevent some spoofing attacks -net.ipv4.conf.default.rp_filter=1 -net.ipv4.conf.all.rp_filter=1 - -# Uncomment the next line to enable TCP/IP SYN cookies -#net.ipv4.tcp_syncookies=1 - -# Uncomment the next line to enable packet forwarding for IPv4 -#net.ipv4.ip_forward=1 - -# Uncomment the next line to enable packet forwarding for IPv6 -#net.ipv6.conf.all.forwarding=1 - - -################################################################### -# Additional settings - these settings can improve the network -# security of the host and prevent against some network attacks -# including spoofing attacks and man in the middle attacks through -# redirection. Some network environments, however, require that these -# settings are disabled so review and enable them as needed. -# -# Ignore ICMP broadcasts -#net.ipv4.icmp_echo_ignore_broadcasts = 1 -# -# Ignore bogus ICMP errors -#net.ipv4.icmp_ignore_bogus_error_responses = 1 -# -# Do not accept ICMP redirects (prevent MITM attacks) -#net.ipv4.conf.all.accept_redirects = 0 -#net.ipv6.conf.all.accept_redirects = 0 -# _or_ -# Accept ICMP redirects only for gateways listed in our default -# gateway list (enabled by default) -# net.ipv4.conf.all.secure_redirects = 1 -# -# Do not send ICMP redirects (we are not a router) -#net.ipv4.conf.all.send_redirects = 0 -# -# Do not accept IP source route packets (we are not a router) -#net.ipv4.conf.all.accept_source_route = 0 -#net.ipv6.conf.all.accept_source_route = 0 -# -# Log Martian Packets -#net.ipv4.conf.all.log_martians = 1 -# - -#kernel.shmmax = 141762560 diff --git a/packages/procps/procps_3.2.7.bb b/packages/procps/procps_3.2.7.bb index 724e1fdc67..e6a6573635 100644 --- a/packages/procps/procps_3.2.7.bb +++ b/packages/procps/procps_3.2.7.bb @@ -1,26 +1,16 @@ require procps.inc -PR = "r6" - -inherit update-rc.d - -INITSCRIPT_NAME = "procps.sh" -INITSCRIPT_PARAMS = "start 30 S ." +PR = "r5" SRC_URI += "file://procmodule.patch;patch=1 \ file://psmodule.patch;patch=1 \ - file://linux-limits.patch;patch=1 \ - file://sysctl.conf \ - file://procps.init \ - " + file://linux-limits.patch;patch=1" FILES = "${bindir}/top.${PN} ${base_bindir}/ps.${PN} ${bindir}/uptime.${PN} ${base_bindir}/kill.${PN} \ ${bindir}/free.${PN} ${bindir}/w ${bindir}/watch ${bindir}/pgrep ${bindir}/pmap ${bindir}/pwdx \ ${bindir}/snice ${bindir}/vmstat ${bindir}/slabtop ${bindir}/pkill ${bindir}/skill ${bindir}/tload \ ${base_sbindir}/sysctl.${PN}" -CONFFILES_${PN} = "${sysconfdir}/sysctl.conf" - EXTRA_OEMAKE = "CFLAGS=-I${STAGING_INCDIR} \ CPPFLAGS=-I${STAGING_INCDIR} \ LDFLAGS=-L${STAGING_LIBDIR} -Wl,--rpath-link,${STAGING_LIBDIR} \ @@ -29,11 +19,6 @@ EXTRA_OEMAKE = "CFLAGS=-I${STAGING_INCDIR} \ ldconfig=echo" do_install_append () { - install -d ${D}${sysconfdir} - install -m 0644 ${WORKDIR}/sysctl.conf ${D}${sysconfdir}/sysctl.conf - install -d ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/procps.init ${D}${sysconfdir}/init.d/procps.sh - mv ${D}${bindir}/uptime ${D}${bindir}/uptime.${PN} mv ${D}${bindir}/top ${D}${bindir}/top.${PN} mv ${D}${base_bindir}/kill ${D}${base_bindir}/kill.${PN} diff --git a/packages/sysvinit/sysvinit/openmoko/rc b/packages/sysvinit/sysvinit/openmoko/rc index 1c2c79b6ae..9d28a6890b 100644 --- a/packages/sysvinit/sysvinit/openmoko/rc +++ b/packages/sysvinit/sysvinit/openmoko/rc @@ -18,6 +18,23 @@ . /etc/default/rcS export VERBOSE +startup_progress() { + step=$(($step + $step_change)) + if [ "$num_steps" != "0" ]; then + progress=$((($step * $progress_size / $num_steps) + $first_step)) + else + progress=$progress_size + fi + #echo "PROGRESS is $progress $runlevel $first_step + ($step of $num_steps) $step_change $progress_size" +# FIXME: this should be virtualised and come from a generic boot splash script +# provided by some generic splash handler - be it psplash, exquisite or +# whatever else soa simple install of one splash instead of another works + if type exquisite-write >/dev/null 2>&1; then + EXQUISITE_IPC=/mnt/.exquisite/exquisite exquisite-write "PROGRESS $progress" || true + fi +} + + # # Start script or program. # @@ -28,14 +45,18 @@ startup() { case "$1" in *.sh) # Source shell script for speed. - scriptname=$1 - shift - . $scriptname + ( + trap - INT QUIT TSTP + scriptname=$1 + shift + . $scriptname + ) ;; *) "$@" ;; esac + startup_progress } # Ignore CTRL-C only in this shell, so we can interrupt subprocesses. @@ -62,6 +83,48 @@ startup() { # Is there an rc directory for this new runlevel? if [ -d /etc/rc$runlevel.d ] then + # Find out where in the progress bar the initramfs got to. + PROGRESS_STATE=0 + #if [ -f /dev/.initramfs/progress_state ]; then + # . /dev/.initramfs/progress_state + #fi + + # Split the remaining portion of the progress bar into thirds + progress_size=$(((100 - $PROGRESS_STATE) / 3)) + + case "$runlevel" in + 0|6) + # Count down from -100 to 0 and use the entire bar + first_step=-100 + progress_size=100 + step_change=1 + ;; + S) + # Begin where the initramfs left off and use 2/3 + # of the remaining space + first_step=$PROGRESS_STATE + progress_size=$(($progress_size * 2)) + step_change=1 + ;; + *) + # Begin where rcS left off and use the final 1/3 of + # the space (by leaving progress_size unchanged) + first_step=$(($progress_size * 2 + $PROGRESS_STATE)) + step_change=1 + ;; + esac + + num_steps=0 + for s in /etc/rc$runlevel.d/[SK]*; do + case "${s##/etc/rc$runlevel.d/S??}" in + gdm|xdm|kdm|reboot|halt) + break + ;; + esac + num_steps=$(($num_steps + 1)) + done + step=0 + # First, run the KILL scripts. if [ $previous != N ] then @@ -106,3 +169,13 @@ startup() { esac done fi + + # FIXME: this should be virtualised and come from a generic boot splash script + # provided by some generic splash handler - be it psplash, exquisite or + # whatever else soa simple install of one splash instead of another works + if [ "x$runlevel" != "xS" ]; then + if type exquisite-write >/dev/null 2>&1; then + EXQUISITE_IPC=/mnt/.exquisite/exquisite exquisite-write "QUIT" || true + umount /mnt/.exquisite + fi + fi diff --git a/packages/sysvinit/sysvinit/openmoko/rcS b/packages/sysvinit/sysvinit/openmoko/rcS deleted file mode 100644 index 08dca5dc1e..0000000000 --- a/packages/sysvinit/sysvinit/openmoko/rcS +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/sh -# -# rcS Call all S??* scripts in /etc/rcS.d in -# numerical/alphabetical order. -# -# Version: @(#)/etc/init.d/rcS 2.76 19-Apr-1999 miquels@cistron.nl -# - -exec /etc/init.d/rc S diff --git a/packages/sysvinit/sysvinit_2.86.bb b/packages/sysvinit/sysvinit_2.86.bb index 6e6f98c6ed..c399874b8d 100644 --- a/packages/sysvinit/sysvinit_2.86.bb +++ b/packages/sysvinit/sysvinit_2.86.bb @@ -2,7 +2,7 @@ DESCRIPTION = "System-V like init." SECTION = "base" LICENSE = "GPL" HOMEPAGE = "http://freshmeat.net/projects/sysvinit/" -PR = "r46" +PR = "r44" # USE_VT and SERIAL_CONSOLE are generally defined by the MACHINE .conf. # Set PACKAGE_ARCH appropriately. diff --git a/packages/tasks/task-base.bb b/packages/tasks/task-base.bb index 06fdd24f6c..7151f9eb70 100644 --- a/packages/tasks/task-base.bb +++ b/packages/tasks/task-base.bb @@ -1,5 +1,5 @@ DESCRIPTION = "Merge machine and distro options to create a basic machine task/package" -PR = "r78" +PR = "r79" inherit task diff --git a/packages/tasks/task-boot.bb b/packages/tasks/task-boot.bb index 3d69256e64..3f31185472 100644 --- a/packages/tasks/task-boot.bb +++ b/packages/tasks/task-boot.bb @@ -1,5 +1,5 @@ DESCRIPTION = "Basic task to get a device booting" -PR = "r47" +PR = "r48" inherit task @@ -16,7 +16,6 @@ DISTRO_DEV_MANAGER ?= "${@base_contains("MACHINE_FEATURES", "kernel26", "udev", # sysvinit, upstart # DISTRO_INIT_MANAGER ?= "sysvinit sysvinit-pidof" -DISTRO_INITSCRIPTS ?= "initscripts" # # tinylogin, getty @@ -40,7 +39,7 @@ RDEPENDS_task-boot = "\ base-files \ base-passwd \ busybox \ - ${DISTRO_INITSCRIPTS} \ + initscripts \ ${@base_contains("MACHINE_FEATURES", "keyboard", "keymaps", "", d)} \ modutils-initscripts \ netbase \ diff --git a/packages/tasks/task-openmoko-linux.bb b/packages/tasks/task-openmoko-linux.bb index dbd3a72c45..da787c62c0 100644 --- a/packages/tasks/task-openmoko-linux.bb +++ b/packages/tasks/task-openmoko-linux.bb @@ -1,7 +1,7 @@ DESCRIPTION = "Openmoko: Core system for the Openmoko Linux Distribution" SECTION = "openmoko/base" LICENSE = "MIT" -PR = "r72" +PR = "r71" inherit task @@ -11,9 +11,14 @@ inherit task DESCRIPTION_task-openmoko-linux = "Openmoko: Linux Core Services" RDEPENDS_task-openmoko-linux = "\ task-base \ - udev-static-devices \ + netbase \ + sysfsutils \ + modutils-initscripts \ + module-init-tools-depmod \ rsync \ screen \ + psplash \ fbset \ fbset-modes \ +# update-alternatives \ " diff --git a/packages/udev/files/links.conf b/packages/udev/files/links.conf index a9f8b58b27..8fff922db6 100644 --- a/packages/udev/files/links.conf +++ b/packages/udev/files/links.conf @@ -12,9 +12,6 @@ L MAKEDEV /sbin/MAKEDEV D pts D shm -M null c 1 3 -M console c 5 1 - # Hic sunt leones. M ppp c 108 0 D loop diff --git a/packages/udev/udev-118/openmoko/init b/packages/udev/udev-118/openmoko/init deleted file mode 100644 index e8b2cc57f0..0000000000 --- a/packages/udev/udev-118/openmoko/init +++ /dev/null @@ -1,177 +0,0 @@ -#!/bin/sh -e -### BEGIN INIT INFO -# Provides: udev -# Required-Start: mountkernfs -# Required-Stop: -# Default-Start: S -# Default-Stop: -# Short-Description: Start udevd, populate /dev and load drivers. -### END INIT INFO - -# This script is based on Debian's. - -COLDPLUG=no -COLDPLUG_TARBALL="/lib/udev/devices.tar.gz" - -for x in $(cat /proc/cmdline); do - case $x in - coldplug) - COLDPLUG=yes - ;; - esac -done - -# we need to unmount /dev/pts/ and remount it later over the tmpfs -unmount_devpts() { - if mountpoint -q /dev/pts/; then - umount -n -l /dev/pts/ - fi - - if mountpoint -q /dev/shm/; then - umount -n -l /dev/shm/ - fi -} - -# mount a tmpfs over /dev, if somebody did not already do it -mount_tmpfs() { - if grep -q "/dev tmpfs" /proc/mounts; then - return - fi - - if ! mount -n -o size=$tmpfs_size,mode=0755 -t tmpfs udev /dev; then - echo "udev requires tmpfs support, not started." - exit 1 - fi - - return 0 -} - -create_dev_makedev() { - if [ -e /sbin/MAKEDEV ]; then - ln -sf /sbin/MAKEDEV /dev/MAKEDEV - else - ln -sf /bin/true /dev/MAKEDEV - fi -} - -make_extra_nodes() { - ret=1 - if [ "$(echo /lib/udev/devices/*)" != "/lib/udev/devices/*" ]; then - cp -a /lib/udev/devices/* /$1/ - ret=0 - fi - - [ -e /etc/udev/links.conf ] || return $ret - - grep '^[^#]' /etc/udev/links.conf | \ - while read type name arg1; do - [ "$type" -a "$name" -a ! -e "/$1/$name" -a ! -L "/$1/$name" ] || continue - case "$type" in - L) ln -s $arg1 /$1/$name ;; - D) mkdir -p /$1/$name ;; - M) mknod -m 600 /$1/$name $arg1 ;; - *) echo "links.conf: unparseable line ($type $name $arg1)" >&2 ;; - esac - done - - return $ret -} - -############################################################################## - -[ -x /sbin/udevd ] || exit 0 - -PATH="/sbin:/bin" - -# defaults -tmpfs_size="2M" -udev_root="/dev" - -if [ -e /etc/udev/udev.conf ]; then - . /etc/udev/udev.conf -fi - -############################################################################## - -# When modifying this script, do not forget that between the time that the -# new /dev has been mounted and udevadm trigger has been run there will be -# no /dev/null. This also means that you cannot use the "&" shell command. - -case "$1" in - start) - if [ -e "$udev_root/.udev/" ]; then - if mountpoint -q $udev_root/; then - TMPFS_MOUNTED=1 - else - echo ".udev/ already exists on the static $udev_root!" - fi - fi - - echo > /sys/kernel/uevent_helper - - if [ -z "$TMPFS_MOUNTED" ]; then - unmount_devpts - mount_tmpfs - else - # and clean up the database of the initramfs udev - rm -rf /dev/.udev/ - fi - - # /dev/null must be created before udevd is started - if ! make_extra_nodes "$udev_root"; then - COLDPLUG=yes - fi - if [ ! -f "$COLDPLUG_TARBALL" ]; then - COLDPLUG=yes - fi - - # if this directory is not present /dev will not be updated by udev - mkdir -p /dev/.udev/db/ - - echo "Startting the hotplug events dispatcher" - udevd --daemon - - mkdir -p /dev/.udev/queue/ /dev/.udev/rules.d/ - - create_dev_makedev - - if [ $COLDPLUG != "no" ]; then - echo "Synthesizing the initial hotplug events" - udevadm trigger - - # wait for the udevd childs to finish - echo "Waiting for /dev to be fully populated" - if udevadm settle; then - echo 'done' - else - echo 'timeout' - fi - fi - - ;; - - stop) - echo "Stopping the hotplug events dispatcher" - start-stop-daemon --stop --name udevd --quiet --oknodo - ;; - - restart) - echo "Stopping the hotplug events dispatcher" - start-stop-daemon --stop --name udevd --quiet --oknodo - - echo "Startting the hotplug events dispatcher" - udevd --daemon - ;; - - reload|force-reload) - udevadm control --reload_rules - ;; - - *) - echo "Usage: /etc/init.d/udev {start|stop|restart|reload|force-reload}" - exit 1 - ;; -esac - -exit 0 - diff --git a/packages/udev/udev-static-devices.bb b/packages/udev/udev-static-devices.bb deleted file mode 100644 index f0aab5a6a2..0000000000 --- a/packages/udev/udev-static-devices.bb +++ /dev/null @@ -1,22 +0,0 @@ -DESCRIPTION = "Provide per-machine static nodes of /dev" -RDEPENDS = "udev" - -PR = "r0" - -SRC_URI = "file://udev_static_devices_tarball" - -FILES_${PN} += "${base_libdir}/udev/*" - -do_install () { - install -d ${D}${base_libdir}/udev/devices - if [ -s ${WORKDIR}/udev_static_devices_tarball ]; then - install -m 0644 ${WORKDIR}/udev_static_devices_tarball ${D}${base_libdir}/udev/devices.tar.gz - fi -} - -pkg_postinst () { - ROOT="$D" - if [ -f "$ROOT/lib/udev/devices.tar.gz" ]; then - tar -C "$ROOT/lib/udev" -zxf "$ROOT/lib/udev/devices.tar.gz" || exit $? - fi -} diff --git a/packages/udev/udev-static-devices/om-gta01/udev_static_devices_tarball b/packages/udev/udev-static-devices/om-gta01/udev_static_devices_tarball Binary files differdeleted file mode 100644 index 97f397a468..0000000000 --- a/packages/udev/udev-static-devices/om-gta01/udev_static_devices_tarball +++ /dev/null diff --git a/packages/udev/udev-static-devices/om-gta02/udev_static_devices_tarball b/packages/udev/udev-static-devices/om-gta02/udev_static_devices_tarball Binary files differdeleted file mode 100644 index 24e1a52c95..0000000000 --- a/packages/udev/udev-static-devices/om-gta02/udev_static_devices_tarball +++ /dev/null diff --git a/packages/udev/udev-static-devices/udev_static_devices_tarball b/packages/udev/udev-static-devices/udev_static_devices_tarball deleted file mode 100644 index e69de29bb2..0000000000 --- a/packages/udev/udev-static-devices/udev_static_devices_tarball +++ /dev/null diff --git a/packages/udev/udev_118.bb b/packages/udev/udev_118.bb index 7fcd4c546c..ba82f486c8 100644 --- a/packages/udev/udev_118.bb +++ b/packages/udev/udev_118.bb @@ -3,7 +3,7 @@ DESCRIPTION = "udev is a daemon which dynamically creates and removes device nod the hotplug package and requires a kernel not older than 2.6.12." RPROVIDES_${PN} = "hotplug" -PR = "r5" +PR = "r6" DEFAULT_PREFERENCE = "-118" diff --git a/packages/wireless-tools/wireless-tools/zzz-wireless.if-pre-up b/packages/wireless-tools/wireless-tools/zzz-wireless.if-pre-up index 85fcc87a99..4c8e95bf2a 100644 --- a/packages/wireless-tools/wireless-tools/zzz-wireless.if-pre-up +++ b/packages/wireless-tools/wireless-tools/zzz-wireless.if-pre-up @@ -15,7 +15,7 @@ RETRIES=15 SLEEPTIME=1 # Only sleep if we use DHCP (add others methods seperated by spaces) -ONLY_FOR="dhcp" +ONLY_FOR="static dhcp" if [ -z "$IF_WIRELESS_TYPE" ] && echo "$ONLY_FOR" | grep -q "$METHOD" ; then $IFCONFIG $IFACE up @@ -25,7 +25,7 @@ if [ -z "$IF_WIRELESS_TYPE" ] && echo "$ONLY_FOR" | grep -q "$METHOD" ; then RETRIES=$(($RETRIES-1)) $SLEEP $SLEEPTIME done - + if [ $RETRIES -eq 0 ]; then $LOGGER Timeout waiting for association, continuing anyway... else diff --git a/packages/wireless-tools/wireless-tools_29.bb b/packages/wireless-tools/wireless-tools_29.bb index e5c498bbfa..7f08db81c7 100644 --- a/packages/wireless-tools/wireless-tools_29.bb +++ b/packages/wireless-tools/wireless-tools_29.bb @@ -1,3 +1,3 @@ require wireless-tools.inc -PR = "r1" +PR = "r0" diff --git a/packages/xserver-kdrive-common/xserver-nodm-init.bb b/packages/xserver-kdrive-common/xserver-nodm-init.bb index cba56d55a3..bea21793a6 100644 --- a/packages/xserver-kdrive-common/xserver-nodm-init.bb +++ b/packages/xserver-kdrive-common/xserver-nodm-init.bb @@ -2,7 +2,7 @@ DESCRIPTION = "Simple Xserver Init Script (no dm)" LICENSE = "GPL" SECTION = "x11" PRIORITY = "optional" -PR = "r10" +PR = "r9" SRC_URI = "file://xserver-nodm" S = ${WORKDIR} @@ -18,13 +18,4 @@ do_install() { inherit update-rc.d INITSCRIPT_NAME = "xserver-nodm" -# start earlier under the assumption that xserver takes seconds to start -INITSCRIPT_PARAMS = "start 5 5 2 . stop 20 0 1 6 ." - -pkg_postinst_${PN} () { -if test "x$D" = "x"; then - for f in `ls /etc/rc?.d/S99${INITSCRIPT_NAME} 2>/dev/null`; do - mv $f `dirname $f`/S05${INITSCRIPT_NAME} - done -fi -} +INITSCRIPT_PARAMS = "start 99 5 2 . stop 20 0 1 6 ." diff --git a/packages/xserver-kdrive-common/xserver-nodm-init/xserver-nodm b/packages/xserver-kdrive-common/xserver-nodm-init/xserver-nodm index 28ba65cd52..2251c6aab2 100755 --- a/packages/xserver-kdrive-common/xserver-nodm-init/xserver-nodm +++ b/packages/xserver-kdrive-common/xserver-nodm-init/xserver-nodm @@ -19,13 +19,18 @@ done case "$1" in start) - . /etc/profile - [ -z $LOGNAME ] && export LOGNAME=root && export HOME=/home/root - [ -z $HOME ] && export HOME=/home/$LOGNAME - - - echo "Starting Xserver" - /etc/X11/Xserver & + # We don't want this script to block the rest of the boot process + if [ "$2" != "background" ]; then + $0 $1 background & + else + . /etc/profile + [ -z $LOGNAME ] && export LOGNAME=root && export HOME=/home/root + [ -z $HOME ] && export HOME=/home/$LOGNAME + + + echo "Starting Xserver" + /etc/X11/Xserver & + fi ;; stop) |