2018-12-02 11:41:15 +00:00
|
|
|
{ stdenv, fetchFromGitHub, pkgconfig, go, gobject-introspection,
|
2019-06-16 20:59:06 +01:00
|
|
|
libgudev, deepin }:
|
2018-09-08 16:30:30 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "go-gir-generator";
|
2019-06-22 13:26:34 +01:00
|
|
|
version = "2.0.2";
|
2018-09-08 16:30:30 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "linuxdeepin";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2019-06-22 13:26:34 +01:00
|
|
|
sha256 = "1ydzll8zlk897iqcihvv6p046p0rzr4qqz2drmz2nx95njp8n03a";
|
2018-09-08 16:30:30 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkgconfig
|
|
|
|
go
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
2018-12-02 11:41:15 +00:00
|
|
|
gobject-introspection
|
2018-09-08 16:30:30 +01:00
|
|
|
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 = [
|
2019-09-03 17:38:57 +01:00
|
|
|
"PREFIX=${placeholder "out"}"
|
2019-03-10 21:04:18 +00:00
|
|
|
"GOCACHE=$(TMPDIR)/go-cache"
|
2018-09-08 16:30:30 +01:00
|
|
|
];
|
|
|
|
|
2019-12-04 09:20:00 +00:00
|
|
|
passthru.updateScript = deepin.updateScript { name = "${pname}-${version}"; };
|
2018-10-30 22:17:45 +00:00
|
|
|
|
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 ];
|
|
|
|
};
|
|
|
|
}
|