archrelease: copy trunk to extra-x86_64
[arch-packages.git] / pyside6 / trunk / PKGBUILD
blob5320f84f34521936e913a929fd75c1d92da822be
1 # Maintainer: Antonio Rojas <arojas@archlinux.org>
2 # Maintainer: Felix Yan <felixonmars@archlinux.org>
4 pkgname=pyside6
5 _qtver=6.2.2
6 pkgver=${_qtver/-/}
7 pkgrel=2
8 arch=(x86_64)
9 url='https://www.qt.io'
10 license=(LGPL)
11 pkgdesc='Enables the use of Qt6 APIs in Python applications'
12 depends=(shiboken6 qt6-declarative)
13 makedepends=(cmake ninja python-setuptools vulkan-headers python-numpy
14              qt6-tools qt6-svg qt6-3d qt6-scxml qt6-datavis3d qt6-charts qt6-multimedia qt6-quick3d
15              qt6-positioning qt6-networkauth qt6-remoteobjects qt6-sensors qt6-serialport qt6-connectivity
16              qt6-webchannel qt6-webengine qt6-websockets qt6-shadertools)
17 optdepends=('qt6-tools: QtHelp, QtUiTools bindings'
18             'qt6-svg: QtSvg bindings'
19             'qt6-3d: Qt3D bindings'
20             'qt6-quick3d: QtQuick3D bindings'
21             'qt6-scxml: QtScxml bindings'
22             'qt6-datavis3d: QtDataVisualization bindings'
23             'qt6-charts: QtCharts bindings' 
24             'qt6-multimedia: QtMultimedia bindings' 
25             'qt6-serialport: QtSerialPort bindings' 
26             'qt6-webengine: QtWebEngine bindings' 
27             'qt6-remoteobjects: QtRemoteObjects bindings' 
28             'qt6-sensors: QtSensors bindings' 
29             'qt6-websockets: QtWebSockets bindings' 
30             'qt6-networkauth: QtNetworkAuth bindings')
31 _pkgfn=pyside-setup-opensource-src-$_qtver
32 source=(https://download.qt.io/official_releases/QtForPython/pyside6/PySide6-$pkgver-src/${_pkgfn}.tar.xz
33         designer-plugin-install-dir.patch)
34 sha256sums=('70a74c7c7c9e5af46cae5b1943bc39a1399c4332b342d2c48103a1cfe99891a8'
35             '66e895e07d5b01c64a94092353854c946fd7fc445b6181068dca290b5a3887e0')
37 prepare() {
38   patch -d $_pkgfn -p1 < designer-plugin-install-dir.patch # Fix designer plugin install dir
41 build() {
42   cmake -B build -S $_pkgfn/sources/pyside6 -G Ninja \
43     -DCMAKE_INSTALL_PREFIX=/usr \
44     -DBUILD_TESTS=OFF \
45     -DPYTHON_EXECUTABLE=/usr/bin/python
46   cmake --build build
49 package() {
50   DESTDIR="$pkgdir" cmake --install build
52 # Install egg-info
53   export PATH="/usr/lib/qt6/bin:$PATH"
54   cd $_pkgfn
55   python setup.py egg_info --build-type=pyside6
56   _pythonpath=`python -c "from sysconfig import get_path; print(get_path('platlib'))"`
57   cp -r PySide6.egg-info "$pkgdir"/$_pythonpath