Convert to Python 3

This commit is contained in:
Sebastiaan Lokhorst 2019-04-03 19:14:00 +02:00
parent e4801f3409
commit 629cd29bbc
2 changed files with 50 additions and 36 deletions

View file

@ -1,36 +1,38 @@
pkgbase = freecad-git pkgbase = freecad-git
pkgdesc = A general purpose 3D CAD modeler - git checkout pkgdesc = A general purpose 3D CAD modeler - git checkout
pkgver = 0.18.r26.g51fcdd2c0 pkgver = 0.19pre.r84.gb66a6fa31
pkgrel = 2 pkgrel = 1
epoch = 1 epoch = 1
url = https://www.freecadweb.org/ url = https://www.freecadweb.org/
arch = x86_64 arch = x86_64
license = LGPL license = LGPL
makedepends = git
makedepends = boost makedepends = boost
makedepends = cmake makedepends = cmake
makedepends = desktop-file-utils
makedepends = pyside2-tools
makedepends = desktop-file-utils
makedepends = eigen makedepends = eigen
makedepends = git
makedepends = gcc-fortran makedepends = gcc-fortran
makedepends = pyside2-tools
makedepends = swig makedepends = swig
makedepends = qt5-tools
depends = boost-libs depends = boost-libs
depends = curl depends = curl
depends = desktop-file-utils
depends = glew
depends = hicolor-icon-theme depends = hicolor-icon-theme
depends = libspnav
depends = opencascade
depends = libtheora
depends = med
depends = jsoncpp depends = jsoncpp
depends = libspnav
depends = med
depends = opencascade
depends = shiboken2
depends = xerces-c depends = xerces-c
depends = python2-netcdf4 depends = pyside2
depends = python2-pivy depends = python-matplotlib
depends = python2-pyside2 depends = python-netcdf4
depends = python-pivy
depends = qt5-svg depends = qt5-svg
depends = qt5-webkit depends = qt5-webkit
optdepends = python2-matplotlib depends = qt5-webengine
optdepends = pycollada-git: Create, edit and load COLLADA documents. optdepends = pycollada: Create, edit and load COLLADA documents.
provides = freecad provides = freecad
conflicts = freecad conflicts = freecad
source = freecad-git::git+https://github.com/FreeCAD/FreeCAD.git source = freecad-git::git+https://github.com/FreeCAD/FreeCAD.git

View file

