@@ -1,4 +1,19 @@
1−{ stdenv, fetchurl, bash, unzip, glibc, openssl, libGLU_combined, freetype, xorg, alsaLib, cairo, libuuid, autoreconfHook, gcc48, ... }:
1+{ stdenv
2+, fetchurl
3+, bash
4+, unzip
5+, glibc
6+, openssl
7+, libgit2
8+, libGLU_combined
9+, freetype
10+, xorg
11+, alsaLib
12+, cairo
13+, libuuid
14+, autoreconfHook
15+, gcc48
16+, ... }:
217
318{ name, src, version, source-date, source-url, ... }:
419
@@ -65,7 +80,19 @@ stdenv.mkDerivation rec {
6580
6681 # (No special build phase.)
6782
68− installPhase = ''
83+ installPhase = let
84+ libs = [
85+ cairo
86+ libgit2
87+ libGLU_combined
88+ freetype
89+ openssl
90+ libuuid
91+ alsaLib
92+ xorg.libICE
93+ xorg.libSM
94+ ];
95+ in ''
6996 # Install in working directory and then copy
7097 make install-squeak install-plugins prefix=$(pwd)/products
7198
@@ -83,7 +110,7 @@ stdenv.mkDerivation rec {
83110 mkdir -p "$out/bin"
84111
85112 # Note: include ELF rpath in LD_LIBRARY_PATH for finding libc.
86− libs=$out:$(patchelf --print-rpath "$out/pharo"):${cairo}/lib:${libGLU_combined}/lib:${freetype}/lib:${openssl}/lib:${libuuid}/lib:${alsaLib}/lib:${xorg.libICE}/lib:${xorg.libSM}/lib
113+ libs=$out:$(patchelf --print-rpath "$out/pharo"):${stdenv.lib.makeLibraryPath libs}
87114
88115 # Create the script
89116 cat > "$out/bin/${cmd}" <<EOF
@@ -92,6 +119,7 @@ stdenv.mkDerivation rec {
92119 LD_LIBRARY_PATH="\$LD_LIBRARY_PATH:$libs" exec $out/pharo "\$@"
93120 EOF
94121 chmod +x "$out/bin/${cmd}"
122+ ln -s ${libgit2}/lib/libgit2.so* "$out/"
95123 '';
96124
97125 enableParallelBuilding = true;
@@ -104,7 +132,22 @@ stdenv.mkDerivation rec {
104132 #
105133 # (stack protection is disabled above for gcc 4.8 compatibility.)
106134 nativeBuildInputs = [ autoreconfHook ];
107− buildInputs = [ bash unzip glibc openssl gcc48 libGLU_combined freetype xorg.libX11 xorg.libICE xorg.libSM alsaLib cairo pharo-share libuuid ];
135+ buildInputs = [
136+ bash
137+ unzip
138+ glibc
139+ openssl
140+ gcc48
141+ libGLU_combined
142+ freetype
143+ xorg.libX11
144+ xorg.libICE
145+ xorg.libSM
146+ alsaLib
147+ cairo
148+ pharo-share
149+ libuuid
150+ ];
108151
109152 meta = with stdenv.lib; {
110153 description = "Clean and innovative Smalltalk-inspired environment";