libopenshot: switch to python 3.8

This commit is contained in:
Jerome Duval
2021-01-26 18:15:38 +01:00
parent 1a2fe2124f
commit 3691d741fe

View File

@@ -6,7 +6,7 @@ OpenShot Video Editor (version 2.0+). C++, Python are fully supported."
HOMEPAGE="https://www.openshot.org/" HOMEPAGE="https://www.openshot.org/"
COPYRIGHT="2008-2020 OpenShot Studios, LLC" COPYRIGHT="2008-2020 OpenShot Studios, LLC"
LICENSE="GNU LGPL v3" LICENSE="GNU LGPL v3"
REVISION="3" REVISION="4"
SOURCE_URI="https://github.com/OpenShot/libopenshot/archive/v$portVersion.tar.gz" SOURCE_URI="https://github.com/OpenShot/libopenshot/archive/v$portVersion.tar.gz"
CHECKSUM_SHA256="8ae7d226fbd2efbc84da4f7d9d8c7f3cc9616e4de46e1233e3b0a84ac0a429bc" CHECKSUM_SHA256="8ae7d226fbd2efbc84da4f7d9d8c7f3cc9616e4de46e1233e3b0a84ac0a429bc"
SOURCE_FILENAME="libopenshot-$portVersion.tar.gz" SOURCE_FILENAME="libopenshot-$portVersion.tar.gz"
@@ -15,7 +15,7 @@ PATCHES="libopenshot-$portVersion.patchset"
ARCHITECTURES="!x86_gcc2 x86 x86_64" ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86" SECONDARY_ARCHITECTURES="x86"
PYTHON_VERSION="3.7" PYTHON_VERSION="3.8"
libVersion="17" libVersion="17"
PROVIDES=" PROVIDES="
@@ -48,34 +48,30 @@ REQUIRES_devel="
libopenshot$secondaryArchSuffix == $portVersion base libopenshot$secondaryArchSuffix == $portVersion base
" "
SUMMARY_python3="$SUMMARY (python3 bindings)" SUMMARY_python38="$SUMMARY (python3 bindings)"
PROVIDES_python3=" PROVIDES_python38="
libopenshot${secondaryArchSuffix}_python3 = $portVersion libopenshot${secondaryArchSuffix}_python38 = $portVersion
" "
REQUIRES_python3=" REQUIRES_python38="
libopenshot$secondaryArchSuffix == $portVersion base libopenshot$secondaryArchSuffix == $portVersion base
lib:libavutil$secondaryArchSuffix lib:libavutil$secondaryArchSuffix
lib:libopenshot_audio$secondaryArchSuffix lib:libopenshot_audio$secondaryArchSuffix
lib:libpython${PYTHON_VERSION}m$secondaryArchSuffix lib:libpython${PYTHON_VERSION}$secondaryArchSuffix
" "
if [ "$targetArchitecture" = "x86_gcc2" ]; then if [ "$targetArchitecture" = "x86_gcc2" ]; then
PROVIDES_python3+=" PROVIDES_python38+="
libopenshot_python3 = $portVersion libopenshot_python38 = $portVersion
" "
fi fi
REPLACES_python3=" SUMMARY_python38_debuginfo="$SUMMARY (python3 bindings debug info)"
libopenshot${secondaryArchSuffix}_python36 PROVIDES_python38_debuginfo="
" libopenshot${secondaryArchSuffix}_python38_debuginfo = $portVersion
debuginfo:_openshot.so(libopenshot_python38) = $portVersion
SUMMARY_python3_debuginfo="$SUMMARY (python3 bindings debug info)"
PROVIDES_python3_debuginfo="
libopenshot${secondaryArchSuffix}_python3_debuginfo = $portVersion
debuginfo:_openshot.so(libopenshot_python3) = $portVersion
" "
REQUIRES_python3_debuginfo=" REQUIRES_python38_debuginfo="
libopenshot${secondaryArchSuffix}_python3 == $portVersion base libopenshot${secondaryArchSuffix}_python38 == $portVersion base
" "
BUILD_REQUIRES=" BUILD_REQUIRES="
@@ -138,16 +134,16 @@ INSTALL()
packageEntries devel \ packageEntries devel \
$developDir $developDir
python=$portPackageLinksDir/cmd~python${PYTHON_VERSION}/bin/python${PYTHON_VERSION}m python=$portPackageLinksDir/cmd~python${PYTHON_VERSION}/bin/python${PYTHON_VERSION}
pythonVersion=$($python --version 2>&1 | sed 's/Python //' | head -c3) pythonVersion=$($python --version 2>&1 | sed 's/Python //' | head -c3)
pythonLocation=$prefix/lib/python$pythonVersion pythonLocation=$prefix/lib/python$pythonVersion
installLocation=$pythonLocation/vendor-packages installLocation=$pythonLocation/vendor-packages
pythonDebugInfoDir=$(getPackagePrefix python3_debuginfo)/$relativeDebugInfoDir pythonDebugInfoDir=$(getPackagePrefix python38_debuginfo)/$relativeDebugInfoDir
mv $pythonLocation/dist-packages $pythonLocation/vendor-packages mv $pythonLocation/dist-packages $pythonLocation/vendor-packages
extractDebugInfo $installLocation/_openshot.so \ extractDebugInfo $installLocation/_openshot.so \
"$pythonDebugInfoDir/_openshot.so(libopenshot_python3-$portFullVersion).debuginfo" "$pythonDebugInfoDir/_openshot.so(libopenshot_python38-$portFullVersion).debuginfo"
# python package # python package
packageEntries python3 \ packageEntries python38 \
$pythonLocation $pythonLocation
} }