summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavide Pesavento <pesa@gentoo.org>2021-03-02 07:07:36 +0100
committerDavide Pesavento <pesa@gentoo.org>2021-03-02 07:09:09 +0100
commitef6c1182595d7c4afc5cf96dc1ebfe71bc78647a (patch)
tree39b02adbc507772881a1e8088dd464ed0611d88a
parentdev-ruby/capistrano: add 3.16.0 (diff)
downloadgentoo-ef6c1182595d7c4afc5cf96dc1ebfe71bc78647a.tar.gz
gentoo-ef6c1182595d7c4afc5cf96dc1ebfe71bc78647a.tar.bz2
gentoo-ef6c1182595d7c4afc5cf96dc1ebfe71bc78647a.zip
dev-python/sip: add 4.19.25
Package-Manager: Portage-3.0.16, Repoman-3.0.2 Signed-off-by: Davide Pesavento <pesa@gentoo.org>
-rw-r--r--dev-python/sip/Manifest1
-rw-r--r--dev-python/sip/sip-4.19.25.ebuild94
2 files changed, 95 insertions, 0 deletions
diff --git a/dev-python/sip/Manifest b/dev-python/sip/Manifest
index 9cab9454da6a..b115206796da 100644
--- a/dev-python/sip/Manifest
+++ b/dev-python/sip/Manifest
@@ -1 +1,2 @@
DIST sip-4.19.24.tar.gz 1055461 BLAKE2B 6990b127a83fa57bc084eb9a1097f73c384b4fcf3d181479557fe2ffc66cde254bfbb5aef26f5ddd84dca346f54184952e7a111adf3b665f68571853e63b6575 SHA512 c9acf8c66da6ff24ffaeed254c11deabbc587cea0eb50164f2016199af30b85980f96a2d754ae5e7fe080f9076673b1abc82e2a6a41ff2ac442fb2b326fca1c0
+DIST sip-4.19.25.tar.gz 1056384 BLAKE2B f92e105e6b30e871aea2883dc9cd459e4032fb139a9eaff153a3412a66b39df4d7ac985711a2693aee83195ff3850ae648bee4102f7fc3cc30d09885799f2b98 SHA512 60fb4133c68869bf0993144978b4847d94a0f9c7b477f64a346ea133cfe35bc11820204ab327dcf9a929b6f65a26d16cc7efbce65e49967c3347b39376e57001
diff --git a/dev-python/sip/sip-4.19.25.ebuild b/dev-python/sip/sip-4.19.25.ebuild
new file mode 100644
index 000000000000..c4e7e7947b40
--- /dev/null
+++ b/dev-python/sip/sip-4.19.25.ebuild
@@ -0,0 +1,94 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{7..9} )
+inherit python-r1 toolchain-funcs
+
+DESCRIPTION="Python extension module generator for C and C++ libraries"
+HOMEPAGE="https://www.riverbankcomputing.com/software/sip/intro"
+
+MY_PN=sip
+MY_P=${MY_PN}-${PV/_pre/.dev}
+if [[ ${PV} == *_pre* ]]; then
+ SRC_URI="https://dev.gentoo.org/~pesa/distfiles/${MY_P}.tar.gz"
+else
+ SRC_URI="https://www.riverbankcomputing.com/static/Downloads/${MY_PN}/${PV}/${MY_P}.tar.gz"
+fi
+
+# Sub-slot based on SIP_API_MAJOR_NR from siplib/sip.h
+SLOT="0/12"
+LICENSE="|| ( GPL-2 GPL-3 SIP )"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="doc"
+
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+DEPEND="${PYTHON_DEPS}"
+RDEPEND="${DEPEND}"
+
+S=${WORKDIR}/${MY_P}
+
+PATCHES=( "${FILESDIR}"/${PN}-4.18-darwin.patch )
+
+src_prepare() {
+ # Sub-slot sanity check
+ local sub_slot=${SLOT#*/}
+ local sip_api_major_nr=$(sed -nre 's:^#define SIP_API_MAJOR_NR\s+([0-9]+):\1:p' siplib/sip.h || die)
+ if [[ ${sub_slot} != ${sip_api_major_nr} ]]; then
+ eerror
+ eerror "Ebuild sub-slot (${sub_slot}) does not match SIP_API_MAJOR_NR (${sip_api_major_nr})"
+ eerror "Please update SLOT variable as follows:"
+ eerror " SLOT=\"${SLOT%%/*}/${sip_api_major_nr}\""
+ eerror
+ die "sub-slot sanity check failed"
+ fi
+
+ default
+}
+
+src_configure() {
+ configuration() {
+ local incdir=$(python_get_includedir)
+ local myconf=(
+ "${PYTHON}"
+ "${S}"/configure.py
+ --sysroot="${ESYSROOT}/usr"
+ --bindir="${EPREFIX}/usr/bin"
+ --destdir="$(python_get_sitedir)"
+ --incdir="${incdir#${SYSROOT}}"
+ AR="$(tc-getAR) cqs"
+ CC="$(tc-getCC)"
+ CFLAGS="${CFLAGS}"
+ CFLAGS_RELEASE=
+ CXX="$(tc-getCXX)"
+ CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS_RELEASE=
+ LINK="$(tc-getCXX)"
+ LINK_SHLIB="$(tc-getCXX)"
+ LFLAGS="${LDFLAGS}"
+ LFLAGS_RELEASE=
+ RANLIB=
+ STRIP=
+ )
+ echo "${myconf[@]}"
+ "${myconf[@]}" || die
+ }
+ python_foreach_impl run_in_build_dir configuration
+}
+
+src_compile() {
+ python_foreach_impl run_in_build_dir default
+}
+
+src_install() {
+ installation() {
+ emake DESTDIR="${D}" install
+ python_optimize
+ }
+ python_foreach_impl run_in_build_dir installation
+
+ einstalldocs
+ use doc && dodoc -r doc/html
+}