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