mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-04-12 06:49:02 +02:00
Only allow __Dmain to remain undefined in druntime to avoid hidden build errors.
This commit is contained in:
@@ -30,7 +30,9 @@ set(D_FLAGS -g -w -d CACHE STRING "runtime build flags, separated by ;")
|
||||
if(BUILD_SHARED_LIBS)
|
||||
list(APPEND D_FLAGS -relocation-model=pic)
|
||||
if(APPLE)
|
||||
list(APPEND LD_FLAGS -Wl,-undefined,dynamic_lookup)
|
||||
# We need to explicitly specify that __Dmain should be resolved at
|
||||
# runtime with the default OS X tool chain.
|
||||
list(APPEND LD_FLAGS -Wl,-U,__Dmain)
|
||||
endif()
|
||||
set(D_LIBRARY_TYPE SHARED)
|
||||
else(BUILD_SHARED_LIBS)
|
||||
|
||||
Reference in New Issue
Block a user