2015-12-09 13:05:26 +03:00
|
|
|
{ stdenv, fetchurl, cmake, libxml2, libxslt, pysideApiextractor, pysideGeneratorrunner, python, sphinx, qt4, isPy3k, isPy35 }:
|
2011-12-18 00:16:45 +04:00
|
|
|
|
2015-12-09 13:05:26 +03:00
|
|
|
# Python 3.5 is not supported: https://github.com/PySide/Shiboken/issues/77
|
2016-06-15 20:30:12 +03:00
|
|
|
stdenv.mkDerivation rec {
|
2016-11-18 15:22:02 +03:00
|
|
|
name = "pyside-shiboken-${version}";
|
2015-12-10 23:40:00 +03:00
|
|
|
version = "1.2.4";
|
2011-12-18 00:16:45 +04:00
|
|
|
|
2014-08-01 15:50:09 +04:00
|
|
|
src = fetchurl {
|
2015-12-10 23:40:00 +03:00
|
|
|
url = "https://github.com/PySide/Shiboken/archive/${version}.tar.gz";
|
|
|
|
sha256 = "1536f73a3353296d97a25e24f9554edf3e6a48126886f8d21282c3645ecb96a4";
|
2011-12-18 00:16:45 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2015-12-09 13:05:26 +03:00
|
|
|
buildInputs = [ cmake libxml2 libxslt pysideApiextractor pysideGeneratorrunner python sphinx qt4 ];
|
2011-12-18 00:16:45 +04:00
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
echo "preConfigure: Fixing shiboken_generator install target."
|
|
|
|
substituteInPlace generator/CMakeLists.txt --replace \
|
|
|
|
\"$\{GENERATORRUNNER_PLUGIN_DIR}\" lib/generatorrunner/
|
|
|
|
'';
|
2016-06-15 20:30:12 +03:00
|
|
|
patches = if isPy35 then [ ./shiboken_py35.patch ] else null;
|
2011-12-18 00:16:45 +04:00
|
|
|
|
2015-12-09 13:05:26 +03:00
|
|
|
cmakeFlags = if isPy3k then "-DUSE_PYTHON3=TRUE" else null;
|
|
|
|
|
2011-12-18 00:16:45 +04:00
|
|
|
meta = {
|
|
|
|
description = "Plugin (front-end) for pyside-generatorrunner, that generates bindings for C++ libraries using CPython source code";
|
|
|
|
license = stdenv.lib.licenses.gpl2;
|
|
|
|
homepage = "http://www.pyside.org/docs/shiboken/";
|
|
|
|
maintainers = [ stdenv.lib.maintainers.chaoflow ];
|
|
|
|
platforms = stdenv.lib.platforms.all;
|
|
|
|
};
|
|
|
|
}
|