diff options
Diffstat (limited to 'packages/opie-init')
24 files changed, 470 insertions, 0 deletions
diff --git a/packages/opie-init/.mtn2git_empty b/packages/opie-init/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/.mtn2git_empty diff --git a/packages/opie-init/opie-init.inc b/packages/opie-init/opie-init.inc new file mode 100644 index 0000000000..04a73cb4ea --- /dev/null +++ b/packages/opie-init/opie-init.inc @@ -0,0 +1,46 @@ +DESCRIPTION = "Opie Startup scripts and config" +SECTION = "opie/base" +PRIORITY = "optional" +LICENSE = "GPL" +#APPNAME = "qpe" + +#S = "${WORKDIR}/launcher" + +#inherit opie +inherit update-rc.d + +INITSCRIPT_NAME = "opie" +INITSCRIPT_PARAMS = "start 99 5 . stop 20 0 1 6 ." + +do_install() { + install -d ${D}${sysconfdir}/init.d + install -d ${D}${sysconfdir}/profile.d + install -d ${D}${bindir} + install -d ${D}${palmtopdir}/etc/skel + + sed -s "s|@palmtopdir@|${palmtopdir}|" ${WORKDIR}/opie >${WORKDIR}/opie.tmp + sed -s "s|@palmtopdir@|${palmtopdir}|" ${WORKDIR}/opie_defaults >${WORKDIR}/opie_defaults.tmp + install -m 0755 ${WORKDIR}/opie.tmp ${D}${sysconfdir}/init.d/opie + install -m 0644 ${WORKDIR}/opie_defaults.tmp ${D}${sysconfdir}/profile.d/opie_defaults + + install -m 0755 ${WORKDIR}/opie-reorgfiles ${D}${bindir}/ + install -m 0644 ${WORKDIR}/qpe.conf ${D}${palmtopdir}/etc/skel/ + + if [ -s ${WORKDIR}/locale.conf ]; then + install -m 0644 ${WORKDIR}/locale.conf ${D}${palmtopdir}/etc/skel/ + fi + + case ${MACHINE} in + c7x0) + install -d ${D}${sysconfdir}/apm/event.d/ + install -m 0755 ${WORKDIR}/qpe-suspend-resume ${D}${sysconfdir}/apm/event.d/00-qpe-suspend-resume.sh + ;; + *) + ;; + esac +} + +#FILES_opie-init_append = " ${sysconfdir} ${palmtopdir}/bin" +FILES_${PN} += "${palmtopdir}" + +PACKAGE_ARCH = "${MACHINE_ARCH}" diff --git a/packages/opie-init/opie-init/.mtn2git_empty b/packages/opie-init/opie-init/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/.mtn2git_empty diff --git a/packages/opie-init/opie-init/akita/.mtn2git_empty b/packages/opie-init/opie-init/akita/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/akita/.mtn2git_empty diff --git a/packages/opie-init/opie-init/akita/qpe.conf b/packages/opie-init/opie-init/akita/qpe.conf new file mode 100644 index 0000000000..e9922e4d86 --- /dev/null +++ b/packages/opie-init/opie-init/akita/qpe.conf @@ -0,0 +1,22 @@ +[Appearance] +useBigPixmaps = 1 +SmallIconSize = 32 +BigIconSize = 48 +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 16 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 14 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = Windows +Text = #000000 +TabStyle = 1 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init/c7x0/.mtn2git_empty b/packages/opie-init/opie-init/c7x0/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/c7x0/.mtn2git_empty diff --git a/packages/opie-init/opie-init/c7x0/qpe-suspend-resume b/packages/opie-init/opie-init/c7x0/qpe-suspend-resume new file mode 100644 index 0000000000..be37519512 --- /dev/null +++ b/packages/opie-init/opie-init/c7x0/qpe-suspend-resume @@ -0,0 +1,33 @@ +#!/bin/sh + +QTDIR=/opt/QtPalmtop +LD_LIBRARY_PATH=$QTDIR +export LD_LIBRARY_PATH QTDIR +LOGGING=0 +log() { + if [ $LOGGING -eq 1 ]; then + echo "$(date +%y/%m/%d-%H:%m:%S): $@" >> /var/log/qte.log + fi +} + +retcode=1 +tries=3 + +if [ "$1" = suspend ]; then + while [ $retcode -ne 0 -a $tries -gt 0 ]; do + log "-> $QTDIR/bin/qcop QPE/System 'aboutToSuspend()'" + $QTDIR/bin/qcop QPE/System 'aboutToSuspend()' + retcode=$? + tries=`expr $tries - 1` + log "<- Result $retcode" + done +elif [ "$1" = resume ]; then + while [ $retcode -ne 0 -a $tries -gt 0 ]; do + log "-> $QTDIR/bin/qcop QPE/System 'returnFromSuspend()'" + $QTDIR/bin/qcop QPE/System 'returnFromSuspend()' + retcode=$? + tries=`expr $tries - 1` + log "<- Result $retcode" + done +fi + diff --git a/packages/opie-init/opie-init/c7x0/qpe.conf b/packages/opie-init/opie-init/c7x0/qpe.conf new file mode 100644 index 0000000000..e9922e4d86 --- /dev/null +++ b/packages/opie-init/opie-init/c7x0/qpe.conf @@ -0,0 +1,22 @@ +[Appearance] +useBigPixmaps = 1 +SmallIconSize = 32 +BigIconSize = 48 +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 16 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 14 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = Windows +Text = #000000 +TabStyle = 1 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init/htcuniversal/.mtn2git_empty b/packages/opie-init/opie-init/htcuniversal/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/htcuniversal/.mtn2git_empty diff --git a/packages/opie-init/opie-init/htcuniversal/qpe.conf b/packages/opie-init/opie-init/htcuniversal/qpe.conf new file mode 100644 index 0000000000..e9922e4d86 --- /dev/null +++ b/packages/opie-init/opie-init/htcuniversal/qpe.conf @@ -0,0 +1,22 @@ +[Appearance] +useBigPixmaps = 1 +SmallIconSize = 32 +BigIconSize = 48 +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 16 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 14 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = Windows +Text = #000000 +TabStyle = 1 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init/locale.conf b/packages/opie-init/opie-init/locale.conf new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/locale.conf diff --git a/packages/opie-init/opie-init/mnci/.mtn2git_empty b/packages/opie-init/opie-init/mnci/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/mnci/.mtn2git_empty diff --git a/packages/opie-init/opie-init/mnci/qpe.conf b/packages/opie-init/opie-init/mnci/qpe.conf new file mode 100644 index 0000000000..8efe771ad0 --- /dev/null +++ b/packages/opie-init/opie-init/mnci/qpe.conf @@ -0,0 +1,25 @@ +[Appearance] +Decoration = libflat.so +FontFamily = vera +FontSize = 10 +FontStyle = Regular +LeftHand = 0 +Style = libflatstyle.so +rotatedir = 0 +[Battery] +[Date] +ClockApplet = 0 +LongOrder = 273 +Separator = . +ShortOrder = 273 +[InputMethod] +current = Multikey +[Keyboard] +[Startup] +FirstUse = 0 +[Time] +AMPM = 0 +MONDAY = 1 +[Volume] +[Wireless] +UpdateFrequency = 2 diff --git a/packages/opie-init/opie-init/opie b/packages/opie-init/opie-init/opie new file mode 100755 index 0000000000..d7e06e5ce2 --- /dev/null +++ b/packages/opie-init/opie-init/opie @@ -0,0 +1,102 @@ +#!/bin/sh +# +[ -z $LOGNAME ] && export LOGNAME=root && export HOME=/home/root +[ -z $HOME ] && export HOME=/home/$LOGNAME + +export QTDIR="@palmtopdir@" +export OPIEDIR="$QTDIR" +export QPEDIR="$QTDIR" +export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OPIEDIR/lib +export PATH=$PATH:$OPIEDIR/bin +# Following is from c7x0 override, check for validity, etc. +## we need to tinker directly with qws_display until the ODevice +## default (which is now W100:Rot0:0) works flawlessly with rotation +## and survives a suspend/resume cycle +#export QWS_DISPLAY=Transformed:Rot0:0 +## export QWS_DISPLAY=W100:Rot0:0 + +if [ -z `which qpe` ] ; then + echo Opie not installed + exit 0 +fi + +. /etc/profile + +if [ ! -e $TSLIB_TSDEVICE ]; then + export QWS_MOUSE_PROTO=MouseMan:/dev/input/mice +fi + +for conf in $OPIEDIR/etc/skel/*.conf; do + conf_basename=`basename $conf` + if [ ! -e "$HOME/Settings/$conf_basename" ] ; then + echo "Copying default $conf_basename into $HOME/Settings/" + mkdir -p $HOME/Settings/ + cat $conf >$HOME/Settings/$conf_basename + fi +done + +if [ ! -e "$HOME/systeminfo/linkver" ] ; then + mkdir -p $HOME/systeminfo/ + echo "1.13" >$HOME/systeminfo/linkver +fi + +case $1 in +'start') + # Turn off psplash if any - sleep is required for anti-race + if [ -e /mnt/.psplash ]; then + TMPDIR=/mnt/.psplash psplash-write "QUIT" || true + sleep 1 + fi + + if [ -x "$OPIEDIR/bin/opie-login" ]; then + echo Starting Opie-login.... + $OPIEDIR/bin/opie-login -terminal 3 + else + opie-reorgfiles + + if [ -x "$OPIEDIR/bin/opie-sh-ssh-askpass.sh" ]; then + export SSH_ASKPASS=$OPIEDIR/bin/opie-sh-ssh-askpass.sh + fi + echo Starting Opie.... + ( + test -x /usr/bin/ssh-agent && eval $(/usr/bin/ssh-agent -s) && echo $SSH_AGENT_PID>/var/run/opie-ssh-agent.pid ; + qpe -terminal 3 + ) + echo -n >/var/log/opie-qss.log + { for attempt in 0 1 2 3 4 5 6 7 8 9 a b c d e f ; do + sleep 1 + echo "Waiting for qcop to startup: $attempt ..." >>/var/log/opie-qss.log + qcop QPE/System 'ping()' || continue + echo "Starting qss" >>/var/log/opie-qss.log + qss </dev/null >>/var/log/opie-qss.log 2>&1 + echo "qss exited, will try to restart" >>/var/log/opie-qss.log + done; rm /var/run/opie-qss-loop.pid; } </dev/null >/dev/null 2>&1 & + echo $! >/var/run/opie-qss-loop.pid + fi + + ;; + +'stop') + echo "Stopping Opie..." + test -r /var/run/opie-qss-loop.pid && kill $(cat /var/run/opie-qss-loop.pid) 2>/dev/null ; rm -f /var/run/opie-qss-loop.pid + killall qss 2>/dev/null + killall qpe 2>/dev/null + killall opie-login 2>/dev/null + killall quicklauncher 2>/dev/null + test -r /var/run/opie-ssh-agent.pid && kill $(cat /var/run/opie-ssh-agent.pid) 2>/dev/null ; rm -f /var/run/opie-ssh-agent.pid + true + + ;; + +'restart') + $0 stop && $0 start + + ;; + +*) + echo "usage: $0 { start | stop | restart }" + + ;; + +esac + diff --git a/packages/opie-init/opie-init/opie-reorgfiles b/packages/opie-init/opie-init/opie-reorgfiles new file mode 100755 index 0000000000..96b3e29da4 --- /dev/null +++ b/packages/opie-init/opie-init/opie-reorgfiles @@ -0,0 +1,93 @@ +#!/bin/sh + +APPS=$HOME/Applications +DOCS=$HOME/Documents + +if [ -d $APPS -a "$1" != "-f" ] +then + echo "You seem to already have a $APPS directory." + echo "Assuming it is the Opie Applications directory. Exiting." + exit 0 +fi + +if [ -d $HOME/Apps ] +then + mv $HOME/Apps $APPS +else + mkdir $APPS +fi + +if [ -f $DOCS/addressbook.xml ] +then + if [ -f $APPS/addressbook/addressbook.xml ] + then + echo "$DOCS/addressbook.xml conflicts with $APPS/addressbook/addressbook.xml" + echo "Moving $DOCS/addressbook.xml to $HOME" + mv $DOCS/addressbook.xml $HOME + else + mkdir $APPS/addressbook + mv $DOCS/addressbook.xml $APPS/addressbook + fi +fi + +if [ -f $DOCS/datebooksettings.xml ] +then + echo "$DOCS/datebooksettings.xml is obsolete" + echo "Please re-set your datebook preferences" + rm $DOCS/datebooksettings.xml +fi + +if [ -f $DOCS/datebook.xml ] +then + mkdir $APPS/databook + mv $DOCS/datebook.xml $APPS/databook +fi + +if [ -d $DOCS/qtmail ] +then + mv $DOCS/qtmail $APPS/ +fi + +if [ -f $DOCS/todo.xml ] +then + if [ -f $APPS/todolist/todolist.xml ] + then + mv $DOCS/todo.xml $HOME + echo "$DOCS/todo.xml is superceded by $APPS/todolist/todolist.xml" + echo "$DOCS/todo.xml has been moved to $HOME" + else + echo "NOTE: $DOCS/todo.xml is obsolete. It will move to $APPS/todolist/todolist.xml" + echo "when next you run the latest ToDo application." + fi +fi + +if [ ! -d $APPS/qimpen ] +then + mkdir $APPS/qimpen +fi + +if [ -f $DOCS/asciilower.qpt ] +then + mv $DOCS/asciilower.qpt $APPS/qimpen +fi + +if [ -f $DOCS/asciiupper.qpt ] +then + mv $DOCS/asciiupper.qpt $APPS/qimpen +fi + +if [ -f $DOCS/numeric.qpt ] +then + mv $DOCS/numeric.qpt $APPS/qimpen +fi + +if [ -d "$HOME/.qpe" ] +then + if [ -d "$HOME/Settings" ] + then + mv $HOME/.qpe/* "$HOME/Settings" + rmdir "$HOME/.qpe" + else + mv $HOME/.qpe "$HOME/Settings" + fi +fi diff --git a/packages/opie-init/opie-init/opie_defaults b/packages/opie-init/opie-init/opie_defaults new file mode 100644 index 0000000000..c4d127db33 --- /dev/null +++ b/packages/opie-init/opie-init/opie_defaults @@ -0,0 +1,15 @@ +#!/bin/sh + +MACHINE="`cat /proc/cpuinfo | sed -n "/^Hardware/s/.*\:\(.*\)/\1/;s/^\ //p"`" +KVER="`uname -r | sed -n "s/\([0-9]\)\.\([0-9]\)\..*/\1.\2/p"`" + +case "$MACHINE" in +*Poodle) test "$KVER" = "2.6" && export QWS_CURSOR_ROTATION=90;; +esac + +export QTDIR="@palmtopdir@" +export OPIEDIR="$QTDIR" +export QPEDIR="$QTDIR" +export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$OPIEDIR/lib" +export PATH="$PATH:$OPIEDIR/bin" + diff --git a/packages/opie-init/opie-init/qpe.conf b/packages/opie-init/opie-init/qpe.conf new file mode 100644 index 0000000000..59bb20c762 --- /dev/null +++ b/packages/opie-init/opie-init/qpe.conf @@ -0,0 +1,18 @@ +[Appearance] +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 9 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 9 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = libphasestyle.so +Text = #000000 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init/simpad/.mtn2git_empty b/packages/opie-init/opie-init/simpad/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/simpad/.mtn2git_empty diff --git a/packages/opie-init/opie-init/simpad/qpe.conf b/packages/opie-init/opie-init/simpad/qpe.conf new file mode 100644 index 0000000000..b10d90b94e --- /dev/null +++ b/packages/opie-init/opie-init/simpad/qpe.conf @@ -0,0 +1,18 @@ +[Appearance] +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 12 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 12 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = libphasestyle.so +Text = #000000 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init/spitz/.mtn2git_empty b/packages/opie-init/opie-init/spitz/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/spitz/.mtn2git_empty diff --git a/packages/opie-init/opie-init/spitz/qpe.conf b/packages/opie-init/opie-init/spitz/qpe.conf new file mode 100644 index 0000000000..e9922e4d86 --- /dev/null +++ b/packages/opie-init/opie-init/spitz/qpe.conf @@ -0,0 +1,22 @@ +[Appearance] +useBigPixmaps = 1 +SmallIconSize = 32 +BigIconSize = 48 +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 16 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 14 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = Windows +Text = #000000 +TabStyle = 1 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init/tosa/.mtn2git_empty b/packages/opie-init/opie-init/tosa/.mtn2git_empty new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/opie-init/opie-init/tosa/.mtn2git_empty diff --git a/packages/opie-init/opie-init/tosa/qpe.conf b/packages/opie-init/opie-init/tosa/qpe.conf new file mode 100644 index 0000000000..e9922e4d86 --- /dev/null +++ b/packages/opie-init/opie-init/tosa/qpe.conf @@ -0,0 +1,22 @@ +[Appearance] +useBigPixmaps = 1 +SmallIconSize = 32 +BigIconSize = 48 +FontFamily = DejaVu_Sans +FontStyle = Regular +FontSize = 16 +FixedFontFamily = DejaVu_Sans_Mono +FixedFontStyle = Regular +FixedFontSize = 14 +Background = #d5d0de +Base = #ffffff +Button = #e3e3e3 +ButtonText = #000000 +Decoration = libliquid.so +Highlight = #52719c +HighlightedText = #ffffff +Style = Windows +Text = #000000 +TabStyle = 1 +[InputMethod] +current = Multikey diff --git a/packages/opie-init/opie-init_1.2.2.bb b/packages/opie-init/opie-init_1.2.2.bb new file mode 100644 index 0000000000..b52e162e50 --- /dev/null +++ b/packages/opie-init/opie-init_1.2.2.bb @@ -0,0 +1,10 @@ +require ${PN}.inc +PR = "r8" + +SRC_URI = "file://opie-reorgfiles \ + file://opie \ + file://qpe.conf \ + file://locale.conf \ + file://opie_defaults" + +SRC_URI_append_c7x0 = " file://qpe-suspend-resume" |