cgui: use stdenv
This replaces use of `builderDefsPackage`.
This commit is contained in:
parent
7ce3f6f976
commit
6ca0480de6
@ -1,57 +1,26 @@
|
|||||||
x@{builderDefsPackage
|
{ stdenv, fetchurl, texinfo, allegro, perl }:
|
||||||
, texinfo, allegro, perl
|
|
||||||
, ...}:
|
|
||||||
builderDefsPackage
|
|
||||||
(a :
|
|
||||||
let
|
|
||||||
helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++
|
|
||||||
[];
|
|
||||||
|
|
||||||
buildInputs = map (n: builtins.getAttr n x)
|
stdenv.mkDerivation rec {
|
||||||
(builtins.attrNames (builtins.removeAttrs x helperArgNames));
|
name = "cgui-${version}";
|
||||||
sourceInfo = rec {
|
version="2.0.3";
|
||||||
baseName="cgui";
|
|
||||||
version="2.0.3";
|
src = fetchurl {
|
||||||
name="${baseName}-${version}";
|
url = "mirror://sourceforge/project/cgui/${version}/${name}.tar.gz";
|
||||||
project="${baseName}";
|
sha256 = "00kk4xaw68m44awy8zq4g5plx372swwccvzshn68a0a8f3f2wi4x";
|
||||||
url="mirror://sourceforge/project/${project}/${version}/${name}.tar.gz";
|
|
||||||
hash="00kk4xaw68m44awy8zq4g5plx372swwccvzshn68a0a8f3f2wi4x";
|
|
||||||
};
|
|
||||||
in
|
|
||||||
rec {
|
|
||||||
src = a.fetchurl {
|
|
||||||
url = sourceInfo.url;
|
|
||||||
sha256 = sourceInfo.hash;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inherit (sourceInfo) name version;
|
buildInputs = [ texinfo allegro perl ];
|
||||||
inherit buildInputs;
|
|
||||||
|
|
||||||
/* doConfigure should be removed if not needed */
|
configurePhase = ''
|
||||||
phaseNames = ["genMakefile" "doMakeInstall"];
|
|
||||||
|
|
||||||
genMakefile = a.fullDepEntry (''
|
|
||||||
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -fPIC"
|
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -fPIC"
|
||||||
sh fix.sh unix
|
sh fix.sh unix
|
||||||
'') ["minInit" "doUnpack" "addInputs"];
|
'';
|
||||||
|
|
||||||
makeFlags = [
|
|
||||||
"SYSTEM_DIR=$out"
|
|
||||||
];
|
|
||||||
|
|
||||||
meta = {
|
makeFlags = [ "SYSTEM_DIR=$(out)" ];
|
||||||
|
|
||||||
|
meta = with stdenv.lib; {
|
||||||
description = "A multiplatform basic GUI library";
|
description = "A multiplatform basic GUI library";
|
||||||
maintainers = with a.lib.maintainers;
|
maintainers = [ maintainers.raskin ];
|
||||||
[
|
platforms = platforms.linux;
|
||||||
raskin
|
|
||||||
];
|
|
||||||
platforms = with a.lib.platforms;
|
|
||||||
linux;
|
|
||||||
};
|
};
|
||||||
passthru = {
|
}
|
||||||
updateInfo = {
|
|
||||||
downloadPage = "http://sourceforge.net/projects/cgui/files/";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}) x
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user