mirror of
https://github.com/ProgramSnail/Lama.git
synced 2025-12-06 06:48:48 +00:00
Disable x32 when os_type = Darwin
Signed-off-by: Kakadu <Kakadu@pm.me>
This commit is contained in:
parent
59273f734e
commit
8a8fc3432b
10 changed files with 22 additions and 28 deletions
|
|
@ -5,6 +5,7 @@ let demos = ["Expressions"; "Functions"; "Hello"; "PatternMatching"; "Values"]
|
|||
let template = {|
|
||||
(rule
|
||||
(targets %DEMO%.exe)
|
||||
%COND%
|
||||
(deps (:lama %DEMOSRC%.lama) %RUNTIME%/runtime.a %STDLIB%/Fun.i)
|
||||
(mode
|
||||
(promote (until-clean)))
|
||||
|
|
@ -30,6 +31,7 @@ let () =
|
|||
template
|
||||
|> Str.global_replace (Str.regexp "%DEMO%") (demo^".x32")
|
||||
|> Str.global_replace (Str.regexp "%DEMOSRC%") demo
|
||||
|> Str.global_replace (Str.regexp "%COND%") {|(enabled_if (<> %{ocaml-config:os_type} "Darwin"))|}
|
||||
|> Str.global_replace (Str.regexp "%RUNTIME%") "../runtime32"
|
||||
|> Str.global_replace (Str.regexp "%STDLIB%") "../stdlib/x32"
|
||||
|> Str.global_replace (Str.regexp "%EXTRASWITCHES%") "-march=x86"
|
||||
|
|
@ -37,6 +39,7 @@ let () =
|
|||
template
|
||||
|> Str.global_replace (Str.regexp "%DEMO%") (demo^".x64")
|
||||
|> Str.global_replace (Str.regexp "%DEMOSRC%") demo
|
||||
|> Str.global_replace (Str.regexp "%COND%") ""
|
||||
|> Str.global_replace (Str.regexp "%RUNTIME%") "../runtime"
|
||||
|> Str.global_replace (Str.regexp "%STDLIB%") "../stdlib/x64"
|
||||
|> Str.global_replace (Str.regexp "%EXTRASWITCHES%") "-march=x86_64"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue