[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

debian-installer/rootskel/src/bin register-module,NONE,1.1 Makefile,1.1,1.2 apt-install,1.13,1.14 apt-update,1.10,1.11 debconf-get,1.3,1.4



Update of /cvs/debian-boot/debian-installer/rootskel/src/bin
In directory gluck:/tmp/cvs-serv1319/src/bin

Modified Files:
	Makefile apt-install apt-update debconf-get 
Added Files:
	register-module 
Log Message:
   * Add a register-module command, similar to apt-install, which queues
     modules for entry into /target/etc/modules and /target/etc/modutils/local.
     Does not yet handle 2.6 modutils. Should only be used for modules
     that discover does not find, or that have special parameters.
   * Add debian-installer/framebuffer and only enable frame buffer if it is
     true.
   * Add a S25env2debconf in debian-installer.d, that finds environment
     variables in the form foo/bar=baz, and uses these special ones to set
     debconf values in the db. This allows booting with any d-i debconf
     values on the command line, to override *anything*. For example --
     boot: debian-installer/framebuffer=false
   * Fixed debconf-get to not output value on stderr, and not clear screen
     either. But it is insanely gross and expensive now, and should be
     moved to cdebconf and rewritten.

Index: apt-update
===================================================================
RCS file: /cvs/debian-boot/debian-installer/rootskel/src/bin/apt-update,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- apt-update	6 Apr 2003 15:44:50 -0000	1.10
+++ apt-update	8 Dec 2003 21:52:30 -0000	1.11
@@ -15,10 +15,10 @@
 
 # Try to enable proxy when using HTTP.  What about using ftp_proxy for
 # FTP sources?  (This code is in both apt-update and apt-install)
-RET=`debconf-get mirror/protocol 2>&1 || true`
+RET=`debconf-get mirror/protocol || true`
 if [ "http" = "$RET" ]; then
     # try to find http proxy
-    RET=`debconf-get mirror/http/proxy 2>&1 || true`
+    RET=`debconf-get mirror/http/proxy || true`
     if [ "$RET" ] ; then
 	http_proxy="$RET"
 	export http_proxy

Index: debconf-get
===================================================================
RCS file: /cvs/debian-boot/debian-installer/rootskel/src/bin/debconf-get,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- debconf-get	4 May 2003 08:44:03 -0000	1.3
+++ debconf-get	8 Dec 2003 21:52:30 -0000	1.4
@@ -1,10 +1,12 @@
 #!/bin/sh -e
 #
-# Usage: var=`debconf-get template 2>&1`
-
-. /usr/share/debconf/confmodule
-
-db_get "$1"
+# Usage: var=`debconf-get template`
+# TODO move to cdebconf, reimplement so it's not shite
 
-# stdout is sent to debconf.  using stderr instead
-echo $RET 1>&2
+if [ -n "$TO_GET" ]; then
+	. /usr/share/debconf/confmodule
+	db_get "$TO_GET"
+	echo $RET 1>&2
+else
+	(TO_GET=$1 $0 >/dev/null) 2>&1
+fi

--- NEW FILE: register-module ---
#!/bin/sh
# Register a module to go in /etc/modules on the target. May be called
# before the target is mounted. Can optionally pass parameters that should
# be passed to the module on load; these are added to /etc/modules.conf.
QUEUE=/var/lib/register-module/queue
MODULE=$1

touch $QUEUE
grep -v "^$MODULE " $QUEUE > $QUEUE.new
mv $QUEUE.new $QUEUE
# Trialing whitespace is significant.
echo "$@ " >> $QUEUE

Index: apt-install
===================================================================
RCS file: /cvs/debian-boot/debian-installer/rootskel/src/bin/apt-install,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- apt-install	27 Sep 2003 12:58:12 -0000	1.13
+++ apt-install	8 Dec 2003 21:52:30 -0000	1.14
@@ -25,10 +25,10 @@
 
 # Try to enable proxy when using HTTP.  What about using ftp_proxy for
 # FTP sources?  (This code is in both apt-update and apt-install)
-RET=`debconf-get mirror/protocol 2>&1 || true`
+RET=`debconf-get mirror/protocol || true`
 if [ "http" = "$RET" ]; then
     # try to find http proxy
-    RET=`debconf-get mirror/http/proxy 2>&1 || true`
+    RET=`debconf-get mirror/http/proxy || true`
     if [ "$RET" ] ; then
 	http_proxy="$RET"
 	export http_proxy

Index: Makefile
===================================================================
RCS file: /cvs/debian-boot/debian-installer/rootskel/src/bin/Makefile,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- Makefile	3 May 2003 14:16:56 -0000	1.1
+++ Makefile	8 Dec 2003 21:52:30 -0000	1.2
@@ -1,5 +1,5 @@
 dir = bin
 
-files_exec = $(wildcard apt*) $(wildcard debconf*)
+files_exec = $(wildcard apt*) $(wildcard debconf*) register-module
 
 include ../Makefile.inc



Reply to: