aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouglas Rupp <rupp@adacore.com>2020-04-13 10:52:39 -0700
committerOlivier Hainque <hainque@adacore.com>2020-10-23 15:47:45 +0000
commitcd8b7d7b24caedea8ff33992088c50b3806d32c4 (patch)
tree5a01b359e00680cab84a3210079b481890e96d39
parente10440edda6f5f20b1b3c781c063ecf2b6db2572 (diff)
downloadgcc-cd8b7d7b24caedea8ff33992088c50b3806d32c4.zip
gcc-cd8b7d7b24caedea8ff33992088c50b3806d32c4.tar.gz
gcc-cd8b7d7b24caedea8ff33992088c50b3806d32c4.tar.bz2
Link with the configured net lib on vxworks7
The net library is configurable on vxworks7. Pick the library to include in link closures in accordance with the availability of a revealing header file, using the recently introduced if-exist-then-else spec builtin function. 2021-10-23 Douglas Rupp <rupp@adacore.com> gcc/ * config/vxworks.h (VXWORKS_NET_LIBS_RTP): Use -lrtnet if rtnetStackLib.h is available,fallback to -lnet otherwise.
-rw-r--r--gcc/config/vxworks.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/config/vxworks.h b/gcc/config/vxworks.h
index 5b15380..b7e5970 100644
--- a/gcc/config/vxworks.h
+++ b/gcc/config/vxworks.h
@@ -90,7 +90,7 @@ along with GCC; see the file COPYING3. If not see
#define VXWORKS_SYSCALL_LIBS_RTP
#if TARGET_VXWORKS7
-#define VXWORKS_NET_LIBS_RTP "-lnet"
+#define VXWORKS_NET_LIBS_RTP "-l%:if-exists-then-else(%:getenv(VSB_DIR /usr/h/public/rtnetStackLib.h) rtnet net)"
#else
#define VXWORKS_NET_LIBS_RTP "-lnet -ldsi"
#endif