]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Arrange to --disable-shared by default for VxWorks
authorOlivier Hainque <hainque@adacore.com>
Fri, 3 Dec 2021 17:48:18 +0000 (17:48 +0000)
committerOlivier Hainque <hainque@adacore.com>
Fri, 30 Sep 2022 10:43:13 +0000 (10:43 +0000)
This change makes sure that shared libraries for VxWorks are
only built on explicit request, when configured with --enable-shared.

As the support to build shared libs gets in very incrementally,
this provides us with a robust way to guard the relevant pieces
and reduce the risks of accidentally breaking a platform not yet
ready for it.

2022-09-30  Olivier Hainque  <hainque@adacore.com>

* configure.ac (*vxworks*): If enable_shared is not
set, set to "no" and add --disable-shared to target and
host_configargs.
* configure: Regenerate.

configure
configure.ac

index e7604dc6ff08cdf96aefd61a42bdd27e064451e8..d9aa84c6138ad867c21f55232b1db4c9ce24a0c4 100755 (executable)
--- a/configure
+++ b/configure
@@ -10263,6 +10263,17 @@ case "${target}" in
   mep*)
     FLAGS_FOR_TARGET="$FLAGS_FOR_TARGET -mlibrary"
     ;;
+  # The VxWorks support for shared libraries is getting in
+  # incrementally.  Make sure it doesn't get activated implicitly:
+  *vxworks*)
+    if test "${enable_shared-unset}" = unset ; then
+      enable_shared=no
+      # So the build of libraries knows ...
+      target_configargs="${target_configargs} --disable-shared"
+      # So gcc knows ...
+      host_configargs="${host_configargs} --disable-shared"
+    fi
+    ;;
 esac
 
 # Makefile fragments.
index 3cfd9b41fcab1f370727356725c8e9a8503ba87a..2cff32e300ea251d1794d3cd86a85245773d576c 100644 (file)
@@ -3440,6 +3440,17 @@ case "${target}" in
   mep*)
     FLAGS_FOR_TARGET="$FLAGS_FOR_TARGET -mlibrary"
     ;;
+  # The VxWorks support for shared libraries is getting in
+  # incrementally.  Make sure it doesn't get activated implicitly:
+  *vxworks*)
+    if test "${enable_shared-unset}" = unset ; then
+      enable_shared=no
+      # So the build of libraries knows ...
+      target_configargs="${target_configargs} --disable-shared"
+      # So gcc knows ...
+      host_configargs="${host_configargs} --disable-shared"
+    fi
+    ;;
 esac
 
 # Makefile fragments.