diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2021-07-15 16:06:12 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2021-07-15 16:06:12 +0100 |
commit | 438951e8839c66a0d0f65011a7a4ff6bd50efad6 (patch) | |
tree | 975a2a9c2c626d93e54d267adc784f0891cd52f4 /configure | |
parent | f665574ac5b08284e5292f013235bef2e9d4e73d (diff) | |
parent | a6b95a9733a94f38b289430bf46987809f53ab16 (diff) |
Merge remote-tracking branch 'remotes/stsquad/tags/pull-testing-and-plugins-140721-5' into staging
Testing and plugin updates:
- custom runner playbooks for configuring GitLab runners
- integrate Cirrus jobs into GitLab via cirrus-run
- clean-up docker package lists
- bump NetBSD to 9.2
- bump OpenBSD to 6.9
- make test-mmap more hexagon friendly
- fixup handling of hostaddr for plugins
- disallow some incompatible plugin configurations
- fix handling of -ldl for BSDs
- remove some old unused symbols from the plugin symbol map
- enable plugins by default for most TCG builds
- honour main build -Wall settings for plugins
- new execlog plugin
- new cache modelling plugin
- fix io_uring build regression
- disable modular TCG on Darwin
# gpg: Signature made Wed 14 Jul 2021 15:56:27 BST
# gpg: using RSA key 6685AE99E75167BCAFC8DF35FBD0DB095A9E2A44
# gpg: Good signature from "Alex Bennée (Master Work Key) <alex.bennee@linaro.org>" [full]
# Primary key fingerprint: 6685 AE99 E751 67BC AFC8 DF35 FBD0 DB09 5A9E 2A44
* remotes/stsquad/tags/pull-testing-and-plugins-140721-5: (44 commits)
MAINTAINERS: Added myself as a reviewer for TCG Plugins
docs/devel: Added cache plugin to the plugins docs
plugins/cache: Added FIFO and LRU eviction policies
plugins/cache: Enable cache parameterization
plugins: Added a new cache modelling plugin
docs/devel: tcg-plugins: add execlog plugin description
contrib/plugins: add execlog to log instruction execution and memory access
contrib/plugins: enable -Wall for building plugins
tcg/plugins: enable by default for most TCG builds
configure: stop user enabling plugins on Windows for now
configure: add an explicit static and plugins check
configure: don't allow plugins to be enabled for a non-TCG build
tcg/plugins: remove some stale entries from the symbol list
meson.build: relax the libdl test to one for the function dlopen
meson.build: move TCG plugin summary output
plugins: fix-up handling of internal hostaddr for 32 bit
tests/tcg: make test-mmap a little less aggressive
tests/vm: update openbsd to release 6.9
tests/vm: update NetBSD to 9.2
tests/docker: expand opensuse-leap package list
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 142 |
1 files changed, 83 insertions, 59 deletions
@@ -429,7 +429,7 @@ libxml2="auto" debug_mutex="no" libpmem="auto" default_devices="true" -plugins="no" +plugins="$default_feature" fuzzing="no" rng_none="no" secret_keyring="$default_feature" @@ -708,6 +708,7 @@ MINGW32*) audio_drv_list="" fi supported_os="yes" + plugins="no" pie="no" ;; GNU/kFreeBSD) @@ -1110,6 +1111,7 @@ for opt do --enable-cap-ng) cap_ng="enabled" ;; --disable-tcg) tcg="disabled" + plugins="no" ;; --enable-tcg) tcg="enabled" ;; @@ -1521,7 +1523,11 @@ for opt do ;; --disable-xkbcommon) xkbcommon="disabled" ;; - --enable-plugins) plugins="yes" + --enable-plugins) if test "$mingw32" = "yes"; then + error_exit "TCG plugins not currently supported on Windows platforms" + else + plugins="yes" + fi ;; --disable-plugins) plugins="no" ;; @@ -1575,6 +1581,11 @@ for opt do esac done +# test for any invalid configuration combinations +if test "$plugins" = "yes" -a "$tcg" = "disabled"; then + error_exit "Can't enable plugins on non-TCG builds" +fi + case $git_submodules_action in update|validate) if test ! -e "$source_path/.git"; then @@ -2191,11 +2202,16 @@ if test "$modules" = "no" && test "$module_upgrades" = "yes" ; then error_exit "Can't enable module-upgrades as Modules are not enabled" fi -# Static linking is not possible with modules or PIE +# Static linking is not possible with plugins, modules or PIE if test "$static" = "yes" ; then if test "$modules" = "yes" ; then error_exit "static and modules are mutually incompatible" fi + if test "$plugins" = "yes"; then + error_exit "static and plugins are mutually incompatible" + else + plugins="no" + fi fi # Unconditional check for compiler __thread support @@ -3089,6 +3105,69 @@ for drv in $audio_drv_list; do done ########################################## +# plugin linker support probe + +if test "$plugins" != "no"; then + + ######################################### + # See if --dynamic-list is supported by the linker + + ld_dynamic_list="no" + cat > $TMPTXT <<EOF +{ + foo; +}; +EOF + + cat > $TMPC <<EOF +#include <stdio.h> +void foo(void); + +void foo(void) +{ + printf("foo\n"); +} + +int main(void) +{ + foo(); + return 0; +} +EOF + + if compile_prog "" "-Wl,--dynamic-list=$TMPTXT" ; then + ld_dynamic_list="yes" + fi + + ######################################### + # See if -exported_symbols_list is supported by the linker + + ld_exported_symbols_list="no" + cat > $TMPTXT <<EOF + _foo +EOF + + if compile_prog "" "-Wl,-exported_symbols_list,$TMPTXT" ; then + ld_exported_symbols_list="yes" + fi + + if test "$ld_dynamic_list" = "no" && + test "$ld_exported_symbols_list" = "no" ; then + if test "$plugins" = "yes"; then + error_exit \ + "Plugin support requires dynamic linking and specifying a set of symbols " \ + "that are exported to plugins. Unfortunately your linker doesn't " \ + "support the flag (--dynamic-list or -exported_symbols_list) used " \ + "for this purpose." + else + plugins="no" + fi + else + plugins="yes" + fi +fi + +########################################## # glib support probe glib_req_ver=2.56 @@ -3096,7 +3175,7 @@ glib_modules=gthread-2.0 if test "$modules" = yes; then glib_modules="$glib_modules gmodule-export-2.0" fi -if test "$plugins" = yes; then +if test "$plugins" = "yes"; then glib_modules="$glib_modules gmodule-2.0" fi @@ -3921,61 +4000,6 @@ if compile_prog "" "" ; then atomic64=yes fi -######################################### -# See if --dynamic-list is supported by the linker -ld_dynamic_list="no" -if test "$static" = "no" ; then - cat > $TMPTXT <<EOF -{ - foo; -}; -EOF - - cat > $TMPC <<EOF -#include <stdio.h> -void foo(void); - -void foo(void) -{ - printf("foo\n"); -} - -int main(void) -{ - foo(); - return 0; -} -EOF - - if compile_prog "" "-Wl,--dynamic-list=$TMPTXT" ; then - ld_dynamic_list="yes" - fi -fi - -######################################### -# See if -exported_symbols_list is supported by the linker - -ld_exported_symbols_list="no" -if test "$static" = "no" ; then - cat > $TMPTXT <<EOF - _foo -EOF - - if compile_prog "" "-Wl,-exported_symbols_list,$TMPTXT" ; then - ld_exported_symbols_list="yes" - fi -fi - -if test "$plugins" = "yes" && - test "$ld_dynamic_list" = "no" && - test "$ld_exported_symbols_list" = "no" ; then - error_exit \ - "Plugin support requires dynamic linking and specifying a set of symbols " \ - "that are exported to plugins. Unfortunately your linker doesn't " \ - "support the flag (--dynamic-list or -exported_symbols_list) used " \ - "for this purpose. You can't build with --static." -fi - ######################################## # check if getauxval is available. |