From: Perforce Review Daemon <p4review AT smee.org>
To: "Andraž " ruskie " Levstik" <ruskie AT mages.ath.cx>, "Andrew Stitt" <a AT t.armory.com>, "Arjan Bouter" <abouter AT sourcemage.org>, "Arwed von Merkatz" <v.merkatz AT gmx.net>, "SM-Commit Daemon" <sm-commit AT lists.ibiblio.org>, "David Kowis" <dkowis+smgl-p4 AT shlrm.org>, "duane_malcolm" <d.malcolm AT auckland.ac.nz>, "Eric Sandall" <eric AT sandall.us>, "Ethan Grammatikidis" <eekee AT eekee.is-a-geek.org>, "Flavien Bridault" <f.bridault AT fra.net>, "Gareth Clay" <gareth AT caffeinefuelled.co.uk>, "George J. Sherwood" <george AT beernabeer.com>, "Jason Flatt" <jflatt AT sourcemage.org>, "Jeremy Blosser" <jblosser AT sourcemage.org>, "Juuso Alasuutari" <iuso AT sourcemage.org>, "Ladislav Hagara" <ladislav.hagara AT unob.cz>, "Maurizio Boriani" <baux AT member.fsf.org>, "Pieter Lenaerts" <e-type AT sourcemage.org>, "Pol Vinogradov" <vin.public AT gmail.com>, "Robin Cook" <rcook AT wyrms.net>, "Unet" <unet AT sourcemage.org>, "vladimir_marek" <vlmarek AT volny.cz>
Subject: [SM-Commit] PERFORCE change 77335 by Flavien Bridault for review
Date: Thu, 6 Apr 2006 11:25:01 +0100 (BST)
Change 77335 by flavien_bridault@flavien-Gargamel on 2006/04/06 11:22:51
@@ -1,3 +1,9 @@
+2006-04-06 Flavien Bridault <vlaaad AT sourcemage.org>
+ * disk/FUNCTIONS: moved common code from cdrtools and dvdrtools there,
+ giving two new functions: add_module_autoload and
remove_module_autoload
+ This code is modified from the original, taking into account the
+ right version of the kernel. That should fix bug #10683
+
2006-04-06 Pol Vinogradov <vin.public AT gmail.com>
* gnome2-apps/gideon: added, GUI designer for GTK+
#---------------------------------------------------------------------
##
+## @param module filename
+## Add a file in /etc/modules.d to get some modules autoloaded
+##
+#---------------------------------------------------------------------
+function add_module_autoload()
+{
+ MODULE_FILENAME=${1##*/}
+
+ if [ ! -f $INSTALL_ROOT/etc/modules.d/$MODULE_FILENAME ]; then
+ mkdir -p $INSTALL_ROOT/etc/modules.d &&
+ cp $1 $INSTALL_ROOT/etc/modules.d
+ fi &&
+
+ local MOD="$INSTALL_ROOT/etc/modules.conf"
+ local INC="include /etc/modules.d/$MODULE_FILENAME"
+
+ grep -q "$INC" $MOD ||
+ echo "$INC" >> $MOD
+
+ # Avoid that -b option of depmod takes the kernel version as the path for
/lib/modules
+ if [ -z $INSTALL_ROOT ]; then
+ depmod -a -C $MOD $(get_kernel_version)
+ else
+ depmod -a -C $MOD -b $INSTALL_ROOT $(get_kernel_version)
+ fi
+}
+
+#---------------------------------------------------------------------
+##
+## @param module filename
+## Add a file in /etc/modules.d to get some modules autoloaded
+##
+#---------------------------------------------------------------------
+function remove_module_autoload()
+{
+ MODULE_FILENAME=${1##*/}
+
+ MOD="$INSTALL_ROOT/etc/modules.conf"
+ TMP="$INSTALL_ROOT/tmp/modules.conf"
+ INC="include /etc/modules.d/$MODULE_FILENAME"
+
+ cp $MOD $TMP &&
+ grep -v "$INC" $TMP > $MOD &&
+ rm $TMP &&
+ rm $INSTALL_ROOT/etc/modules.d/$MODULE_FILENAME
+
+ # Avoid that -b option of depmod takes the kernel version as the path for
/lib/modules
+ if [ -z $INSTALL_ROOT ]; then
+ depmod -a -C $MOD $(get_kernel_version)
+ else
+ depmod -a -C $MOD -b $INSTALL_ROOT $(get_kernel_version)
+ fi
+}
+
+#---------------------------------------------------------------------
+##
## Detects cd recorders and list them on standard output
##
#---------------------------------------------------------------------
@@ -1,3 +1,9 @@
+2006-04-06 Flavien Bridault <disk AT sourcemage.org>
+ * POST_REMOVE: call persistent_load to get $IDE_SCSI
+ moved the main code in FUNCTIONS
+ * FINAL: moved the main code in FUNCTIONS
+ * ide-scsi: moved at section level for sharing
+
2006-03-12 Karsten Behrmann <BearPerson AT sourcemage.org>
* DETAILS: (automated) Add KEYWORDS
@@ -1,8 +1,7 @@
-MOD="/etc/modules.conf"
-TMP="/tmp/modules.conf"
-INC="include /etc/modules.d/ide-scsi"
+# Temporary call to get config variables
+# this should be fixed soon in sorcery
+persistent_load &&
@@ -1,7 +1,7 @@
-config_query IDE_SCSI
\
- "Do you want to use ide-scsi to burn cds/dvds with an IDE
burner?" \
- n
&&
-config_query_list PERM
\
- "Giving write permission to IDE devices can be risky, whom do
you want to allow this?" \
- "burning_group_users"
\
- "root_only"
+config_query IDE_SCSI
\
+ "Do you want to use ide-scsi to burn cds with an IDE burner?"
\
+ n
&&
+config_query_list PERM
\
+ "Giving write permission to IDE devices can be risky, whom do
you want to allow this?" \
+ "root_only"
\
+ "burning_group_users_with_suid_bit"
@@ -1,3 +1,12 @@
+2006-04-06 Flavien Bridault <vlaaad AT sourcemage.org>
+ * DETAILS: updated WEB_SITE
+ * CONFIGURE: doesn't work without root perms, deleted burning group
+ option and replaced it by burning group with suid bit
+ * POST_REMOVE: call persistent_load to get $IDE_SCSI
+ moved the main code in FUNCTIONS
+ * FINAL: moved the main code in FUNCTIONS
+ * ide-scsi: moved at section level for sharing
+
2006-03-12 Karsten Behrmann <BearPerson AT sourcemage.org>
* DETAILS: (automated) Add KEYWORDS
@@ -1,8 +1,7 @@
-MOD="/etc/modules.conf"
-TMP="/tmp/modules.conf"
-INC="include /etc/modules.d/ide-scsi"
+# Temporary call to get config variables
+# this should be fixed soon in sorcery
+persistent_load &&