mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2025-04-21 12:27:27 +03:00
fix unnamed config sections
git-svn-id: svn://svn.openwrt.org/openwrt/branches/buildroot-ng/openwrt@4321 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# Copyright (C) 2006 OpenWrt.org
|
# Copyright (C) 2006 OpenWrt.org
|
||||||
|
# Copyright (C) 2006 Fokus Fraunhofer <carsten.tittel@fokus.fraunhofer.de>
|
||||||
|
|
||||||
alias debug=${DEBUG:-:}
|
alias debug=${DEBUG:-:}
|
||||||
|
|
||||||
@@ -38,11 +39,13 @@ reset_cb() {
|
|||||||
reset_cb
|
reset_cb
|
||||||
|
|
||||||
config () {
|
config () {
|
||||||
|
local type="$1"
|
||||||
|
local name="$2"
|
||||||
_C=$(($_C + 1))
|
_C=$(($_C + 1))
|
||||||
name="${name:-cfg${_C}}"
|
name="${name:-cfg${_C}}"
|
||||||
config_cb "$1" "$2"
|
config_cb "$type" "$name"
|
||||||
export CONFIG_SECTION="$2"
|
export CONFIG_SECTION="$name"
|
||||||
export CONFIG_${CONFIG_SECTION}_TYPE="$1"
|
export CONFIG_${CONFIG_SECTION}_TYPE="$type"
|
||||||
}
|
}
|
||||||
|
|
||||||
option () {
|
option () {
|
||||||
@@ -88,3 +91,9 @@ config_set() {
|
|||||||
load_modules() {
|
load_modules() {
|
||||||
sed 's/^[^#]/insmod &/' $* | ash 2>&- || :
|
sed 's/^[^#]/insmod &/' $* | ash 2>&- || :
|
||||||
}
|
}
|
||||||
|
|
||||||
|
include() {
|
||||||
|
for file in $(ls /lib/$1/*.sh 2>/dev/null); do
|
||||||
|
. $file
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user