• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-cqtcocoa誰得pythonphprubygameguibathyscaphec翻訳計画中(planning stage)omegatframeworktwittertestdomvb.netdirectxbtronarduinopreviewerゲームエンジン

A categorical programming language


Commit MetaInfo

修订版85c53c3d45efeb70dd8edc9957f5952d940cf6b8 (tree)
时间2021-09-08 11:09:30
作者Corbin <cds@corb...>
CommiterCorbin

Log Message

Build movelist with Nix.

更改概述

差异

--- a/compile.sh
+++ b/compile.sh
@@ -16,7 +16,8 @@ fullname=$(basename -- $1)
1616 name="${fullname%.*}"
1717
1818 # Typecheck with movelist.
19-ty=$(./movelist type-check <"$tmpdir/program.cammy")
19+movelist=$(nix-build movelist/)
20+ty=$($movelist/bin/movelist type-check <"$tmpdir/program.cammy")
2021
2122 # Compute the final piece.
2223 cat "$tmpdir/program.cammy"
--- /dev/null
+++ b/movelist/default.nix
@@ -0,0 +1,24 @@
1+{ nixpkgs ? import <nixpkgs> {} }:
2+let
3+ pkgs = nixpkgs.pkgs;
4+in pkgs.stdenv.mkDerivation {
5+ name = "movelist";
6+ version = "0.0.1";
7+
8+ buildInputs = [
9+ pkgs.chicken
10+ ] ++ (with pkgs.chickenPackages.chickenEggs; [
11+ matchable mini-kanren
12+ ]);
13+
14+ src = ./.;
15+
16+ buildPhase = ''
17+ csc -O3 -o movelist movelist.scm
18+ '';
19+
20+ installPhase = ''
21+ mkdir -p $out/bin/
22+ cp movelist $out/bin/
23+ '';
24+}