3
0
Fork 0
forked from mirrors/nixpkgs

mruby: Fixes build on Linux

I'm not sure of the semantics of `gcc` vs. `ld` for linking, but it
makes the difference between working and:

```
/nix/store/gpc2wld1s0c6qzx9326cwn1wcx29xzsj-binutils-2.30/bin/ld: warning: cannot find entry symbol _start; defaulting to 0000000000401100
```
This commit is contained in:
Samuel Dionne-Riel 2018-08-09 19:10:24 -04:00
parent c26a6db0f8
commit f847155014

View file

@ -13,6 +13,10 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ ruby bison ];
# Necessary so it uses `gcc` instead of `ld` for linking.
# https://github.com/mruby/mruby/blob/35be8b252495d92ca811d76996f03c470ee33380/tasks/toolchains/gcc.rake#L25
preBuild = if stdenv.isLinux then "unset LD" else null;
installPhase = ''
mkdir $out
cp -R build/host/{bin,lib} $out