# Compiling Time: 1.33 SBU
# Maintainer: DeX77 <dex+fw@dragonslave.de>

pkgname=shiboken6
pkgver=6.9.1
_qtver=6.9.1
pkgrel=4
pkgdesc="Support library for Python bindings."
depends=("qt6-base>=$_qtver" 'clang-libs>=20.1.6' 'libxslt')
makedepends=('python3-sphinx' 'clang' 'clang-static' 'llvm' 'llvm-static' \
	'openmp' 'mlir' 'polly' 'qt6-tools' 'qt6-svg' 'qt6-3d' 'qt6-scxml' 'zstd-static' \
	'qt6-datavis3d' 'qt6-charts' 'qt6-multimedia' 'qt6-quick3d' 'qt6-positioning' 'qt6-graphs' \
	'qt6-networkauth' 'qt6-remoteobjects' 'qt6-sensors' 'qt6-serialport' 'qt6-connectivity' \
	'qt6-webchannel' 'qt6-webengine' 'qt6-websockets' 'qt6-shadertools' 'qt6-speech' 'qt6-httpserver')
url="https://wiki.qt.io/Qt_for_Python"
_F_cmake_confopts="     -DBUILD_TESTS=OFF \
			-DFORCE_LIMITED_API=no \
			-DNO_QT_TOOLS=yes"

_F_archive_name="PySide6"
up2date="Flastarchive https://download.qt.io/official_releases/QtForPython/pyside6 -cp39-abi3-win_amd64.whl"
Finclude cmake
groups=('devel-extra')
source=("https://download.qt.io/official_releases/QtForPython/pyside6/PySide6-$pkgver-src/pyside-setup-everywhere-src-${pkgver}.tar.xz")
sha1sums=('cf3f782ca6bd72cbddc802301abce2118b369509')
archs=('x86_64')
_F_cd_path="pyside-setup-everywhere-src-${_qtver}/sources/shiboken6"
options=('clang')

subpkgs=("python3-$pkgname")
subdescs=("Shiboken lib python only")
subdepends=('python3>=3.12')
subarchs=('x86_64')
subgroups=('lib')

build() {
	export CLANG_INSTALL_DIR="/usr"
        export CC=clang
        export CXX=clang++

	CMake_build -DSHIBOKEN_PYTHON_LIBRARIES=`pkgconf python3-embed --libs`
	Fsplit python3-$pkgname	usr/lib/python*
	Fsplit python3-$pkgname usr/lib/libshiboken*
}

# optimization OK
