2018-03-14 20:36:47 +01:00
|
|
|
|
{ stdenv, fetchFromGitHub, zlib, jdk, CoreServices, Foundation }:
|
2016-06-02 16:34:35 +02:00
|
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
|
pname = "avian";
|
2016-06-02 16:34:35 +02:00
|
|
|
|
version = "1.2.0";
|
|
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
|
owner = "readytalk";
|
|
|
|
|
repo = "avian";
|
|
|
|
|
rev = "v${version}";
|
|
|
|
|
sha256 = "1j2y45cpqk3x6a743mgpg7z3ivwm7qc9jy6xirvay7ah1qyxmm48";
|
|
|
|
|
};
|
|
|
|
|
|
2018-03-14 20:36:47 +01:00
|
|
|
|
buildInputs = [ zlib jdk ]
|
|
|
|
|
++ stdenv.lib.optionals stdenv.isDarwin [ CoreServices Foundation ];
|
|
|
|
|
|
2018-06-11 02:34:40 +02:00
|
|
|
|
NIX_CFLAGS_COMPILE = "-Wno-error";
|
2018-03-14 20:36:47 +01:00
|
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
|
substituteInPlace makefile \
|
|
|
|
|
--replace 'g++' 'c++' \
|
|
|
|
|
--replace 'gcc' 'cc'
|
|
|
|
|
'';
|
2016-06-02 16:34:35 +02:00
|
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
|
mkdir -p $out/bin
|
|
|
|
|
cp build/*/avian $out/bin/
|
|
|
|
|
cp build/*/avian-dynamic $out/bin/
|
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
|
description = "Lightweight Java virtual machine";
|
|
|
|
|
longDescription = ''
|
|
|
|
|
Avian is a lightweight virtual machine and class library designed
|
|
|
|
|
to provide a useful subset of Java’s features, suitable for
|
|
|
|
|
building self-contained applications.
|
|
|
|
|
'';
|
2020-04-01 03:11:51 +02:00
|
|
|
|
homepage = "https://readytalk.github.io/avian/";
|
2016-06-02 16:34:35 +02:00
|
|
|
|
license = stdenv.lib.licenses.isc;
|
|
|
|
|
platforms = stdenv.lib.platforms.all;
|
2017-10-22 22:50:43 +02:00
|
|
|
|
maintainers = [ stdenv.lib.maintainers.earldouglas ];
|
2016-06-02 16:34:35 +02:00
|
|
|
|
};
|
|
|
|
|
}
|