summaryrefslogtreecommitdiff
path: root/libgo/configure
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2022-02-12 17:12:41 -0800
committerIan Lance Taylor <iant@golang.org>2022-02-13 11:03:45 -0800
commit58aeb75d4097010ad9bb72b964265b18ab284f93 (patch)
tree849876c3156f676db4c951f9b9f6a77e452b6a06 /libgo/configure
parent033ec967ec5583ea978d16ca83f9563c518e6dc6 (diff)
downloadgcc-58aeb75d4097010ad9bb72b964265b18ab284f93.tar.gz
runtime: call timer functions via syscall
It turns out to be painful to require linking against -lrt on GNU/Linux, as that makes it harder to link Go code into C programs. Instead just call the timer syscalls directly. That is what the upstream library does anyhow. gcc/go/ * gospec.cc: Revert 2022-02-09 change: (RTLIB, RT_LIBRARY): Don't define. (lang_specific_driver): Don't add -lrt if linking statically on GNU/Linux. gotools/ * configure.ac: Revert 2022-02-09 change: (RT_LIBS): Don't define. * Makefile.am (check-runtime): Don't set GOLIBS to $(RT_LIBS). * configure, Makefile.in: Regenerate. Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/385475
Diffstat (limited to 'libgo/configure')
-rwxr-xr-xlibgo/configure11
1 files changed, 2 insertions, 9 deletions
diff --git a/libgo/configure b/libgo/configure
index e2403634281..ffe17c9be55 100755
--- a/libgo/configure
+++ b/libgo/configure
@@ -649,7 +649,6 @@ HAVE_SYS_MMAN_H_FALSE
HAVE_SYS_MMAN_H_TRUE
PTHREAD_LIBS
PTHREAD_CFLAGS
-RT_LIBS
NET_LIBS
MATH_LIBS
GOC_IS_LLGO_FALSE
@@ -11545,7 +11544,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11548 "configure"
+#line 11547 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -11651,7 +11650,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11654 "configure"
+#line 11653 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -14748,12 +14747,6 @@ $as_echo "$libgo_cv_lib_sockets" >&6; }
NET_LIBS="$libgo_cv_lib_sockets"
-RT_LIBS=
-case ${host} in
- *-*-linux*) RT_LIBS=-lrt ;;
-esac
-
-
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -pthread is supported" >&5
$as_echo_n "checking whether -pthread is supported... " >&6; }
if ${libgo_cv_lib_pthread+:} false; then :