diff options
| author | 2019-03-03 15:18:17 -0500 | |
|---|---|---|
| committer | 2019-03-03 15:18:17 -0500 | |
| commit | 6158ec0ce55ace7c9bb224c535132ef4c8d5830a (patch) | |
| tree | 8a87d5615e2662cd0e4be0a1c1bb660f7d147ef3 /tools | |
| parent | Travis add sudo. (diff) | |
Add -undefined dynamic_lookup on mac.
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/cook.janet | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/cook.janet b/tools/cook.janet index 28597eca..7803d30f 100644 --- a/tools/cook.janet +++ b/tools/cook.janet @@ -3,6 +3,7 @@ # Windows is the OS outlier (def- is-win (= (os/which) :windows)) +(def- is-mac (= (os/which) :macos)) (def- sep (if is-win "\\" "/")) (def- objext (if is-win ".obj" ".o")) (def- modext (if is-win ".dll" ".so")) @@ -93,7 +94,11 @@ # Defaults (def OPTIMIZE 2) (def CC (if is-win "cl" "cc")) -(def LD (if is-win "link" (string CC " -shared"))) +(def LD (if is-win + "link" + (string CC + " -shared" + (if is-mac " -undefined dynamic_lookup" "")))) (def CFLAGS (string (if is-win "/I" "-I") module/*syspath* |
