aboutsummaryrefslogtreecommitdiff
path: root/resources/scripts/helpers/build/config/grubupdate
diff options
context:
space:
mode:
Diffstat (limited to 'resources/scripts/helpers/build/config/grubupdate')
-rwxr-xr-xresources/scripts/helpers/build/config/grubupdate23
1 files changed, 13 insertions, 10 deletions
diff --git a/resources/scripts/helpers/build/config/grubupdate b/resources/scripts/helpers/build/config/grubupdate
index 63902534..5bb1a57e 100755
--- a/resources/scripts/helpers/build/config/grubupdate
+++ b/resources/scripts/helpers/build/config/grubupdate
@@ -3,7 +3,7 @@
#
# helper script: run "make oldconfig" on all coreboot config files
#
-# Copyright (C) 2014, 2015 Francis Rowe <info@gluglug.org.uk>
+# Copyright (C) 2014, 2015, 2016 Francis Rowe <info@gluglug.org.uk>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -25,25 +25,28 @@
[ "x${DEBUG+set}" = 'xset' ] && set -v
set -u -e
-configpath="resources/libreboot/config/grub"
+payload="grub"
+configpath="resources/libreboot/config/${payload}"
hackconfig () {
- cd "coreboot/"
+ board="${1}"
- printf "Updating config for %s\n" "${1}"
+ cd "coreboot/${payload}/${board}/"
+
+ printf "Updating config for %s (%s payload)\n" "${board}" "${payload}"
sleep 2
- if [ ! -d "../${configpath}/${1}/" ]; then
- printf "build/config/corebootupdate WARNING: config '%s' does not exist. Skipping.\n" "${1}"
- cd "../"
+ if [ ! -d "../../../${configpath}/${board}/" ]; then
+ printf "build/config/grubupdate WARNING: config '%s' does not exist. Skipping.\n" "${board}"
+ cd "../../../"
return
fi
- mv "../${configpath}/${1}/config" ".config"
+ mv "../../../${configpath}/${board}/config" ".config"
make oldconfig
- mv ".config" "../${configpath}/${1}/config"
+ mv ".config" "../../../${configpath}/${board}/config"
- cd "../"
+ cd "../../../"
}
if [ $# -lt 1 ]; then