summaryrefslogtreecommitdiff
path: root/menuselect/menuselect.c
AgeCommit message (Collapse)Author
2017-11-17menuselect: Remove ineffective weak attribute detection.Corey Farrell
menuselect detects compiler support for multiple styles of weak functions. This is a remnant from 2013 when OPTIONAL_API required weak functions. It is no longer correct for menuselect to switch dependencies from optional to required based on lack of weak function support. Note an issue remains - dependencies should switch from optional to required based on OPTIONAL_API being enabled or disabled. I don't think this is possible. menuselect needs to know at startup if OPTIONAL_API is enabled or disabled, so the only way to fix this is to remove OPTIONAL_API from menuselect and create a configure option. I've left the code that switches in place but it's preprocessed out. Additionally removed: - WEAKREF variable from Asterisk makeopts.in. - Related disabled code from test_utils. - Pointless AC_REVISION call from menuselect/configure.ac. Change-Id: Ifa702e5f98eb45f338b2f131a93354632a8fb389
2017-03-13menuselect: Add a new 'options' support typeGeorge Joseph
The Binaural Rendering patches in the master branch required menuselect to be updated with a new support type called 'option'. This allows binaural rendering to be turned on or off when bridge_softmix is built. This patch backports the 'option' functionality to the 13 and 14 branches. Here's what it looks like in menuselect: [*] bridge_simple [*] bridge_softmix --- Module Options --- [ ] binaural_rendering_in_bridge_softmix To create an option for a module, you can create (or update) the menuselect-tree xml snippet in the directory where the module resides and add a member element with an 'option' support_level. Example (abbreviated) from bridges/bridges.xml: <member name="binaural_rendering_in_bridge_softmix" displayname="Enable binaural rendering in bridge_softmix" remove_on_change="bridges/bridge_softmix.o bridges/bridge_softmix.so"> <support_level>option</support_level> <depend>bridge_softmix</depend> <depend>fftw3</depend> <defaultenabled>no</defaultenabled> </member> The 'name' will be added or removed from the MENUSELECT_<dir> make variable following the standard module "missing means yes" rules. Example (abbreviated) from bridges/Makefile: ifeq ($(findstring binaural_rendering,$(MENUSELECT_BRIDGES)),) bridge_softmix.o: _ASTCFLAGS+=-DBINAURAL_RENDERING bridge_softmix.so: LIBS+=$(FFTW3_LIB) endif Change-Id: I66d23755ed6e81f8d439cad410f2ffa7c30f25ad
2016-08-01menuselect: Add an opaque "member_data" string to the acceptable xmlGeorge Joseph
Change-Id: Id5ac43b95c8d7395f3be37f983632169db3d1afe
2016-08-01Replace strdupa with more portable ast_strdupaDavid M. Lee
The strdupa function is a GNU extension, and not widely portable. We have an ast_strdupa function used within Asterisk which is preferred. I pulled the definition up from menuselect.c into the menuselect.h header file so it can be shared across menuselect. Change-Id: I9593c97f78386b47dc1e83201e80cb2f62b36c2e
2016-08-01menuselect: Various menuselect enhancementsGeorge Joseph
* Add 'external' as a support level. * Add ability for module directories to add entries to the menu by adding members to the <module_prefix>/<module_prefix>.xml file. * Expand the description field to 3 lines in the ncurses implementation. * Allow the description field to wrap in the newt implementation. * Add description field to the gtk implementation. Change-Id: I7f9600a1984a42ce0696db574c1051bc9ad7c808 (cherry picked from commit 90f445729d5d86050d9d379485ff0a99f4a006c1)
2016-03-13build_system: Split COMPILE_DOUBLE from DONT_OPTIMIZEGeorge Joseph
I can't ever recall actually needing the intermediate files or the checking that a double compile produces. What I CAN remember is every DONT_OPTIMIZE build needing 3 invocations of gcc instead of 1 just to do the checks and produce those intermediate files. Having said that, Richard pointed out that the reason for the double compile was that there were cases in the past where a submitted patch failed to compile because the submitter never tried it with the optimizations turned on. To get the best of both worlds, COMPILE_DOUBLE has been split into its own option. If DONT_OPTIMIZE is turned on, COMPILE_DOUBLE will also be selected BUT you can then turn it off if all you need are the debugging symbols. This way you have to make an informed decision about disabling COMPILE_DOUBLE. To allow COMPILE_DOUBLE to be both auto-selected and turned off, a new feature was added to menuselect. The <use> element can now contain an "autoselect" attribute which will turn the used member on but not create a hard dependency. The cflags.xml implementation for COMPILE_DOUBLE looks like this... <member name="DONT_OPTIMIZE" displayname="Disable Optimizations ..."> <use autoselect="yes">COMPILE_DOUBLE</use> <support_level>core</support_level> </member> <member name="COMPILE_DOUBLE" displayname="Pre-compile with ...> <depend>DONT_OPTIMIZE</depend> <support_level>core</support_level> </member> When DONT_OPTIMIZE is turned on, COMPILE_DOUBLE is turned on because of the use. When DONT_OPTIMIZE is turned off, COMPILE_DOUBLE is turned off because of the depend. When COMPILE_DOUBLE is turned on, DONT_OPTIMIZE is turned on because of the depend. When COMPILE_DOUBLE is turned off, DONT_OPTIMIZE is left as is because it only uses COMPILE_DOUBLE, it doesn't depend on it. I also made a few tweaks to the ncurses implementation to move things left a bit to allow longer descriptions. Change-Id: Id49ca930ac4b5ec4fc2d8141979ad888da7b1611
2014-09-05Menuselect: Fix incorrect enabling on failed depsKinsey Moore
This corrects a situation where menuselect can incorrectly enable a module by default that has defaultenabled set to "no" and has failed/non-selected dependencies. The bug is due to an inverted test when checking for whether the given module should be set to enabled by default on load. Review: https://reviewboard.asterisk.org/r/3975/ Reported by: John Bigelow git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@422646 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-17menuselect: Add libxml2 support (Patch 3)Matthew Jordan
This is the final patch in adding menuselect to Asterisk. - The first patch (r418832) added menuselect along with mxml - The second patch (r418833) removed mxml from menuselect This patch adds support for libxml2 to menuselect, and makes libxml2 a required library for Asterisk. Note that the libxml2 portion of this patch was written by Sean Bright, and was made available on a team branch: http://svn.digium.com/svn/menuselect/team/seanbright/libxml2/ Review: https://reviewboard.asterisk.org/r/3773/ ASTERISK-20703 #close patches: some_mysterious_team_branch uploaded by seanbright (License 5060) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@418834 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-17menuselect: Add menuselect to Asterisk trunk (Patch 1)Matthew Jordan
This is the first patch that adds menuselect to Asterisk trunk, and removes the svn:externals property. This is being done for two reasons: (1) The removal of external repositories eases a future migration to git (2) Asterisk is now the only thing that uses menuselect; as a result, there's little need to keep it in an external repository Subsequent patches will remove the mxml dependency from menuselect and tidy up the build system. ASTERISK-20703 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@418832 65c4cc65-6c06-0410-ace0-fbb531ad65f3