2016-04-17 00:49:29 +01:00
|
|
|
{ stdenv, fetchurl, qt4 }:
|
2009-09-11 13:05:23 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "qtscriptgenerator-0.1.0";
|
|
|
|
src = fetchurl {
|
2017-10-27 00:44:19 +01:00
|
|
|
url = "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/qtscriptgenerator/qtscriptgenerator-src-0.1.0.tar.gz";
|
2009-09-11 13:05:23 +01:00
|
|
|
sha256 = "0h8zjh38n2wfz7jld0jz6a09y66dbsd2jhm4f2024qfgcmxcabj6";
|
|
|
|
};
|
|
|
|
buildInputs = [ qt4 ];
|
2010-01-17 21:34:55 +00:00
|
|
|
|
2012-02-20 05:27:57 +00:00
|
|
|
patches = [ ./qtscriptgenerator.gcc-4.4.patch ./qt-4.8.patch ];
|
2016-02-11 01:36:07 +00:00
|
|
|
|
2017-11-03 18:50:20 +00:00
|
|
|
postPatch = ''
|
2009-09-11 13:05:23 +01:00
|
|
|
# remove phonon stuff which causes errors (thanks to Gentoo bug reports)
|
|
|
|
sed -i "/typesystem_phonon.xml/d" generator/generator.qrc
|
2016-02-11 01:36:07 +00:00
|
|
|
sed -i "/qtscript_phonon/d" qtbindings/qtbindings.pro
|
2017-11-03 18:50:20 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
configurePhase = ''
|
|
|
|
( cd generator; qmake )
|
|
|
|
( cd qtbindings; qmake )
|
|
|
|
'';
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
makeFlags="SHELL=$SHELL ''${enableParallelBuilding:+-j$NIX_BUILD_CORES -l$NIX_BUILD_CORES}"
|
|
|
|
make $makeFlags -C generator
|
2016-02-11 01:36:07 +00:00
|
|
|
|
2017-10-27 00:44:19 +01:00
|
|
|
# Set QTDIR, see https://code.google.com/archive/p/qtscriptgenerator/issues/38
|
2017-11-03 18:50:20 +00:00
|
|
|
( cd generator; QTDIR=${qt4} ./generator )
|
|
|
|
make $makeFlags -C qtbindings
|
2009-09-11 13:05:23 +01:00
|
|
|
'';
|
2016-02-11 01:36:07 +00:00
|
|
|
|
2009-09-11 13:05:23 +01:00
|
|
|
installPhase = ''
|
2012-01-18 20:16:00 +00:00
|
|
|
mkdir -p $out/lib/qt4/plugins/script
|
2009-09-11 13:05:23 +01:00
|
|
|
cp -av plugins/script/* $out/lib/qt4/plugins/script
|
|
|
|
'';
|
2012-01-05 23:16:12 +00:00
|
|
|
|
2017-11-03 18:50:20 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2016-02-26 17:38:15 +00:00
|
|
|
hardeningDisable = [ "format" ];
|
2016-02-11 01:36:07 +00:00
|
|
|
|
2012-01-05 23:16:12 +00:00
|
|
|
meta = {
|
|
|
|
description = "QtScript bindings generator";
|
2017-10-27 00:44:19 +01:00
|
|
|
homepage = https://code.qt.io/cgit/qt-labs/qtscriptgenerator.git/;
|
2012-01-05 23:16:12 +00:00
|
|
|
inherit (qt4.meta) platforms;
|
2017-03-27 18:11:17 +01:00
|
|
|
maintainers = [ ];
|
2012-01-05 23:16:12 +00:00
|
|
|
};
|
2009-09-11 13:05:23 +01:00
|
|
|
}
|