forked from ocaml-multicore/ocaml-multicore
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Provide a way to build the bytecode compiler using Dune (#2093)
- Loading branch information
Showing
25 changed files
with
953 additions
and
131 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,6 +34,8 @@ | |
_ocamltest | ||
_ocamltestd | ||
*.odoc | ||
.merlin | ||
_build | ||
|
||
# local to root directory | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
;************************************************************************** | ||
;* * | ||
;* OCaml * | ||
;* * | ||
;* Thomas Refis, Jane Street Europe * | ||
;* * | ||
;* Copyright 2018 Jane Street Group LLC * | ||
;* * | ||
;* All rights reserved. This file is distributed under the terms of * | ||
;* the GNU Lesser General Public License version 2.1, with the * | ||
;* special exception on linking described in the file LICENSE. * | ||
;* * | ||
;************************************************************************** | ||
|
||
(rule | ||
(targets arch.ml CSE.ml proc.ml reload.ml scheduling.ml selection.ml) | ||
(mode fallback) | ||
(deps (:conf ../Makefile.config) | ||
(glob_files amd64/*.ml) | ||
(glob_files arm/*.ml) | ||
(glob_files arm64/*.ml) | ||
(glob_files i386/*.ml) | ||
(glob_files power/*.ml) | ||
(glob_files s390x/*.ml)) | ||
(action (bash "cp `grep 'ARCH=' %{conf} | cut -d'=' -f2`/*.ml ."))) | ||
|
||
(rule | ||
(targets emit.ml) | ||
(mode fallback) | ||
(deps (:conf ../Makefile.config) | ||
amd64/emit.mlp | ||
arm/emit.mlp | ||
arm64/emit.mlp | ||
i386/emit.mlp | ||
power/emit.mlp | ||
s390x/emit.mlp) | ||
(action | ||
(progn | ||
(with-stdout-to contains-input-name | ||
(bash "echo `grep 'ARCH=' %{conf} | cut -d'=' -f2`/emit.mlp")) | ||
(with-stdout-to %{targets} | ||
(progn | ||
(bash "echo \\# 1 \\\"`cat contains-input-name`\\\"") | ||
(bash "%{dep:../tools/cvt_emit.exe} < `cat contains-input-name`")))))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
;************************************************************************** | ||
;* * | ||
;* OCaml * | ||
;* * | ||
;* Thomas Refis, Jane Street Europe * | ||
;* * | ||
;* Copyright 2018 Jane Street Group LLC * | ||
;* * | ||
;* All rights reserved. This file is distributed under the terms of * | ||
;* the GNU Lesser General Public License version 2.1, with the * | ||
;* special exception on linking described in the file LICENSE. * | ||
;* * | ||
;************************************************************************** | ||
|
||
(rule | ||
(targets opcodes.ml) | ||
(mode fallback) | ||
(deps (:instr (file ../runtime/caml/instruct.h))) | ||
(action | ||
(bash "%{dep:../tools/make_opcodes.exe} -opcodes < %{instr} > %{targets}"))) | ||
|
||
(rule | ||
(targets runtimedef.ml) | ||
(mode fallback) | ||
(deps (:fail (file ../runtime/caml/fail.h)) | ||
(:prim (file ../runtime/primitives))) | ||
(action (with-stdout-to %{targets} | ||
(run ./generate_runtimedef.sh %{fail} %{prim})))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/bin/bash | ||
|
||
#************************************************************************** | ||
#* * | ||
#* OCaml * | ||
#* * | ||
#* Xavier Leroy, projet Cristal, INRIA Rocquencourt * | ||
#* * | ||
#* Copyright 1999 Institut National de Recherche en Informatique et * | ||
#* en Automatique. * | ||
#* * | ||
#* All rights reserved. This file is distributed under the terms of * | ||
#* the GNU Lesser General Public License version 2.1, with the * | ||
#* special exception on linking described in the file LICENSE. * | ||
#* * | ||
#************************************************************************** | ||
|
||
echo 'let builtin_exceptions = [|' | ||
cat "$1" | tr -d '\r' | \ | ||
sed -n -e 's|.*/\* \("[A-Za-z_]*"\) \*/$| \1;|p' | ||
echo '|]' | ||
|
||
echo 'let builtin_primitives = [|' | ||
sed -e 's/.*/ "&";/' "$2" | ||
echo '|]' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
;************************************************************************** | ||
;* * | ||
;* OCaml * | ||
;* * | ||
;* Thomas Refis, Jane Street Europe * | ||
;* * | ||
;* Copyright 2018 Jane Street Group LLC * | ||
;* * | ||
;* All rights reserved. This file is distributed under the terms of * | ||
;* the GNU Lesser General Public License version 2.1, with the * | ||
;* special exception on linking described in the file LICENSE. * | ||
;* * | ||
;************************************************************************** | ||
|
||
(ocamllex lexer) | ||
(ocamlyacc parser) | ||
|
||
(executable | ||
(name main) | ||
(modes byte) | ||
(flags (:standard -w -9)) | ||
(modules_without_implementation parser_aux) | ||
(libraries ocamlcommon ocamltoplevel runtime stdlib unix)) | ||
|
||
(rule (copy main.exe ocamldebug.byte)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
(rule | ||
(targets compdynlink.ml) | ||
(deps (:ml (file ../otherlibs/dynlink/dynlink.ml))) | ||
(action | ||
(with-stdout-to %{targets} | ||
(bash "grep -v 'REMOVE_ME for ../../debugger/dynlink.ml' %{ml}")))) |
Oops, something went wrong.