termux-packages/packages/ldc/ldc-linker-flags.patch
2018-08-21 00:49:42 +02:00

15 lines
744 B
Diff

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 336bbdbc..4b9e8c88 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -591,7 +591,8 @@ if(UNIX AND (CMAKE_COMPILER_IS_GNUCXX OR (${CMAKE_CXX_COMPILER_ID} STREQUAL "Cla
message(FATAL_ERROR "GDMD currently not supported due to http://bugzilla.gdcproject.org/show_bug.cgi?id=232.")
endif()
- include(ExtractDMDSystemLinker)
+ #include(ExtractDMDSystemLinker)
+ set(D_LINKER_ARGS "-fuse-ld=bfd;-Lldc-build-runtime.tmp/lib;-lphobos2-ldc;-ldruntime-ldc;-Wl,--gc-sections")
message(STATUS "Host D compiler linker program: ${D_LINKER_COMMAND}")
message(STATUS "Host D compiler linker flags: ${D_LINKER_ARGS}")
list(APPEND LDC_LINKERFLAG_LIST ${D_LINKER_ARGS})