summaryrefslogtreecommitdiff
path: root/mbld
diff options
context:
space:
mode:
authorCarlin Bingham <cb@viennan.net>2018-01-17 01:24:19 +1300
committerCarlin Bingham <cb@viennan.net>2018-01-17 01:57:28 +1300
commit4db2895318842a451a5036652ea9373667a603b1 (patch)
treea2ffb492a013b4de6786f1a12462bef83549ff9a /mbld
parent1f2656eeadb7b3230f92fbdfe1f31eebc5f81a71 (diff)
downloadmc-4db2895318842a451a5036652ea9373667a603b1.tar.gz
Make mbld use dynamic linker flags from configure
Diffstat (limited to 'mbld')
-rw-r--r--mbld/deps.myr11
1 files changed, 7 insertions, 4 deletions
diff --git a/mbld/deps.myr b/mbld/deps.myr
index a95bef8..a99a471 100644
--- a/mbld/deps.myr
+++ b/mbld/deps.myr
@@ -455,18 +455,21 @@ const linkcmd = {b, n, mt, bin, libs, dynlibs, istest
std.slpush(&n.cmd, std.sldup(o))
;;
- dynlink = addlibs(b, &n.cmd, libs, mt.incpath)
+ dynlink = addlibs(b, &n.cmd, libs, mt.incpath) || mt.isdyn
for l : dynlibs
std.slpush(&n.cmd, std.fmt("-l{}", l))
;;
+ if dynlink
+ for f : config.Dlflags
+ std.slpush(&n.cmd, std.sldup(f))
+ ;;
+ ;;
+
/* OSX warns if we don't add a version */
if std.sleq(opt_sys, "osx")
std.slpush(&n.cmd, std.sldup("-macosx_version_min"))
std.slpush(&n.cmd, std.sldup("10.6"))
- elif std.sleq(opt_sys, "linux") && (dynlink || mt.isdyn)
- std.slpush(&n.cmd, std.sldup("-dynamic-linker"))
- std.slpush(&n.cmd, std.sldup("/lib64/ld-linux-x86-64.so.2"))
;;
}