2018-09-08 16:30:30 +01:00
|
|
|
{ stdenv, fetchFromGitHub, pkgconfig, go, gobjectIntrospection, libgudev }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "${pname}-${version}";
|
|
|
|
pname = "go-gir-generator";
|
|
|
|
version = "1.0.4";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "linuxdeepin";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
|
|
|
sha256 = "0yi3lsgkxi8ghz2c7msf2df20jxkvzj8s47slvpzz4m57i82vgzl";
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkgconfig
|
|
|
|
go
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
gobjectIntrospection
|
|
|
|
libgudev
|
|
|
|
];
|
|
|
|
|
2018-10-12 12:06:54 +01:00
|
|
|
postPatch = ''
|
|
|
|
sed -i -e 's:/share/gocode:/share/go:' Makefile
|
|
|
|
'';
|
|
|
|
|
2018-09-08 16:30:30 +01:00
|
|
|
makeFlags = [
|
|
|
|
"PREFIX=$(out)"
|
2018-10-12 12:06:54 +01:00
|
|
|
"GOCACHE=off"
|
2018-09-08 16:30:30 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Generate static golang bindings for GObject";
|
|
|
|
homepage = https://github.com/linuxdeepin/go-gir-generator;
|
|
|
|
license = licenses.gpl3;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ romildo ];
|
|
|
|
};
|
|
|
|
}
|