2008-04-08 17:10:09 +02:00
|
|
|
args : with args;
|
|
|
|
rec {
|
|
|
|
src = fetchurl {
|
2009-02-26 16:49:55 +01:00
|
|
|
url = http://downloads.sourceforge.net/lazarus/lazarus-0.9.26-0.tgz;
|
|
|
|
sha256 = "1pb6h35axdmg552pvazgi7jclkx93vssy08cbpa4jw3rij7drhnl";
|
2008-04-08 17:10:09 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [fpc gtk glib libXi inputproto
|
|
|
|
libX11 xproto libXext xextproto gdkpixbuf
|
|
|
|
stdenv.gcc makeWrapper];
|
|
|
|
configureFlags = [];
|
|
|
|
makeFlags = [
|
|
|
|
"LAZARUS_INSTALL_DIR=$out/lazarus/"
|
|
|
|
"INSTALL_PREFIX=$out/"
|
|
|
|
"FPC=fpc"
|
|
|
|
"PP=fpc"
|
|
|
|
];
|
|
|
|
|
|
|
|
/* doConfigure should be specified separately */
|
|
|
|
phaseNames = ["preBuild" "doMakeInstall" "postInstall"];
|
|
|
|
|
2009-05-20 01:25:58 +02:00
|
|
|
preBuild = fullDepEntry (''
|
2008-04-08 17:10:09 +02:00
|
|
|
export NIX_LDFLAGS='-lXi -lX11 -lglib -lgtk -lgdk -lgdk_pixbuf -lc -lXext'
|
|
|
|
ensureDir $out/share
|
|
|
|
tar xf ${fpc.src} --strip-components=1 -C $out/share
|
|
|
|
sed -e 's@/usr/fpcsrc@'"$out/share/fpcsrc@" -i ide/include/unix/lazbaseconf.inc
|
|
|
|
'')
|
|
|
|
["minInit" "defEnsureDir" "doUnpack"];
|
|
|
|
|
2009-05-20 01:25:58 +02:00
|
|
|
postInstall = fullDepEntry (''
|
2008-04-08 17:10:09 +02:00
|
|
|
wrapProgram $out/bin/startlazarus --prefix NIX_LDFLAGS ' ' "'$NIX_LDFLAGS'"
|
|
|
|
'') ["doMakeInstall" "minInit" "defEnsureDir"];
|
|
|
|
|
2009-02-26 16:49:55 +01:00
|
|
|
name = "lazarus-0.9.26-0";
|
2008-04-08 17:10:09 +02:00
|
|
|
meta = {
|
|
|
|
description = "Lazarus graphical IDE for FreePascal language";
|
|
|
|
homepage = http://www.lazarus.freepascal.org ;
|
|
|
|
};
|
|
|
|
}
|