# This file is an EasyBuild reciPY as per https://github.com/hpcugent/easybuild
# Author: Bart Verleye
# Center for eResearch, Auckland
easyblock = 'ConfigureMakePythonPackage'

name = 'PyQt'
version = '4.11.4'

homepage = 'http://www.riverbanklocal_computing.co.uk/software/pyqt'
description = """PyQt is a set of Python v2 and v3 bindings for Digia's Qt application framework."""

toolchain = {'name': 'foss', 'version': '2015g'}

sources = ['%(name)s-x11-gpl-%(version)s.tar.gz']
source_urls = [
    'http://sourceforge.net/projects/pyqt/files/PyQt4/PyQt-%(version)s']

local_python = 'Python'
local_pyver = '2.7.9'
local_pythonshortver = '.'.join(local_pyver.split('.')[:2])
versionsuffix = '-%s-%s' % (local_python, local_pyver)

dependencies = [
    (local_python, local_pyver),
    ('SIP', '4.17', versionsuffix),
    ('Qt', '4.8.6'),
]

configopts = "configure-ng.py --confirm-license"
configopts += " --destdir=%%(installdir)s/lib/local_python%s/site-packages " % local_pythonshortver
configopts += " --qsci-api"

options = {'modulename': 'PyQt4'}

modextrapaths = {'PYTHONPATH': 'lib/local_python%s/site-packages' % local_pythonshortver}

sanity_check_paths = {
    'files': ['lib/python2.7/site-packages/PyQt4/Qt.so'],
    'dirs': [],
}

moduleclass = 'vis'
