[OpenWrt-Users] how is the config dependency information generated?

Robert P. J. Day rpjday at crashcourse.ca
Wed Dec 19 20:50:18 CET 2007


  more specifically, i'm looking at the somewhat awkward structure of
the asterisk-related menu entries under "Network":

...
asterisk (Complete Open Source PBX)  --->
asterisk (Complete Open Source PBX), v1.2.x  --->
asterisk14 (Complete Open Source PBX), v1.4.x  --->
...

  what's awkward about it is that that first selection opens onto a
single menu entry:

<M> asterisk-prompt-de................ German asterisk prompts

which seems sort of wasteful.  more to the point, if i look at the
generated file tmp/.config-package.in, i can see this:

...
menu "asterisk (Complete Open Source PBX)"
        config PACKAGE_asterisk-prompt-de
                tristate "asterisk-prompt-de............................... German asterisk prompts"
                default y if DEFAULT_asterisk-prompt-de
                default m if ALL
                depends PACKAGE_asterisk-mini
                help
                 German asterisk prompts
                 http://www.stadt-pforzheim.de/asterisk/

endmenu
...

  but given that i'm used to the 2.6 Kconfig structure, i would
normally then expect to see that asterisk-prompt-de entry as a *sub*
entry under asterisk-mini, which is where it would seem to belong.
but it gets weirder.

  if i go under "asterisk14", i would have thought that i could just
deselect "asterisk14" to deselect that entire set of selections.  but
it doesn't work that way.  instead, this is what is in that same
tmp/pconfig-packag.in file:

...
menu "asterisk14 (Complete Open Source PBX), v1.4.x"
        config PACKAGE_asterisk14
                tristate "asterisk14...................................... Complete open source PBX"
                default y if DEFAULT_asterisk14
                default m if ALL
                select PACKAGE_libncurses
                select PACKAGE_libltdl
                select PACKAGE_libpopt
                select PACKAGE_libpthread
                depends !NATIVE_TOOLCHAIN
                help
                 Asterisk is a complete PBX in software. It provides all of the features
                 you would expect from a PBX and more. Asterisk does voice over IP in three
                 protocols, and can interoperate with almost all standards-based telephony
                 equipment using relatively inexpensive hardware.
                 URL:=http://www.asterisk.org/

        config PACKAGE_asterisk14-chan-alsa
                tristate "asterisk14-chan-alsa............................. ALSA soundcards support"
                default y if DEFAULT_asterisk14-chan-alsa
                default m if ALL
                select PACKAGE_alsa-lib
                depends USB_SUPPORT
                select PACKAGE_asterisk14  <------????????
                help
                 Asterisk is a complete PBX in software. It provides all of the features
                 you would expect from a PBX and more. Asterisk does voice over IP in three
                 protocols, and can interoperate with almost all standards-based telephony
                 equipment using relatively inexpensive hardware.
                 URL:=http://www.asterisk.org/
                 This package provides the channel driver for ALSA sound cards support to
                 Asterisk.
...

  normally, the package asterisk14-chan-alsa would *depend* on the
selection of asterisk14.  instead, there's a "select", which means i
have to deselect every single option in that list before i can finally
deselect asterisk14.  that just seems backwards.

  so how is that config file generated?  and why in such a
non-standard way?  thanks.

rday
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://crashcourse.ca
========================================================================


More information about the openwrt-users mailing list