summaryrefslogtreecommitdiffstats
path: root/move/tree
diff options
context:
space:
mode:
authorMystery Man <unknown@mandriva.org>2005-08-22 14:57:05 +0000
committerMystery Man <unknown@mandriva.org>2005-08-22 14:57:05 +0000
commitc4c6eb3de2799d5544e9cc8703b0261c0a3350d6 (patch)
treeb9f1a4c99ae89c4210c2c2848b16e66430b63700 /move/tree
parenta723a6e26fc5be438675cc29b636f0b61547ec32 (diff)
downloaddrakx-10_3_0_48mdk.tar
drakx-10_3_0_48mdk.tar.gz
drakx-10_3_0_48mdk.tar.bz2
drakx-10_3_0_48mdk.tar.xz
drakx-10_3_0_48mdk.zip
This commit was manufactured by cvs2svn to create tagV10_3_0_48mdk
'V10_3_0_48mdk'.
Diffstat (limited to 'move/tree')
-rwxr-xr-xmove/tree/X_move16
-rwxr-xr-xmove/tree/alsa_default.pl19
-rwxr-xr-xmove/tree/halt5
-rw-r--r--move/tree/kdedrc7
-rw-r--r--move/tree/konsolerc19
-rwxr-xr-xmove/tree/mdk_behind_totem106
-rw-r--r--move/tree/mdk_move_boot_loop.desktop8
-rwxr-xr-xmove/tree/mdk_move_loop56
-rwxr-xr-xmove/tree/mdk_totem125
-rw-r--r--move/tree/mdk_totem.desktop12
-rwxr-xr-xmove/tree/netscape3
-rwxr-xr-xmove/tree/reboot5
-rwxr-xr-xmove/tree/sound.initscript116
-rwxr-xr-xmove/tree/startkde_move17
-rw-r--r--move/tree/sudoers1
-rwxr-xr-xmove/tree/wait4x21
16 files changed, 0 insertions, 536 deletions
diff --git a/move/tree/X_move b/move/tree/X_move
deleted file mode 100755
index dde4bcc32..000000000
--- a/move/tree/X_move
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/bash
-
-ok=0
-lastdate1=0
-lastdate0=0
-while [ "$ok" == 0 -a ! -s /var/run/rebootctl ]; do
- lastdate2=$lastdate1
- lastdate1=$lastdate0
- lastdate0=`date +%s`
- if [ `expr $lastdate0 - $lastdate2` -lt 40 ]; then
- echo "X server respawning too fast :(, dropping to a shell"
- bash
- fi
- X $@
- ok=$?
-done
diff --git a/move/tree/alsa_default.pl b/move/tree/alsa_default.pl
deleted file mode 100755
index 28b06cc04..000000000
--- a/move/tree/alsa_default.pl
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/usr/bin/perl -pi
-
-# state machine:
-if (/\s*control\./) {
- ($min, $max) = (0, 0);
-} elsif (/\s*name '/) {
- # skip masks and blacklist sb live and the like:
- $ignore = /\s*name '.*(3D Control|AC97 Playback Volume|Audigy Analog\/Digital Output Jack|External Amplifier Power Down|Exchange DAC|IEC958 input monitor|IEC958 Capture Monitor|IEC958 Playback Switch|mask|Mic Boost \(\+20dB\)|Mic Playback Switch|Output Jack|Surround down mix)/i;
-} elsif (!$ignore) {
- if (/s*comment.range '(\d+) - (\d+)'/) {
- ($min, $max) = ($1, $2);
- } elsif (/s*value/) {
- # enable switches:
- s/(value\w*\S*)\s* false/\1 true/;
- # set volume to 80%:
- my $val = int($max*0.8);
- s/(value\w*\S*)\s* \d+/\1 $val/;
- }
-}
diff --git a/move/tree/halt b/move/tree/halt
deleted file mode 100755
index c8431ac03..000000000
--- a/move/tree/halt
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-
-echo "halt" > /var/run/rebootctl
-sudo killall -USR1 startkde_move
-sudo killall X
diff --git a/move/tree/kdedrc b/move/tree/kdedrc
deleted file mode 100644
index a58482a55..000000000
--- a/move/tree/kdedrc
+++ /dev/null
@@ -1,7 +0,0 @@
-[General]
-CheckSycoca=false
-CheckUpdates=false
-CheckHostname=false
-
-[Move]
-Rebuild=false
diff --git a/move/tree/konsolerc b/move/tree/konsolerc
deleted file mode 100644
index fb7658ad3..000000000
--- a/move/tree/konsolerc
+++ /dev/null
@@ -1,19 +0,0 @@
-[Desktop Entry]
-ActiveSession=0
-DefaultSession=shell.desktop
-Height 600=410
-Width 800=582
-bellmode=1
-defaultfont=Fixed,13,-1,5,48,0,0,0,1,0
-history=0
-historyenabled=true
-keytab=default
-
-[konsole-mainwindow#1 Toolbar style]
-Hidden=false
-IconSize=22
-IconText=IconOnly
-Index=0
-NewLine=false
-Offset=-1
-Position=Bottom
diff --git a/move/tree/mdk_behind_totem b/move/tree/mdk_behind_totem
deleted file mode 100755
index 028077821..000000000
--- a/move/tree/mdk_behind_totem
+++ /dev/null
@@ -1,106 +0,0 @@
-#!/bin/bash
-
-ok=1
-
-while [ -n "$1" ]; do
- case "$1" in
- --lang)
- lang="$2"
- shift
- shift
- ;;
- --i18n-loop)
- i18n_loop="$2"
- shift
- shift
- ;;
- --boot-loop)
- boot_loop="$2"
- shift
- shift
- ;;
- --main-loop)
- main_loop="$2"
- shift
- shift
- ;;
- --totem-pid)
- totem_pid="$2"
- shift
- shift
- ;;
- --user)
- USER="$2"
- shift
- shift
- ;;
- --restore-cmd)
- RESTORE_CMD="$2"
- shift
- shift
- ;;
- *)
- ok=''
- shift
- esac
-done
-
-if [ -z "$totem_pid" -o -z "$ok" ]; then
- printf "Usage: mdk_behind_totem [--boot-loop <loop>] [--main-loop <loop>] --totem-pid <pid>\n"
- exit 1
-fi
-
-exec &> /tmp/mdk_behind_totem.log
-
-trap 'umount_cd' USR1
-
-umount_cd() {
- echo umount_cd
-
- umount /image_i18n_$lang
- losetup -d /dev/$i18n_loop
-
- umount /image_boot
- losetup -d /dev/$boot_loop
-
- ln -sf /image_always/lib /
-
- if [ -L /image ]; then
- rm -f /image
- else
- umount /image && \
- /image_always/sbin/losetup -d /dev/$main_loop || { mount_cd; kill $totem_pid; exec mdk_totem; }
- fi
-
- /image_always/usr/bin/eject
-}
-
-mount_cd() {
- echo mount_cd
- if [ -e /cdrom/live_tree.clp ]; then
- /image_always/sbin/losetup -r -e gz /dev/$main_loop /cdrom/live_tree.clp
- /image_always/bin/mount -r /dev/$main_loop /image
- else
- ln -sf /cdrom/live_tree /image
- fi
-
- losetup -r -e gz /dev/$boot_loop /cdrom/live_tree_boot.clp
- mount -r /dev/$boot_loop /image_boot
-
- losetup -r -e gz /dev/$i18n_loop /cdrom/live_tree_i18n_$lang.clp
- mount -r /dev/$i18n_loop /image_i18n_$lang
-
- ln -sf /image/lib /
-
- mdk_move_loop to_cdrom always always_i18n totem nvidia
-
- # restore killed kde apps
- su -c "$RESTORE_CMD" $USER
-}
-
-while [ -e "/proc/$totem_pid" ]; do
- echo "waiting..."
- /image_totem/bin/sleep 1
-done
-
-mount_cd
diff --git a/move/tree/mdk_move_boot_loop.desktop b/move/tree/mdk_move_boot_loop.desktop
deleted file mode 100644
index 5d82a7875..000000000
--- a/move/tree/mdk_move_boot_loop.desktop
+++ /dev/null
@@ -1,8 +0,0 @@
-[Desktop Entry]
-Name=Move Move Loop
-Exec=mdk_move_loop to_cdrom always always_i18n boot totem
-Type=Application
-Terminal=0
-X-KDE-autostart-after=panel
-X-KDE-autostart-after=mdkhtmlbrowser
-X-KDE-StartupNotify=false
diff --git a/move/tree/mdk_move_loop b/move/tree/mdk_move_loop
deleted file mode 100755
index b98c4a417..000000000
--- a/move/tree/mdk_move_loop
+++ /dev/null
@@ -1,56 +0,0 @@
-#!/usr/bin/perl
-
-sub name2file {
- my ($name) = @_;
- "live_tree_$name.clp";
-}
-
-sub get_file2loop {
- my %file2loop;
- foreach (0 .. 9) {
- my ($file) = `sudo losetup /dev/loop$_ 2>/dev/null` =~ m!\([^)]*/([^)]*)\)! or last;
- $file2loop{$file} = "loop$_";
- }
- %file2loop;
-}
-
-sub to_memory {
- my ($loop, $file) = @_;
-
- return if -e "/tmp/$file";
-
- if (-e "/$file") {
- system("sudo mv /$file /tmp");
- } else {
- system("sudo cp /cdrom/$file /tmp");
- }
- system("sudo losetup /dev/$loop /tmp/$file");
-}
-
-sub to_cdrom {
- my ($loop, $file) = @_;
- my $f = -e "/$file" ? "/$file" : -e "/tmp/$file" ? "/tmp/$file" : return;
- system("sudo losetup /dev/$loop /cdrom/$file");
- system("sudo rm $f");
-}
-
-sub usage() { die "usage: mdk_move_loop <to_cdrom | to_memory> [names ...]\n" }
-
-my ($direction, @names) = @ARGV;
-my $f = $direction eq 'to_memory' && \&to_memory || $direction eq 'to_cdrom' && \&to_cdrom;
-$f && @names or usage();
-
-my %file2loop = get_file2loop(@names);
-
-foreach my $name (@names) {
- if ($name eq 'always_i18n') {
- /(always_i18n.*)\.clp/ and $name = $1 foreach keys %file2loop;
- }
- my $file = name2file($name);
- my $loop = $file2loop{$file} or next;
- $f->($loop, $file);
-}
-
-if ($ENV{GIVE_LOOP}) {
- print "$_=$file2loop{$_}\n" foreach keys %file2loop;
-}
diff --git a/move/tree/mdk_totem b/move/tree/mdk_totem
deleted file mode 100755
index 0a54248ac..000000000
--- a/move/tree/mdk_totem
+++ /dev/null
@@ -1,125 +0,0 @@
-#!/usr/bin/perl
-
-use lib qw(../../perl-install /usr/lib/libDrakX);
-use common;
-use interactive;
-
-sub busy_pids_and_files() {
- my @pids = grep { $_ ne $$ && /^(\d+)$/ } all('/proc');
-
- map {
-
- my @l1 = grep {
- $_ && !m!^(/proc/|/dev/|pipe:|socket:)!;
- } map { readlink($_) } "/proc/$_/exe", glob_("/proc/$_/fd/*");
-
- my @l2 = grep { $_ } map { (split)[5] } cat_("/proc/$_/maps");
-
- if (my @l = grep { m!^/(image(_boot)?|cdrom/live_tree)/! } @l1, @l2) {
- my $cmdline = join(' ', split('\0', cat_("/proc/$_/cmdline")));
- my $exe = readlink("/proc/$_/exe");
- { pid => $_, cmdline => $cmdline, exe => $exe, files => [ sort(uniq(@l)) ] };
- } else {
- ();
- }
- } @pids;
-}
-
-my @to_restart_progs = qw(kded kdesktop kicker);
-my $restart_progs = join(";", @to_restart_progs);
-my @simple_daemons = qw(kdesud kio_uiserver klaptopdaemon artsd portmap);
-sub simple_daemon {
- my ($e) = @_;
- my $re = join('|', @to_restart_progs, @simple_daemons);
- $e->{cmdline} =~ m!\b($re)\b!
-}
-
-my $in = interactive->vnew;
-
-my @busy = busy_pids_and_files();
-
-my $needed_processes = join('|', map { quotemeta }
- 'init',
- 'xfs',
- 'kdeinit: Running...',
- '/etc/X11/X',
- '/sbin/devfsd',
- );
-
-if (!$ENV{DEBUG} && find { $_->{cmdline} =~ /^($needed_processes)/ } @busy) {
- exec 'totem' if $in->ask_okcancel('', N("You can only run with no CDROM support"));
- $in->exit(1);
-}
-
-my ($simple_daemons, $bad_busy) = partition { simple_daemon($_) } @busy;
-if (@$bad_busy) {
- warn '*' x 80, "\n";
- warn join("\n", "$_->{exe} ($_->{cmdline}) =>", map { " $_" } @{$_->{files}}) . "\n" foreach @$bad_busy;
- warn '*' x 80, "\n";
-
- my @progs = map {
- my $s = $_->{cmdline};
- $s =~ s!^/usr/bin/perl\s+([^-]\S*).*!$1!;
- $s =~ s!/.*/!!;
- $s =~ s!^kdeinit:\s+(\S+).*!$1!;
- $s =~ s!\s.*!!;
- $s;
- } @$bad_busy;
-
- my $choice = 'quit';
- my @l = my %l = (
- kill => N("Kill those programs"),
- keep => N("No CDROM support"),
- );
-
- $in->ask_from_({
- title => N("Read carefully!"),
- messages => N("You can not use another CDROM when the following programs are running:
-%s", join(", ", uniq(sort @progs))) },
- [ { type => 'list', val => \$choice, list => first(list2kv(@l)), format => sub { $l{$_[0]} } } ]) or $in->exit;
-
- if ($choice eq 'keep') {
- exec 'totem' or $in->exit;
- } else {
- system('sudo', 'kill', map { $_->{pid} } @$bad_busy);
- sleep 2;
- system('sudo', 'kill', '-9', map { $_->{pid} } @$bad_busy);
- }
-}
-
-kill 15, map { $_->{pid} } @$simple_daemons;
-sleep 1;
-
-@busy = busy_pids_and_files(); #- update list
-if (@busy) {
- system($restart_progs);
- exec 'totem' if $in->ask_okcancel('', N("You can only run with no CDROM support"));
- $in->exit(1);
-}
-
-my %file2loop = do {
- my $_w = $in->wait_message('', N("Copying to memory to allow removing the CDROM"));
- `GIVE_LOOP=1 mdk_move_loop to_memory always always_i18n totem nvidia` =~ /(.*?)=(.*)/g;
-};
-
-ugtk2::gtkset_mousecursor_normal(); #- for restoring a normal in any case
-ugtk2::flush();
-
-my ($lang) = map { if_(/live_tree_i18n_(.*)\.clp/, $1) } keys %file2loop;
-my $totem_pid = $$;
-
-if (my $pid = fork()) {
- $ENV{MDKMOVE} = $pid;
- $ENV{G_BROKEN_FILENAMES} = 1;
- exec 'totem';
-} else {
- exec 'sudo', 'mdk_behind_totem',
- '--lang', $lang,
- '--i18n-loop', $file2loop{"live_tree_i18n_$lang.clp"},
- '--boot-loop', $file2loop{'live_tree_boot.clp'},
- '--boot-loop', $file2loop{'live_tree_boot.clp'},
- '--main-loop', $file2loop{'live_tree.clp'},
- '--totem-pid', $totem_pid,
- '--user', $ENV{USER},
- '--restore-cmd', $restart_progs;
-}
diff --git a/move/tree/mdk_totem.desktop b/move/tree/mdk_totem.desktop
deleted file mode 100644
index 85511c1db..000000000
--- a/move/tree/mdk_totem.desktop
+++ /dev/null
@@ -1,12 +0,0 @@
-[Desktop Entry]
-Name=Multimedia Player for CDs/DVDs
-Comment=Play movies and songs
-Exec=mdk_totem
-Icon=totem.png
-Type=Application
-Terminal=false
-
-Name[fr]=Lecteur Multimédia pour CDs/DVDs
-Name[it]=Lettore Multimediale di CD/DVDs
-Name[de]=Multimedia-Player für CDs/DVDs
-Name[es]=Reproductor multimedios para CD/DVD
diff --git a/move/tree/netscape b/move/tree/netscape
deleted file mode 100755
index 922d33bc5..000000000
--- a/move/tree/netscape
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/sh
-
-$BROWSER "$@"
diff --git a/move/tree/reboot b/move/tree/reboot
deleted file mode 100755
index b4b1d4ede..000000000
--- a/move/tree/reboot
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-
-echo "reboot" > /var/run/rebootctl
-sudo killall -USR1 startkde_move
-sudo killall X
diff --git a/move/tree/sound.initscript b/move/tree/sound.initscript
deleted file mode 100755
index 919a9b875..000000000
--- a/move/tree/sound.initscript
+++ /dev/null
@@ -1,116 +0,0 @@
-#!/bin/sh
-# (c) Mandrakesoft, Chmouel Boudjnah <chmouel@mandrakesoft.com>
-# $Id$
-#
-# sound: This shell script launch the sound on your system.
-#
-# chkconfig: 2345 18 69
-# description: This shell script launch the sound on your system.
-
-. /etc/rc.d/init.d/functions
-
-PKLVL=$(cut -f1 /proc/sys/kernel/printk)
-sysctl -n -w kernel.printk=0
-
-function start_mixer () {
- # ALSA
- if [ -d /proc/asound ] && [ -x /usr/sbin/alsactl ]; then
- # is ALSA already configured ?
- if [[ ! -r /etc/asound.state ]]; then
- # provide decent default sound level for alsa drivers
- if [ -d /proc/asound ] && [ -x /usr/sbin/alsactl ];then
- MIXER_SETTINGS=/root/tmp/asound.state_tmp
- alsactl -f $MIXER_SETTINGS store
- # set some sane default volume and unmute needed channels:
- /usr/bin/alsa_default.pl $MIXER_SETTINGS
- action "Setting mixer settings" alsactl -f $MIXER_SETTINGS restore
- rm -f $MIXER_SETTINGS
- return 0
- fi
- # if we've not alsa-utils, we'll fallback on OSS initialization below
- else
- # Not first boot:
- # Done by alsa service but only if sound service is not
- # enabled (hance this code path).
- # We'll merge in back aksa service once mdk9.2 is released.
- # [but we'll still handle both aumix & alsactl in order
- # to manage packages removing / driver switch]
- action "Loading mixer settings" /usr/sbin/alsactl restore
- return 0
- fi
- fi
- # OSS
- if egrep -q '(sparcaudio|sound)' /proc/devices 2>/dev/null && \
- [ "$retval" -eq 0 ] && [ -x /usr/bin/aumix ];then
- if [ ! -r /etc/.aumixrc ];then
- action "Setting mixer settings" /usr/bin/aumix -v80 -w80 -c80
- else
- action "Loading mixer settings" /usr/bin/aumix -f /etc/.aumixrc -L
- fi
- fi
-}
-
-function stop_mixer () {
- if [ -d /proc/asound ] && [ -x /usr/sbin/alsactl ];then
- # done by alsa service (to merge back after mdk9.2 release)
- #action "Saving mixer settings" /usr/sbin/alsactl store
- return 0;
- fi
- if egrep -q '(sparcaudio|sound)' /proc/devices 2>/dev/null && [ -x /usr/bin/aumix ];then
- action "Saving mixer settings" /usr/bin/aumix -f /etc/.aumixrc -S
- fi
-}
-
-function module () {
- opt=""
- phrase=$1
- alias=$2
- [ -n "$3" ] && opt="-r"
- module=`/sbin/modprobe -c | egrep -s "^alias( |\t)+"$alias"( |\t)+" | awk '{ print $3 }'`
- if [ -n "$module" ] && [ "$module" != "off" ];then
- action "$phrase ($module)" modprobe "$opt" $module
- return $?
- fi
-}
-
-case $1 in
- start)
- retval=0
- if [ ! -d /proc/asound ];then
- module "Loading sound module" sound || retval=1
- /sbin/modprobe -c | awk '/^((alias)|(probe)) +sound-slot-[0-9]/ {print $2}' | ( \
- while read line; do
- [[ $line = snd-card-* ]] && continue #we do it via alsa script
- module "Loading sound module" $line || retval=1
- done
- )
- module "Loading midi module" midi
- fi
- start_mixer;
- touch /var/lock/subsys/sound
- ;;
- stop)
- # i should have the same semantic of alsa script than oss script,
- # but i do not :-(, patches welcome.
- stop_mixer;
- rm -f /var/lock/subsys/sound
- ;;
- status)
- if egrep -q '(sparcaudio|sound)' /proc/devices;then
- gprintf "Sound loaded"
- echo
- fi
- ;;
- reload)
- ;;
- restart)
- $0 stop
- $0 start
- ;;
- *)
- echo "Usage: %s\n" "$(basename $0) {start|stop|restart|status}"
- exit 0
-esac
-
-sysctl -n -w kernel.printk=$PKLVL
-exit 0
diff --git a/move/tree/startkde_move b/move/tree/startkde_move
deleted file mode 100755
index a455ee580..000000000
--- a/move/tree/startkde_move
+++ /dev/null
@@ -1,17 +0,0 @@
-#!/bin/sh
-
-#- exit cleanly on SIGUSR1, so that our init can see a clean shutdown and automatically reboot
-reboot () {
- exit 0
-}
-trap 'reboot' SIGUSR1
-
-while true; do
- wait4x || exit 1
- xwait -permanent &
- xdim=`xdpyinfo | perl -ne 'print $1 if /dimensions:\s*(\d+)/'`
- qiv --root /image/move/BOOT-$xdim-MOVE.jpg
- /etc/X11/xdm/Xsession KDE #- call it with KDE parameter to keep background image
- sudo killall X
- sleep 2
-done
diff --git a/move/tree/sudoers b/move/tree/sudoers
deleted file mode 100644
index 49615de98..000000000
--- a/move/tree/sudoers
+++ /dev/null
@@ -1 +0,0 @@
-ALL ALL = NOPASSWD: ALL
diff --git a/move/tree/wait4x b/move/tree/wait4x
deleted file mode 100755
index a3158f1bd..000000000
--- a/move/tree/wait4x
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/usr/bin/perl
-
-use MDK::Common;
-use lib qw(/usr/lib/libDrakX);
-use xf86misc::main;
-
-my $nb = 0;
-$| = 1;
-print "waiting for X";
-foreach (1..30) {
- print ".";
- sleep 1;
- print("no X server :(\n"), exit 1 if !fuzzy_pidofs(qr/\bX_move\b/);
- $nb++ if xf86misc::main::Xtest(':0');
- if ($nb > 2) { #- one succeeded test is not enough :-(
- print "found\n";
- exit 0;
- }
-}
-print "not found\n";
-exit 1;