diff options
author | Matteo Bernardini <ponce@slackbuilds.org> | 2021-07-26 10:19:55 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2021-07-28 18:02:33 -0500 |
commit | 35a1af63e825175d29e4aa08c507b25d3335d5be (patch) | |
tree | 68a45eb96f3500a594493c05d8f3539fb6c33060 /python/python-magic/python-magic.SlackBuild | |
parent | 254c61e8499a67fe02a75bd996e5668ca12424f4 (diff) |
python/python-magic: Autodetect python3.
It should be already available...
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'python/python-magic/python-magic.SlackBuild')
-rw-r--r-- | python/python-magic/python-magic.SlackBuild | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/python/python-magic/python-magic.SlackBuild b/python/python-magic/python-magic.SlackBuild index 991344a525f0b..3a2cfabc0d5ad 100644 --- a/python/python-magic/python-magic.SlackBuild +++ b/python/python-magic/python-magic.SlackBuild @@ -67,10 +67,9 @@ find -L . \ python2 setup.py install --root=$PKG -# Install for python3. Default is no. -if [ "${PYTHON3:-no}" == "yes" ]; then - rm -rf build - python3 setup.py install --root=$PKG +# Add Python3 support +if $(python3 -c 'import sys' 2>/dev/null); then + python3 setup.py install --root=$PKG fi find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ |