mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-05 17:43:35 +03:00
Merge remote-tracking branch 'origin/ltsmaster'
This commit is contained in:
commit
0b2d7e7969
3 changed files with 7 additions and 3 deletions
|
@ -153,7 +153,11 @@ static int linkObjToBinaryGcc(bool sharedLib, bool fullyStatic) {
|
||||||
// Don't push -l and -L switches using -Xlinker, but pass them indirectly
|
// Don't push -l and -L switches using -Xlinker, but pass them indirectly
|
||||||
// via GCC. This makes sure user-defined paths take precedence over
|
// via GCC. This makes sure user-defined paths take precedence over
|
||||||
// GCC's builtin LIBRARY_PATHs.
|
// GCC's builtin LIBRARY_PATHs.
|
||||||
if (!p[0] || !(p[0] == '-' && (p[1] == 'l' || p[1] == 'L'))) {
|
// Options starting with -shared and -static are not handled by
|
||||||
|
// the linker and must be passed to the driver.
|
||||||
|
auto str = llvm::StringRef(p);
|
||||||
|
if (!(str.startswith("-l") || str.startswith("-L") ||
|
||||||
|
str.startswith("-shared") || str.startswith("-static"))) {
|
||||||
args.push_back("-Xlinker");
|
args.push_back("-Xlinker");
|
||||||
}
|
}
|
||||||
args.push_back(p);
|
args.push_back(p);
|
||||||
|
|
|
@ -12,7 +12,7 @@ set(MULTILIB OFF CACHE BOOL
|
||||||
set(BUILD_BC_LIBS OFF CACHE BOOL "Build the runtime as LLVM bitcode libraries")
|
set(BUILD_BC_LIBS OFF CACHE BOOL "Build the runtime as LLVM bitcode libraries")
|
||||||
set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/include/d CACHE PATH "Path to install D modules to")
|
set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/include/d CACHE PATH "Path to install D modules to")
|
||||||
set(BUILD_SHARED_LIBS OFF CACHE BOOL "Whether to build the runtime as a shared library")
|
set(BUILD_SHARED_LIBS OFF CACHE BOOL "Whether to build the runtime as a shared library")
|
||||||
set(D_FLAGS -w;-d CACHE STRING "Runtime build flags, separated by ;")
|
set(D_FLAGS -w CACHE STRING "Runtime build flags, separated by ;")
|
||||||
set(D_FLAGS_DEBUG -g;-link-debuglib CACHE STRING "Runtime build flags (debug libraries), separated by ;")
|
set(D_FLAGS_DEBUG -g;-link-debuglib CACHE STRING "Runtime build flags (debug libraries), separated by ;")
|
||||||
set(D_FLAGS_RELEASE -O3;-release CACHE STRING "Runtime build flags (release libraries), separated by ;")
|
set(D_FLAGS_RELEASE -O3;-release CACHE STRING "Runtime build flags (release libraries), separated by ;")
|
||||||
if(MSVC)
|
if(MSVC)
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 545ac5b5bac60de24c1cebb165a713e58364b7de
|
Subproject commit dd3402bdd02480a70653a3d0937afa566bce5fb2
|
Loading…
Add table
Add a link
Reference in a new issue