@ -1,22 +1,22 @@
# Maintainer: Grey Christoforo <first name at last name dot net> # Maintainer: Grey Christoforo <first name at last name dot net>
# Maintainer: Sebastiaan Lokhorst <sebastiaanlokhorst@gmail.com>
_appname=freecad _appname=freecad
pkgname="${_appname}-git" pkgname="${_appname}-git"
pkgver=0.18.r26.g51fcdd2c0 pkgver=0.19pre.r84.gb66a6fa31
pkgrel=2 pkgrel=1
epoch=1 epoch=1
pkgdesc='A general purpose 3D CAD modeler - git checkout' pkgdesc='A general purpose 3D CAD modeler - git checkout'
arch=('x86_64') arch=('x86_64')
url='https://www.freecadweb.org/' url='https://www.freecadweb.org/'
license=('LGPL') license=('LGPL')
depends=('boost-libs' 'curl' 'hicolor-icon-theme' 'libspnav' 'opencascade' depends=('boost-libs' 'curl' 'desktop-file-utils' 'glew' 'hicolor-icon-theme'
'libtheora' 'med' 'jsoncpp' 'xerces-c' 'jsoncpp' 'libspnav' 'med' 'opencascade' 'shiboken2' 'xerces-c'
'python2-netcdf4' 'python2-pivy' 'python2-pyside2' 'pyside2' 'python-matplotlib' 'python-netcdf4' 'python-pivy'
'qt5-svg' 'qt5-webkit') 'qt5-svg' 'qt5-webkit' 'qt5-webengine')
makedepends=('git' 'boost' 'cmake' 'desktop-file-utils' 'pyside2-tools' makedepends=('boost' 'cmake' 'eigen' 'git' 'gcc-fortran'
'desktop-file-utils' 'eigen' 'gcc-fortran' 'swig') 'pyside2-tools' 'swig' 'qt5-tools')
optdepends=('python2-matplotlib' optdepends=('pycollada: Create, edit and load COLLADA documents.')
'pycollada-git: Create, edit and load COLLADA documents.')
provides=('freecad') provides=('freecad')
conflicts=('freecad') conflicts=('freecad')
source=("${pkgname}::git+https://github.com/FreeCAD/FreeCAD.git" source=("${pkgname}::git+https://github.com/FreeCAD/FreeCAD.git"
@ -36,10 +36,23 @@ build() {
cmake . \ cmake . \
-DCMAKE_BUILD_TYPE=Release \ -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX="/opt/${_appname}" \ -DCMAKE_INSTALL_PREFIX="/usr/lib/freecad" \
-DCMAKE_INSTALL_DOCDIR="/usr/share/freecad/doc" \
-DCMAKE_INSTALL_DATADIR="/usr/share/freecad" \
-DFREECAD_USE_OCC_VARIANT="Official Version" \ -DFREECAD_USE_OCC_VARIANT="Official Version" \
-DPYTHON_EXECUTABLE=/usr/bin/python2 \ -DBUILD_QT5=ON \
-DBUILD_QT5=ON -DPYTHON_EXECUTABLE=/usr/bin/python3 \
-DPYTHON_LIBRARY=/usr/lib/libpython3.7m.so \
-DPYTHON_INCLUDE_DIR=/usr/include/python3.7m \
-DPYTHON_PACKAGES_PATH=/usr/lib/python3.7/site-packages \
-DOPENMPI_INCLUDE_DIRS=/usr/include \
-DSHIBOKEN_INCLUDE_DIR=/usr/include/shiboken2 \
-DSHIBOKEN_BINARY=/usr/bin/shiboken2 \
-DSHIBOKEN_LIBRARY=/usr/lib/libshiboken2.cpython-37m-x86_64-linux-gnu.so \
-DPYSIDE_INCLUDE_DIR=/usr/include/PySide2 \
-DPYSIDE_LIBRARY=/usr/lib/libpyside2.cpython-37m-x86_64-linux-gnu.so \
-DPYSIDE_PYTHONPATH=/usr/lib/python3.7/site-packages/PySide2 \
-DPYSIDE_TYPESYSTEMS=/usr/share/PySide2/typesystems
make make
} }
@ -53,10 +66,9 @@ package() {
# Symlink binaries to /usr/bin. # Symlink binaries to /usr/bin.
mkdir -p "${pkgdir}/usr/bin" mkdir -p "${pkgdir}/usr/bin"
ln -s "/opt/${_appname}/bin/${bin}" "${pkgdir}/usr/bin/${bin}" ln -s "/usr/lib/freecad/bin/${bin}" "${pkgdir}/usr/bin/${bin}"
ln -s "/opt/${_appname}/bin/${bin_cmd}" "${pkgdir}/usr/bin/${bin_cmd}" ln -s "/usr/lib/freecad/bin/${bin_cmd}" "${pkgdir}/usr/bin/${bin_cmd}"
# Lowercase aliases for convenience.
# Lowercase aliases like the official arch package.
ln -s "/usr/bin/${bin}" "${pkgdir}/usr/bin/${bin,,}" ln -s "/usr/bin/${bin}" "${pkgdir}/usr/bin/${bin,,}"
ln -s "/usr/bin/${bin_cmd}" "${pkgdir}/usr/bin/${bin_cmd,,}" ln -s "/usr/bin/${bin_cmd}" "${pkgdir}/usr/bin/${bin_cmd,,}"