Fossil SCM

Comment improvements to [6f9d265234 | the recent change] in auto.def.

wyoung 2020-12-16 20:14 trunk
Commit 53caec9524d73e098b73de18b7ec20e9b1d718d016620689ea79366fd7514201
1 file changed +4 -3
+4 -3
--- auto.def
+++ auto.def
@@ -610,19 +610,20 @@
610610
# GCC with -fsanitize=undefined.
611611
cc-check-function-in-lib __ubsan_handle_add_overflow ubsan
612612
}
613613
}
614614
615
-# Finally, append -ldl to make sure it's the last in the list.
616
-# The library order matters in case of static linking.
615
+# Finally, append libraries that must be last. This matters more on some
616
+# OSes than others, but is most broadly required for static linking.
617617
if {[check-function-in-lib dlopen dl]} {
618618
# Some platforms (*BSD) have the dl functions already in libc and no libdl.
619619
# In such case we can link directly without -ldl.
620620
define-append LIBS [get-define lib_dlopen]
621621
}
622
-
623622
if {[opt-bool static]} {
623
+ # Linux can only infer the dependency on pthread from OpenSSL when
624
+ # doing dynamic linkage.
624625
define-append EXTRA_LDFLAGS -lpthread
625626
}
626627
627628
628629
make-template Makefile.in
629630
--- auto.def
+++ auto.def
@@ -610,19 +610,20 @@
610 # GCC with -fsanitize=undefined.
611 cc-check-function-in-lib __ubsan_handle_add_overflow ubsan
612 }
613 }
614
615 # Finally, append -ldl to make sure it's the last in the list.
616 # The library order matters in case of static linking.
617 if {[check-function-in-lib dlopen dl]} {
618 # Some platforms (*BSD) have the dl functions already in libc and no libdl.
619 # In such case we can link directly without -ldl.
620 define-append LIBS [get-define lib_dlopen]
621 }
622
623 if {[opt-bool static]} {
 
 
624 define-append EXTRA_LDFLAGS -lpthread
625 }
626
627
628 make-template Makefile.in
629
--- auto.def
+++ auto.def
@@ -610,19 +610,20 @@
610 # GCC with -fsanitize=undefined.
611 cc-check-function-in-lib __ubsan_handle_add_overflow ubsan
612 }
613 }
614
615 # Finally, append libraries that must be last. This matters more on some
616 # OSes than others, but is most broadly required for static linking.
617 if {[check-function-in-lib dlopen dl]} {
618 # Some platforms (*BSD) have the dl functions already in libc and no libdl.
619 # In such case we can link directly without -ldl.
620 define-append LIBS [get-define lib_dlopen]
621 }
 
622 if {[opt-bool static]} {
623 # Linux can only infer the dependency on pthread from OpenSSL when
624 # doing dynamic linkage.
625 define-append EXTRA_LDFLAGS -lpthread
626 }
627
628
629 make-template Makefile.in
630

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button