angelscript_2_22: refactor
This commit is contained in:
parent
b419971ffa
commit
f961be2d12
|
@ -1,26 +1,19 @@
|
||||||
{lib, stdenv, fetchurl, unzip}:
|
{ lib, stdenv, fetchurl, unzip }:
|
||||||
let
|
|
||||||
s = # Generated upstream information
|
stdenv.mkDerivation rec {
|
||||||
rec {
|
pname = "angelscript";
|
||||||
baseName="angelscript";
|
version = "2.22.2";
|
||||||
version = "2.22.2";
|
|
||||||
name="${baseName}-${version}";
|
|
||||||
url="http://www.angelcode.com/angelscript/sdk/files/angelscript_${version}.zip";
|
|
||||||
sha256 = "1pp853lbnz383ilp9wbgc3wv1dn7lpx3idz8dmzda94rckl7sd43";
|
|
||||||
};
|
|
||||||
in
|
|
||||||
stdenv.mkDerivation {
|
|
||||||
inherit (s) name version;
|
|
||||||
nativeBuildInputs = [ unzip ];
|
nativeBuildInputs = [ unzip ];
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
inherit (s) url sha256;
|
url = "http://www.angelcode.com/angelscript/sdk/files/angelscript_${version}.zip";
|
||||||
|
sha256 = "sha256-gzR96GSZJNV+bei3OPqlx7aw+WBv8XRpHGh8u+go6N4=";
|
||||||
};
|
};
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
cd angelscript/projects/gnuc
|
cd angelscript/projects/gnuc
|
||||||
sed -i makefile -e "s@LOCAL = .*@LOCAL = $out@"
|
sed -i makefile -e "s@LOCAL = .*@LOCAL = $out@"
|
||||||
export SHARED=1
|
export SHARED=1
|
||||||
export VERSION="${s.version}"
|
export VERSION="${version}"
|
||||||
mkdir -p "$out/lib" "$out/bin" "$out/share" "$out/include"
|
mkdir -p "$out/lib" "$out/bin" "$out/share" "$out/include"
|
||||||
'';
|
'';
|
||||||
postBuild = ''
|
postBuild = ''
|
||||||
|
@ -30,14 +23,13 @@ stdenv.mkDerivation {
|
||||||
mkdir -p "$out/share/docs/angelscript"
|
mkdir -p "$out/share/docs/angelscript"
|
||||||
cp -r ../../../docs/* "$out/share/docs/angelscript"
|
cp -r ../../../docs/* "$out/share/docs/angelscript"
|
||||||
'';
|
'';
|
||||||
meta = {
|
meta = with lib; {
|
||||||
inherit (s) version;
|
|
||||||
description = "Light-weight scripting library";
|
description = "Light-weight scripting library";
|
||||||
license = lib.licenses.zlib ;
|
license = licenses.zlib;
|
||||||
maintainers = [lib.maintainers.raskin];
|
maintainers = with maintainers; [ raskin ];
|
||||||
platforms = lib.platforms.linux;
|
platforms = platforms.linux;
|
||||||
badPlatforms = [ "aarch64-linux" ];
|
badPlatforms = [ "aarch64-linux" ];
|
||||||
downloadPage = "http://www.angelcode.com/angelscript/downloads.html";
|
downloadPage = "http://www.angelcode.com/angelscript/downloads.html";
|
||||||
homepage="http://www.angelcode.com/angelscript/";
|
homepage = "http://www.angelcode.com/angelscript/";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue