diff options
author | Jason Felice <jason.m.felice@gmail.com> | 2019-06-11 11:48:57 -0400 |
---|---|---|
committer | Jason Felice <jason.m.felice@gmail.com> | 2019-06-11 16:32:59 -0400 |
commit | 26aef37424aa1791777715d3c3a48bd799b7ffef (patch) | |
tree | 52b8f98592f214872eb05b70849ca067c91968a5 /pkgs/tools/system | |
parent | 9d11c30cf9626b6a2bc955eb47506dbf03a5e917 (diff) | |
download | nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.tar nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.tar.gz nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.tar.bz2 nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.tar.lz nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.tar.xz nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.tar.zst nixlib-26aef37424aa1791777715d3c3a48bd799b7ffef.zip |
plan9port: build everything on Darwin
A commit in 2014 (see #2266) disabled building parts which depended on X11 on Mac OS. There's no explanation given in the pull request. In any case, many people install plan9port on Darwin specifically to use the UI components. Aside from this, the derivation was broken on Mac OS, probably because people put the `which` and `perl` dependencies inside the !isDarwin conditional. Some programs worked, however the static libraries did not build, so this could not be used as a buildInput to build programs which need the libraries. This fixes that.
Diffstat (limited to 'pkgs/tools/system')
-rw-r--r-- | pkgs/tools/system/plan9port/default.nix | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/pkgs/tools/system/plan9port/default.nix b/pkgs/tools/system/plan9port/default.nix index c14fbc49e0d5..b3909a79d942 100644 --- a/pkgs/tools/system/plan9port/default.nix +++ b/pkgs/tools/system/plan9port/default.nix @@ -34,7 +34,7 @@ stdenv.mkDerivation rec { --replace "case Kcmd+'v':" "case 0x16: case Kcmd+'v':" ''; - buildInputs = stdenv.lib.optionals (!stdenv.isDarwin) [ + buildInputs = [ which perl libX11 fontconfig xorgproto libXt libXext freetype # fontsrv wants ft2build.h provides system fonts for acme and sam. ]; @@ -60,6 +60,27 @@ stdenv.mkDerivation rec { NIX_LDFLAGS="-lgcc_s"; enableParallelBuilding = true; + doInstallCheck = true; + installCheckPhase = '' + $out/bin/9 rc -c 'echo rc is working.' + + # 9l can find and use its libs + cd $TMP + cat >test.c <<EOF + #include <u.h> + #include <libc.h> + #include <thread.h> + void + threadmain(int argc, char **argv) + { + threadexitsall(nil); + } + EOF + $out/bin/9 9c -o test.o test.c + $out/bin/9 9l -o test test.o + ./test + ''; + meta = with stdenv.lib; { homepage = https://9fans.github.io/plan9port/; description = "Plan 9 from User Space"; |