tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
gbforth: init at unstable-2023-03-02
Francesco Gazzetta
2 years ago
e4a5147c
8836d9cf
+56
2 changed files
expand all
collapse all
unified
split
pkgs
development
compilers
gbforth
default.nix
top-level
all-packages.nix
+54
pkgs/development/compilers/gbforth/default.nix
···
1
1
+
{ lib
2
2
+
, stdenv
3
3
+
, fetchFromGitHub
4
4
+
, makeWrapper
5
5
+
, gforth
6
6
+
}:
7
7
+
8
8
+
stdenv.mkDerivation {
9
9
+
pname = "gbforth";
10
10
+
version = "unstable-2023-03-02";
11
11
+
12
12
+
src = fetchFromGitHub {
13
13
+
owner = "ams-hackers";
14
14
+
repo = "gbforth";
15
15
+
rev = "428fcf5054fe301e90ac74b1d920ee3ecc375b5b";
16
16
+
hash = "sha256-v1bdwT15Wg1VKpo74Cc3tsTl1uOKvKdlHWtbZkJ/qbA=";
17
17
+
};
18
18
+
19
19
+
nativeBuildInputs = [
20
20
+
makeWrapper
21
21
+
];
22
22
+
23
23
+
dontBuild = true;
24
24
+
25
25
+
installPhase = ''
26
26
+
runHook preInstall
27
27
+
mkdir -p $out/share/gbforth $out/bin
28
28
+
cp -r lib shared src gbforth.fs $out/share/gbforth/
29
29
+
makeWrapper ${gforth}/bin/gforth $out/bin/gbforth \
30
30
+
--set GBFORTH_PATH $out/share/gbforth/lib \
31
31
+
--add-flags $out/share/gbforth/gbforth.fs
32
32
+
runHook postInstall
33
33
+
'';
34
34
+
35
35
+
doInstallCheck = true;
36
36
+
installCheckPhase = ''
37
37
+
runHook preInstallCheck
38
38
+
$out/bin/gbforth examples/simon/simon.fs
39
39
+
runHook postInstallCheck
40
40
+
'';
41
41
+
42
42
+
meta = with lib; {
43
43
+
homepage = "https://gbforth.org/";
44
44
+
description = "A Forth-based Game Boy development kit";
45
45
+
longDescription = ''
46
46
+
A Forth-based Game Boy development kit.
47
47
+
It features a Forth-based assembler, a cross-compiler with support for
48
48
+
lazy code generation and a library of useful words.
49
49
+
'';
50
50
+
license = licenses.mit;
51
51
+
platforms = platforms.all;
52
52
+
maintainers = with maintainers; [ fgaz ];
53
53
+
};
54
54
+
}
+2
pkgs/top-level/all-packages.nix
···
14295
14295
gerbil-support = callPackage ../development/compilers/gerbil/gerbil-support.nix { };
14296
14296
gerbilPackages-unstable = gerbil-support.gerbilPackages-unstable; # NB: don't recurseIntoAttrs for (unstable!) libraries
14297
14297
14298
14298
+
gbforth = callPackage ../development/compilers/gbforth { };
14299
14299
+
14298
14300
inherit (let
14299
14301
num =
14300
14302
if (with stdenv.targetPlatform; isVc4 || libc == "relibc") then 6