ipython: Fix executables by removing setuptools commands
* Disable striping exectuables due to appended archive file. * Remove sed commands replacing shebang. With python-build, the /bin now contains PE file instead of python script.
This commit is contained in:
@@ -7,7 +7,7 @@ provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
||||
conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
||||
replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
||||
pkgver=8.8.0
|
||||
pkgrel=1
|
||||
pkgrel=2
|
||||
pkgdesc="An enhanced Interactive Python shell (mingw-w64)"
|
||||
arch=('any')
|
||||
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
|
||||
@@ -36,6 +36,7 @@ checkdepends=("${MINGW_PACKAGE_PREFIX}-python-requests"
|
||||
"${MINGW_PACKAGE_PREFIX}-python-jupyter-nbformat"
|
||||
"${MINGW_PACKAGE_PREFIX}-python-ipykernel"
|
||||
"${MINGW_PACKAGE_PREFIX}-python-numpy")
|
||||
options=('!strip')
|
||||
source=("https://pypi.org/packages/source/${_realname::1}/${_realname}/${_realname}-${pkgver}.tar.gz")
|
||||
sha256sums=('f3bf2c08505ad2c3f4ed5c46ae0331a8547d36bf4b21a451e8ae80c0791db95b')
|
||||
|
||||
@@ -62,20 +63,5 @@ package() {
|
||||
${MINGW_PREFIX}/bin/python -m installer --prefix=${MINGW_PREFIX} \
|
||||
--destdir="${pkgdir}" dist/*.whl
|
||||
|
||||
find "${pkgdir}/" -type d -empty -delete
|
||||
|
||||
# setuptools doesnt see mingw-w64-python's readline
|
||||
find "${pkgdir}/" -name 'requires.txt' -delete
|
||||
|
||||
# For the command to work on the bash prompt, you must use
|
||||
# winpty so include that in the Shebang before the python command.
|
||||
# I don't like this but what I like really doesn't matter.
|
||||
local PREFIX_WIN=$(cygpath -wm ${MINGW_PREFIX})
|
||||
for _f in ipython ipython3; do
|
||||
sed -e "s|/usr/bin/env |${MINGW_PREFIX}/|g" \
|
||||
-e "s|${PREFIX_WIN}|${MINGW_PREFIX}|g" \
|
||||
-e "s|#!|#!winpty |" -i "${pkgdir}${MINGW_PREFIX}/bin/${_f}"
|
||||
done
|
||||
|
||||
install -Dm644 docs/source/about/license_and_copyright.rst "${pkgdir}${MINGW_PREFIX}/share/licenses/python-ipython/LICENSE"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user