FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu Kernel Team

 
 
LinkBack Thread Tools
 
Old 01-23-2009, 01:38 PM
Andy Whitcroft
 
Default UBUNTU: allow us to build default configs for automated builds

Allow us to request an automated update to the configs taking whatever
the default answers are. This allows us to automate builds of mainline
kernels using our build infrastructure and configs.

Signed-off-by: Andy Whitcroft <apw@canonical.com>
---
debian/rules.d/1-maintainer.mk | 10 ++++++++++
debian/scripts/misc/oldconfig | 12 ++++++++----
2 files changed, 18 insertions(+), 4 deletions(-)

diff --git a/debian/rules.d/1-maintainer.mk b/debian/rules.d/1-maintainer.mk
index 0c1bf38..d63a045 100644
--- a/debian/rules.d/1-maintainer.mk
+++ b/debian/rules.d/1-maintainer.mk
@@ -10,6 +10,8 @@ help:
@echo
@echo " updateconfigs : Update debian/config/*"
@echo
+ @echo " defaultconfigs : Update debian/config/*"
+ @echo
@echo " editconfigs : Update debian/config/* interactively"
@echo
@echo " printchanges : Print the current changelog entries (from git)"
@@ -39,6 +41,14 @@ updateconfigs:
done
rm -rf build

+defaultconfigs:
+ dh_testdir
+ @for arch in $(ARCH_CONFIGS); do
+ yes ' |
+ $(SHELL) debian/scripts/misc/oldconfig $$arch oldconfig;
+ done
+ rm -rf build
+
editconfigs:
dh_testdir
@for arch in $(ARCH_CONFIGS); do
diff --git a/debian/scripts/misc/oldconfig b/debian/scripts/misc/oldconfig
index 9dfdc9a..dfbeff5 100755
--- a/debian/scripts/misc/oldconfig
+++ b/debian/scripts/misc/oldconfig
@@ -8,12 +8,16 @@ fi


# One arg, and that's it. Just pass an architecture
-if [ $# -ne 1 ]; then
- echo "Usage: $0 <arch>" 1>&2
+if [ $# -ne 1 -a $# -ne 2 ]; then
+ echo "Usage: $0 <arch> [<operation>]" 1>&2
exit 1
fi

arch="$1"
+what="silentoldconfig"
+if [ $# -eq 2 ]; then
+ what="$2"
+fi

case "$arch" in
amd64) kernarch="x86_64" ;;
@@ -48,11 +52,11 @@ fi
test -d build || mkdir build
cd build
for config in $configs; do
- echo "Running silentoldconfig for $config ... "
+ echo "Running $what for $config ... "

cat $confdir/$config > .config

- make -C ../ O=`pwd` silentoldconfig ARCH=$kernarch
+ make -C ../ O=`pwd` "$what" ARCH=$kernarch

cat .config > $confdir/$config
done
--
1.6.1.258.g7ff14.dirty


--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 
Old 03-17-2010, 04:01 PM
Andy Whitcroft
 
Default UBUNTU: allow us to build default configs for automated builds

Allow us to request an automated update to the configs taking whatever
the default answers are. This allows us to automate builds of mainline
kernels using our build infrastructure and configs.

Signed-off-by: Andy Whitcroft <apw@canonical.com>
---
debian/rules.d/1-maintainer.mk | 5 +++++
debian/scripts/misc/kernelconfig | 5 +++++
2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/debian/rules.d/1-maintainer.mk b/debian/rules.d/1-maintainer.mk
index ea8e158..65b9688 100644
--- a/debian/rules.d/1-maintainer.mk
+++ b/debian/rules.d/1-maintainer.mk
@@ -44,6 +44,11 @@ updateconfigs:
$(SHELL) $(DROOT)/scripts/misc/kernelconfig oldconfig
rm -rf build

+defaultconfigs:
+ dh_testdir;
+ yes "" | $(SHELL) $(DROOT)/scripts/misc/kernelconfig defaultconfig
+ rm -rf build
+
editconfigs:
dh_testdir
$(SHELL) $(DROOT)/scripts/misc/kernelconfig editconfig
diff --git a/debian/scripts/misc/kernelconfig b/debian/scripts/misc/kernelconfig
index 0c77c14..936680c 100755
--- a/debian/scripts/misc/kernelconfig
+++ b/debian/scripts/misc/kernelconfig
@@ -14,6 +14,7 @@ fi
mode=${1:?"Usage: $0 [oldconfig|editconfig]"}
case "$mode" in
oldconfig) ;; # All is good
+ defaultconfig) ;; # All is good
editconfig) ;; # All is good
genconfig) ;; # All is good
*) echo "$0 called with invalid mode" 1>&2
@@ -86,6 +87,10 @@ for arch in $archs; do
# Weed out incorrect config parameters
echo "* Run silentoldconfig on $arch/$config ..."
make O=`pwd`/build ARCH=$kernarch silentoldconfig ;;
+ defaultconfig)
+ # Weed out incorrect config parameters
+ echo "* Run oldconfig on $arch/$config ..."
+ make O=`pwd`/build ARCH=$kernarch oldconfig ;;
editconfig)
# Interactively edit config parameters
echo " * Run menuconfig on $arch/$config... Press a key."
--
1.7.0


--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 

Thread Tools




All times are GMT. The time now is 05:05 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org