[Git][ghc/ghc][wip/rts-configure] Deleted 3 commits: RTS configure: handle ffi adjustor method
John Ericson (@Ericson2314)
gitlab at gitlab.haskell.org
Fri Sep 22 18:34:22 UTC 2023
John Ericson pushed to branch wip/rts-configure at Glasgow Haskell Compiler / GHC
WARNING: The push did not contain any new commits, but force pushed to delete the commits and changes below.
Deleted commits:
9a98534c by John Ericson at 2023-09-22T14:31:24-04:00
RTS configure: handle ffi adjustor method
- - - - -
eb924a62 by John Ericson at 2023-09-22T14:31:25-04:00
Handle -lpthread entirely within RTS configure
- - - - -
efc5cfef by John Ericson at 2023-09-22T14:31:25-04:00
RTS makes independent decision on leading-underscore
- - - - -
7 changed files:
- configure.ac
- hadrian/cfg/system.config.in
- hadrian/src/Oracles/Flag.hs
- hadrian/src/Rules/Generate.hs
- rts/configure.ac
- rts/rts.buildinfo.in
- rts/rts.cabal.in
Changes:
=====================================
configure.ac
=====================================
@@ -868,9 +868,6 @@ dnl ** check for librt
AC_CHECK_LIB([rt], [clock_gettime], UseLibrt=YES, UseLibrt=NO)
AC_SUBST([UseLibrt])
-FP_CHECK_PTHREAD_LIB
-AC_SUBST([UseLibpthread])
-
GHC_ADJUSTORS_METHOD([Target])
AC_SUBST([UseLibffiForAdjustors])
=====================================
hadrian/cfg/system.config.in
=====================================
@@ -124,5 +124,4 @@ use-lib-m = @UseLibm@
use-lib-rt = @UseLibrt@
use-lib-dl = @UseLibdl@
use-lib-bfd = @UseLibbfd@
-use-lib-pthread = @UseLibpthread@
need-libatomic = @NeedLibatomic@
=====================================
hadrian/src/Oracles/Flag.hs
=====================================
@@ -36,7 +36,6 @@ data Flag = CrossCompiling
| UseLibrt
| UseLibdl
| UseLibbfd
- | UseLibpthread
| NeedLibatomic
| UseGhcToolchain
@@ -60,7 +59,6 @@ flag f = do
UseLibrt -> "use-lib-rt"
UseLibdl -> "use-lib-dl"
UseLibbfd -> "use-lib-bfd"
- UseLibpthread -> "use-lib-pthread"
NeedLibatomic -> "need-libatomic"
UseGhcToolchain -> "use-ghc-toolchain"
value <- lookupSystemConfig key
=====================================
hadrian/src/Rules/Generate.hs
=====================================
@@ -296,7 +296,6 @@ rtsCabalFlags = mconcat
, flag "CabalHaveLibm" UseLibm
, flag "CabalHaveLibrt" UseLibrt
, flag "CabalHaveLibdl" UseLibdl
- , flag "CabalNeedLibpthread" UseLibpthread
, flag "CabalHaveLibbfd" UseLibbfd
, flag "CabalHaveLibNuma" UseLibnuma
, flag "CabalHaveLibZstd" UseLibzstd
@@ -304,7 +303,6 @@ rtsCabalFlags = mconcat
, flag "CabalNeedLibatomic" NeedLibatomic
, flag "CabalUseSystemLibFFI" UseSystemFfi
, targetFlag "CabalLibffiAdjustors" tgtUseLibffiForAdjustors
- , targetFlag "CabalLeadingUnderscore" tgtSymbolsHaveLeadingUnderscore
]
where
flag = interpolateCabalFlag
=====================================
rts/configure.ac
=====================================
@@ -216,7 +216,8 @@ AC_C_BIGENDIAN
FPTOOLS_FLOAT_WORD_ORDER_BIGENDIAN
dnl ** check for leading underscores in symbol names
-if test "$CABAL_FLAG_leading_underscore" = 1; then
+FP_LEADING_UNDERSCORE
+if test x"$fptools_cv_leading_underscore" = xyes; then
AC_DEFINE([LEADING_UNDERSCORE], [1], [Define to 1 if C symbols have a leading underscore added by the compiler.])
fi
@@ -242,6 +243,10 @@ AC_LINK_IFELSE([AC_LANG_CALL([], [printf\$LDBLStub])],
[Define to 1 if we have printf$LDBLStub (Apple Mac OS >= 10.4, PPC).])
])
+dnl ** for pthread_getthreadid_np, pthread_create, ...
+FP_CHECK_PTHREAD_LIB
+AS_IF([test "$UseLibpthread" "YES"],
+ [buildinfoExtraDefs+=' -DNEED_PTHREAD_LIB'])
FP_CHECK_PTHREAD_FUNCS
dnl ** check for eventfd which is needed by the I/O manager
@@ -337,6 +342,9 @@ case ${HostOS} in
AC_DEFINE_UNQUOTED([RTS_LINKER_USE_MMAP], [$RtsLinkerUseMmap],
[Use mmap in the runtime linker])
+GHC_ADJUSTORS_METHOD([Host])
+AC_SUBST([UseLibffiForAdjustors])
+
dnl ** Other RTS features
dnl --------------------------------------------------------------
AC_DEFINE_UNQUOTED([USE_LIBDW], [$CABAL_FLAG_libdw], [Set to 1 to use libdw])
@@ -420,7 +428,7 @@ dnl ######################################################################
[
cat $srcdir/rts.buildinfo.in \
- | "$CC" -E -P -traditional - -o - \
+ | "$CC" $buildinfoExtraDeps -E -P -traditional - -o - \
| sed -e '/^ *$/d' \
> rts.buildinfo \
|| exit 1
=====================================
rts/rts.buildinfo.in
=====================================
@@ -1,3 +1,6 @@
-- External symbols referenced by the RTS
+#ifdef NEED_PTHREAD_LIB
+extra-libraries: pthread
+#endif
ld-options:
#include "external-symbols.flags"
=====================================
rts/rts.cabal.in
=====================================
@@ -38,8 +38,6 @@ flag use-system-libffi
default: @CabalUseSystemLibFFI@
flag libffi-adjustors
default: @CabalLibffiAdjustors@
-flag need-pthread
- default: @CabalNeedLibpthread@
flag libbfd
default: @CabalHaveLibbfd@
flag need-atomic
@@ -52,8 +50,6 @@ flag libzstd
default: @CabalHaveLibZstd@
flag static-libzstd
default: @CabalStaticLibZstd@
-flag leading-underscore
- default: @CabalLeadingUnderscore@
flag smp
default: True
flag find-ptr
@@ -205,9 +201,6 @@ library
-- and also centralizes the versioning.
cpp-options: -D_WIN32_WINNT=0x06010000
cc-options: -D_WIN32_WINNT=0x06010000
- if flag(need-pthread)
- -- for pthread_getthreadid_np, pthread_create, ...
- extra-libraries: pthread
if flag(need-atomic)
-- for sub-word-sized atomic operations (#19119)
extra-libraries: atomic
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/f197176f528b52c1467009ae2a76c362951f6bcc...efc5cfefd59ba6a9a62c564bb8b6351961146334
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/f197176f528b52c1467009ae2a76c362951f6bcc...efc5cfefd59ba6a9a62c564bb8b6351961146334
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230922/90fab028/attachment-0001.html>
More information about the ghc-commits
mailing list