Added pygame & pyserial wity Python 2.7 support.
This commit is contained in:
parent
e8532e414a
commit
889f3ba42e
3
dev-python/pygame/Manifest
Normal file
3
dev-python/pygame/Manifest
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
DIST pygame-1.9.6.tar.gz 3223131 BLAKE2B a4d04c933fcad244d32bd512ef8717e60ec923f361e9e0296b5c7d57c5949d3434a040d028249c5b8f3c865ac3dcdbb32e6f0b223186678595a8625213ba2a17 SHA512 d923c554203a7c35e37921658cb4c5bf50215ab0ff4d2b869a1ee6b2e2ca31d66ec4bbde4287f5a777838ffe932cd15b993cb0224b86e43d684de61c35acbcd0
|
||||||
|
EBUILD pygame-1.9.6-r1.ebuild 2304 BLAKE2B 5d2b586d2de4e306e614d8020a905750fbcc9fdb433c2a647f0863af134d068a5e3fcf79b8e84dc8dd165557fd92466a5274f9fd845cd05bfc32b8c98df06664 SHA512 8972d79e6df16fc60c38654ae11aeb345e433c9c81a1fe30505695997e0c75c440078902005c4c79689d774fd17e5748a7951e92400961be7def475cbe27f81d
|
||||||
|
MISC metadata.xml 408 BLAKE2B ae371ef164069765d0964da714a83c9898ddc190ac295c5ad5bbb6a3c45db5aa415d84ff21dbaa510e5c9852397e6b6b389684c54b67d83d675afd9b3d9a697e SHA512 a6e06c0bed59d5157166577a2dafa53f28a310c56f251bec36af077a79342c6f954fa63a3fa8d3546ca03cc9358e75eeb1ef04c6e0371e43e0b7bff51ffe35dd
|
14
dev-python/pygame/metadata.xml
Normal file
14
dev-python/pygame/metadata.xml
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
<?xml version='1.0' encoding='UTF-8'?>
|
||||||
|
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||||
|
<pkgmetadata>
|
||||||
|
<maintainer type="project">
|
||||||
|
<email>python@gentoo.org</email>
|
||||||
|
<name>Python</name>
|
||||||
|
</maintainer>
|
||||||
|
<use>
|
||||||
|
<flag name="midi">Enable midi support using <pkg>media-libs/portmidi</pkg></flag>
|
||||||
|
</use>
|
||||||
|
<upstream>
|
||||||
|
<remote-id type="pypi">pygame</remote-id>
|
||||||
|
</upstream>
|
||||||
|
</pkgmetadata>
|
102
dev-python/pygame/pygame-1.9.6-r1.ebuild
Normal file
102
dev-python/pygame/pygame-1.9.6-r1.ebuild
Normal file
|
@ -0,0 +1,102 @@
|
||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
PYTHON_COMPAT=( python2_7 python3_{6,7,8} )
|
||||||
|
|
||||||
|
inherit flag-o-matic distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="Python bindings for SDL multimedia library"
|
||||||
|
HOMEPAGE="https://www.pygame.org/"
|
||||||
|
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="LGPL-2.1"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ~ppc64 sparc x86"
|
||||||
|
IUSE="doc examples midi opengl test X"
|
||||||
|
RESTRICT="!test? ( test )"
|
||||||
|
|
||||||
|
RDEPEND="dev-python/numpy[${PYTHON_USEDEP}]
|
||||||
|
>=media-libs/sdl-image-1.2.2[png,jpeg]
|
||||||
|
>=media-libs/sdl-mixer-1.2.4
|
||||||
|
>=media-libs/sdl-ttf-2.0.6
|
||||||
|
>=media-libs/smpeg-0.4.4-r1
|
||||||
|
midi? ( media-libs/portmidi )
|
||||||
|
X? ( >=media-libs/libsdl-1.2.5[opengl?,video,X] )
|
||||||
|
!X? ( >=media-libs/libsdl-1.2.5 )"
|
||||||
|
DEPEND="${RDEPEND}
|
||||||
|
test? (
|
||||||
|
media-libs/sdl-image[gif,png,jpeg]
|
||||||
|
media-libs/sdl-mixer[mp3,vorbis,wav]
|
||||||
|
)"
|
||||||
|
# fontconfig used for fc-list
|
||||||
|
RDEPEND+="
|
||||||
|
media-libs/fontconfig"
|
||||||
|
# util-linux provides script
|
||||||
|
BDEPEND="
|
||||||
|
test? (
|
||||||
|
media-libs/fontconfig
|
||||||
|
sys-apps/util-linux
|
||||||
|
)"
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
# segfaults on Xvfb
|
||||||
|
rm test/scrap_test.py || die
|
||||||
|
# backport from git master (clock() isn't used)
|
||||||
|
sed -i -e '/from time import clock/d' test/math_test.py || die
|
||||||
|
|
||||||
|
distutils-r1_src_prepare
|
||||||
|
}
|
||||||
|
|
||||||
|
python_configure() {
|
||||||
|
PORTMIDI_INC_PORTTIME=1 LOCALBASE="${EPREFIX}/usr" \
|
||||||
|
"${EPYTHON}" "${S}"/buildconfig/config.py -auto
|
||||||
|
|
||||||
|
if ! use X; then
|
||||||
|
sed -e "s:^scrap :#&:" -i Setup || die "sed failed"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Disable automagic dependency on PortMidi.
|
||||||
|
if ! use midi; then
|
||||||
|
sed -e "s:^pypm :#&:" -i Setup || die "sed failed"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
python_compile() {
|
||||||
|
if [[ ${EPYTHON} == python2* ]]; then
|
||||||
|
local CFLAGS=${CFLAGS} CXXFLAGS=${CXXFLAGS}
|
||||||
|
|
||||||
|
append-flags -fno-strict-aliasing
|
||||||
|
fi
|
||||||
|
|
||||||
|
distutils-r1_python_compile
|
||||||
|
}
|
||||||
|
|
||||||
|
python_test() {
|
||||||
|
local -x PYTHONPATH=
|
||||||
|
local -x SDL_VIDEODRIVER=dummy
|
||||||
|
local -x SDL_AUDIODRIVER=disk
|
||||||
|
distutils_install_for_testing
|
||||||
|
script -eqc "${EPYTHON} -m pygame.tests" || die
|
||||||
|
}
|
||||||
|
|
||||||
|
python_install() {
|
||||||
|
distutils-r1_python_install
|
||||||
|
|
||||||
|
# Bug #497720
|
||||||
|
rm -fr "${D}"$(python_get_sitedir)/pygame/{docs,examples,tests}/ || die
|
||||||
|
}
|
||||||
|
|
||||||
|
python_install_all() {
|
||||||
|
distutils-r1_python_install_all
|
||||||
|
|
||||||
|
if use doc; then
|
||||||
|
docinto html
|
||||||
|
dodoc -r docs/*
|
||||||
|
fi
|
||||||
|
|
||||||
|
if use examples; then
|
||||||
|
insinto /usr/share/doc/${PF}/examples
|
||||||
|
doins -r examples/*
|
||||||
|
fi
|
||||||
|
}
|
3
dev-python/pyserial/Manifest
Normal file
3
dev-python/pyserial/Manifest
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
DIST pyserial-3.4.tar.gz 151657 BLAKE2B cf47aba4a6f3bb2fe39d99e72907496faa1c9f37857810fef4d826cca72c361d0e43dbc33d9cf2291a589bf0193d17355d149e6eb61b4f9e28250207708ef09a SHA512 d71dffc330704e41caac6054adf192bee2f1c119691faf2ea93fe22e8e3ba000dc4a1434293f6f80d05a5577d85b96791f656e28d5c63fb0ce6a6605467a117f
|
||||||
|
EBUILD pyserial-3.4.ebuild 830 BLAKE2B ae1703116d7b0eb4841ac2f02395e5a249c37026b3bedd211cf317aa025d388473e43eb36619c158cd80fcd2d3808b60016a5d06e1ad32cdec8f9d2222e71b1d SHA512 178b0ba37a605e696d790886fc76aa6e3e86e8f883e471be706ae9b84c28982b2f32a27572738eaa95b5ea0cdca7e13e7b18d53462e8263aea18c6ac9d710625
|
||||||
|
MISC metadata.xml 421 BLAKE2B f3c94b0b72c3df17d9c539e8b76e1f644e0b4ae1bb3d905652b568084e449bf11cab07f27e7775031eee857095671debd28bf1d2eb8c1992c6b980620b32109b SHA512 30c1232aed930c665c2603443cbff9efbb843b1866d6a4d034a517e0669f28f1e6e7562103a8badbd8fb1efd9e69b058870b9c4fcea8fa5e74e7a1ec8ba17fde
|
13
dev-python/pyserial/metadata.xml
Normal file
13
dev-python/pyserial/metadata.xml
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
<?xml version='1.0' encoding='UTF-8'?>
|
||||||
|
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||||
|
<pkgmetadata>
|
||||||
|
<maintainer type="project">
|
||||||
|
<email>python@gentoo.org</email>
|
||||||
|
<name>Python</name>
|
||||||
|
</maintainer>
|
||||||
|
<upstream>
|
||||||
|
<remote-id type="pypi">pyserial</remote-id>
|
||||||
|
<remote-id type="sourceforge">pyserial</remote-id>
|
||||||
|
<remote-id type="github">pyserial/pyserial</remote-id>
|
||||||
|
</upstream>
|
||||||
|
</pkgmetadata>
|
32
dev-python/pyserial/pyserial-3.4.ebuild
Normal file
32
dev-python/pyserial/pyserial-3.4.ebuild
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
# Copyright 1999-2020 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=7
|
||||||
|
PYTHON_COMPAT=( python2_7 python3_{6..9} )
|
||||||
|
|
||||||
|
inherit distutils-r1
|
||||||
|
|
||||||
|
DESCRIPTION="Python Serial Port extension"
|
||||||
|
HOMEPAGE="https://github.com/pyserial/pyserial https://pypi.org/project/pyserial/"
|
||||||
|
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="PSF-2"
|
||||||
|
SLOT="0"
|
||||||
|
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv s390 sparc x86"
|
||||||
|
IUSE="examples"
|
||||||
|
|
||||||
|
DOCS=( CHANGES.rst README.rst )
|
||||||
|
|
||||||
|
distutils_enable_sphinx documentation --no-autodoc
|
||||||
|
|
||||||
|
python_test() {
|
||||||
|
"${EPYTHON}" test/run_all_tests.py loop:// -v || die "Testing failed with ${EPYTHON}"
|
||||||
|
}
|
||||||
|
|
||||||
|
python_install_all() {
|
||||||
|
distutils-r1_python_install_all
|
||||||
|
if use examples; then
|
||||||
|
dodoc -r examples
|
||||||
|
docompress -x /usr/share/doc/${PF}/examples
|
||||||
|
fi
|
||||||
|
}
|
Loading…
Reference in a new issue