summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTupone Alfredo <tupone@gentoo.org>2017-06-27 22:11:18 +0200
committerTupone Alfredo <tupone@gentoo.org>2017-06-27 22:11:18 +0200
commit51f0ec98d03d7ec65ee4366ebb4d4c5073be42c6 (patch)
treeec20cb0477eda5a473a06979227f0b84f4b5ab8d /dev-ada
parentmedia-libs/libvisio: Fix tests, drop unused DEPEND (diff)
downloadgentoo-51f0ec98d03d7ec65ee4366ebb4d4c5073be42c6.tar.gz
gentoo-51f0ec98d03d7ec65ee4366ebb4d4c5073be42c6.tar.bz2
gentoo-51f0ec98d03d7ec65ee4366ebb4d4c5073be42c6.zip
dev-ada/gnatcoll: Add use flags gnat_2016 & gnat_2017
Package-Manager: Portage-2.3.6, Repoman-2.3.1
Diffstat (limited to 'dev-ada')
-rw-r--r--dev-ada/gnatcoll/gnatcoll-2016.ebuild40
-rw-r--r--dev-ada/gnatcoll/gnatcoll-2017.ebuild20
-rw-r--r--dev-ada/gnatcoll/metadata.xml2
3 files changed, 27 insertions, 35 deletions
diff --git a/dev-ada/gnatcoll/gnatcoll-2016.ebuild b/dev-ada/gnatcoll/gnatcoll-2016.ebuild
index 0f4d7a0062b..77e71b22795 100644
--- a/dev-ada/gnatcoll/gnatcoll-2016.ebuild
+++ b/dev-ada/gnatcoll/gnatcoll-2016.ebuild
@@ -15,10 +15,11 @@ SRC_URI="http://mirrors.cdn.adacore.com/art/5739942ac7a447658d00e1e7
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64"
-IUSE="gmp gtk iconv postgresql pygobject projects readline +shared sqlite
- static syslog"
+IUSE="gmp gnat_2016 gnat_2017 gtk iconv postgresql pygobject projects readline
+ +shared sqlite static syslog"
-RDEPEND="dev-lang/gnat-gpl:*
+RDEPEND="gnat_2016? ( dev-lang/gnat-gpl:4.9.4 )
+ gnat_2017? ( dev-lang/gnat-gpl:6.3.0 )
${PYTHON_DEPS}
gmp? ( dev-libs/gmp:* )
gtk? (
@@ -37,28 +38,16 @@ RDEPEND="dev-lang/gnat-gpl:*
=dev-ada/gprbuild-2016[static?,shared?]
)"
DEPEND="${RDEPEND}
- dev-ada/gprbuild"
+ dev-ada/gprbuild[gnat_2016=,gnat_2017=]"
REQUIRED_USE="${PYTHON_REQUIRED_USE}
- pygobject? ( gtk )"
+ pygobject? ( gtk )
+ ^^ ( gnat_2016 gnat_2017 )"
S="${WORKDIR}"/${MYP}-src
PATCHES=( "${FILESDIR}"/${P}-gentoo.patch )
-pkg_setup() {
- GCC=${ADA:-$(tc-getCC)}
- GNATMAKE="${GCC/gcc/gnatmake}"
- GNATCHOP="${GCC/gcc/gnatchop}"
- if [[ -z "$(type ${GNATMAKE} 2>/dev/null)" ]] ; then
- eerror "You need a gcc compiler that provides the Ada Compiler:"
- eerror "1) use gcc-config to select the right compiler or"
- eerror "2) set ADA=gcc-4.9.4 in make.conf"
- die "ada compiler not available"
- fi
- python-single-r1_pkg_setup
-}
-
src_prepare() {
default
mv configure.{in,ac} || die
@@ -66,6 +55,14 @@ src_prepare() {
}
src_configure() {
+ if use gnat_2016; then
+ GCC_PV=4.9.4
+ else
+ GCC_PV=6.3.0
+ fi
+ GCC=${CHOST}-gcc-${GCC_PV}
+ GNATMAKE=${CHOST}-gnatmake-${GCC_PV}
+ GNATCHOP=${CHOST}-gnatchop-${GCC_PV}
if use sqlite; then
myConf="--with-sqlite=$(get_libdir)"
else
@@ -91,15 +88,18 @@ src_configure() {
--with-python-exec=${EPYTHON} \
--enable-shared-python \
--disable-pygtk \
+ CC=${GCC} \
$myConf
}
src_compile() {
if use shared; then
- emake PROCESSORS=$(makeopts_jobs) build_library_type/relocatable
+ emake PROCESSORS=$(makeopts_jobs) GPRBUILD_OPTIONS=-v GCC=${GCC} \
+ build_library_type/relocatable
fi
if use static; then
- emake PROCESSORS=$(makeopts_jobs) build_library_type/static
+ emake PROCESSORS=$(makeopts_jobs) GPRBUILD_OPTIONS=-v GCC=${GCC} \
+ build_library_type/static
fi
python_fix_shebang .
}
diff --git a/dev-ada/gnatcoll/gnatcoll-2017.ebuild b/dev-ada/gnatcoll/gnatcoll-2017.ebuild
index 64a817fd92c..e62932cebe4 100644
--- a/dev-ada/gnatcoll/gnatcoll-2017.ebuild
+++ b/dev-ada/gnatcoll/gnatcoll-2017.ebuild
@@ -18,7 +18,7 @@ KEYWORDS="~amd64"
IUSE="gmp gtk iconv postgresql pygobject projects readline +shared sqlite
static syslog"
-RDEPEND="dev-lang/gnat-gpl:*
+RDEPEND="dev-lang/gnat-gpl:6.3.0
${PYTHON_DEPS}
gmp? ( dev-libs/gmp:* )
gtk? (
@@ -37,7 +37,7 @@ RDEPEND="dev-lang/gnat-gpl:*
>=dev-ada/gprbuild-2017[static?,shared?]
)"
DEPEND="${RDEPEND}
- dev-ada/gprbuild"
+ dev-ada/gprbuild[gnat_2017]"
REQUIRED_USE="${PYTHON_REQUIRED_USE}
pygobject? ( gtk )"
@@ -46,19 +46,6 @@ S="${WORKDIR}"/${MYP}-src
PATCHES=( "${FILESDIR}"/${P}-gentoo.patch )
-pkg_setup() {
- GCC=${ADA:-$(tc-getCC)}
- GNATMAKE="${GCC/gcc/gnatmake}"
- GNATCHOP="${GCC/gcc/gnatchop}"
- if [[ -z "$(type ${GNATMAKE} 2>/dev/null)" ]] ; then
- eerror "You need a gcc compiler that provides the Ada Compiler:"
- eerror "1) use gcc-config to select the right compiler or"
- eerror "2) set ADA=gcc-4.9.4 in make.conf"
- die "ada compiler not available"
- fi
- python-single-r1_pkg_setup
-}
-
src_prepare() {
default
mv configure.{in,ac} || die
@@ -66,6 +53,9 @@ src_prepare() {
}
src_configure() {
+ GCC=${CHOST}-gcc-6.3.0
+ GNATMAKE=${CHOST}-gnatmake-6.3.0
+ GNATCHOP=${CHOST}-gnatchop-6.3.0
if use sqlite; then
myConf="--with-sqlite=$(get_libdir)"
else
diff --git a/dev-ada/gnatcoll/metadata.xml b/dev-ada/gnatcoll/metadata.xml
index 48cd9149b35..a54b19b4b3c 100644
--- a/dev-ada/gnatcoll/metadata.xml
+++ b/dev-ada/gnatcoll/metadata.xml
@@ -6,6 +6,8 @@
<name>Tupone Alfredo</name>
</maintainer>
<use>
+ <flag name="gnat_2016">Compile with dev-lang/gnat-gpl-2016</flag>
+ <flag name="gnat_2017">Compile with dev-lang/gnat-gpl-2017</flag>
<flag name="postgresql">Adds support for postgresql</flag>
<flag name="projects">Adds support for projects</flag>
<flag name="pygobject">Adds support for pygobject</flag>