summaryrefslogtreecommitdiff
path: root/mbld/deps.myr
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2018-01-16 10:04:07 -0800
committerOri Bernstein <ori@eigenstate.org>2018-01-16 10:04:07 -0800
commit8f8899df9181abbde98ca28f8f7a8ff39cf17146 (patch)
tree14517ce08006226d026c26b359c0adc80784afe7 /mbld/deps.myr
parentac6c06f906d356b0004ed450558dd890c7057fbf (diff)
parent4db2895318842a451a5036652ea9373667a603b1 (diff)
downloadmc-8f8899df9181abbde98ca28f8f7a8ff39cf17146.tar.gz
Merge branch 'clink-obsd' of https://github.com/moreais/mc into trait-syntaxtrait-syntax
Diffstat (limited to 'mbld/deps.myr')
-rw-r--r--mbld/deps.myr13
1 files changed, 9 insertions, 4 deletions
diff --git a/mbld/deps.myr b/mbld/deps.myr
index ab90890..cae46b1 100644
--- a/mbld/deps.myr
+++ b/mbld/deps.myr
@@ -427,6 +427,8 @@ const arcmd = {b, n, mt, ar
}
const linkcmd = {b, n, mt, bin, libs, dynlibs, istest
+ var dynlink
+
for c : config.Linkcmd
std.slpush(&n.cmd, std.sldup(c))
;;
@@ -451,18 +453,21 @@ const linkcmd = {b, n, mt, bin, libs, dynlibs, istest
std.slpush(&n.cmd, std.sldup(o))
;;
- 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") && mt.isdyn
- std.slpush(&n.cmd, std.sldup("-dynamic-linker"))
- std.slpush(&n.cmd, std.sldup("/lib64/ld-linux-x86-64.so.2"))
;;
}