Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,6 @@
path = syntax
url = https://github.com/rescript-lang/syntax
branch = master
[submodule "ninja"]
path = ninja
url = git@github.com:rescript-lang/ninja.git
1 change: 1 addition & 0 deletions ninja
Submodule ninja added at 6deefa
11 changes: 9 additions & 2 deletions scripts/prebuilt.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ var hostPlatform = "darwin";
function rebuild() {
cp.execSync(`node ${path.join(__dirname, "ninja.js")} cleanbuild`, {
cwd: __dirname,
stdio: [0, 1, 2]
stdio: [0, 1, 2],
});
}

Expand All @@ -28,7 +28,7 @@ function buildCompiler() {
? `ocamlopt.opt.exe`
: `../native/${ocamlVersion}/bin/ocamlopt.opt`,
INCL: ocamlVersion,
isWin: is_windows
isWin: is_windows,
});

fs.writeFileSync(path.join(root, "lib", prebuilt), content, "ascii");
Expand All @@ -52,12 +52,19 @@ if (!is_windows) {
function createOCamlTar() {
if (process.platform === hostPlatform) {
require("./installUtils.js").install();
console.log(`status in ocaml submodule:`)
cp.execSync(`git -C ocaml status -uno`, { cwd: root, stdio: [0, 1, 2] });
cp.execSync(
`git -C ocaml archive --format=tar.gz HEAD -o ../vendor/ocaml.tar.gz`,
{ cwd: root, stdio: [0, 1, 2] }
);
}
console.log(`status in ninja submodule:`)
cp.execSync(`git -C ninja status -uno`, { cwd: root, stdio: [0, 1, 2] });
cp.execSync(
`git -C ninja archive --format=tar.gz HEAD -o ../vendor/ninja.tar.gz`,
{ cwd: root, stdio: [0, 1, 2] }
);
}

createOCamlTar();
Expand Down
Binary file removed vendor/ninja.tar.gz
Binary file not shown.