summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTupone Alfredo <tupone@gentoo.org>2017-04-24 23:04:05 +0200
committerTupone Alfredo <tupone@gentoo.org>2017-04-24 23:04:05 +0200
commitce2804ebe6c5d757d481f31a9cd0cbca6bf20726 (patch)
tree75b8b866315ca77377638c9280cf3c17558c4fa4 /dev-ada
parentnet-dialup/picocom: remove old (diff)
downloadgentoo-ce2804ebe6c5d757d481f31a9cd0cbca6bf20726.tar.gz
gentoo-ce2804ebe6c5d757d481f31a9cd0cbca6bf20726.tar.bz2
gentoo-ce2804ebe6c5d757d481f31a9cd0cbca6bf20726.zip
dev-ada/gnatcoll: Adding support to gtk, using python unconditionally
Package-Manager: Portage-2.3.3, Repoman-2.3.1
Diffstat (limited to 'dev-ada')
-rw-r--r--dev-ada/gnatcoll/files/gnatcoll-2016-gentoo.patch176
-rw-r--r--dev-ada/gnatcoll/gnatcoll-2016.ebuild46
2 files changed, 210 insertions, 12 deletions
diff --git a/dev-ada/gnatcoll/files/gnatcoll-2016-gentoo.patch b/dev-ada/gnatcoll/files/gnatcoll-2016-gentoo.patch
index e69b6e50a90e..a54a7c125667 100644
--- a/dev-ada/gnatcoll/files/gnatcoll-2016-gentoo.patch
+++ b/dev-ada/gnatcoll/files/gnatcoll-2016-gentoo.patch
@@ -176,3 +176,179 @@
[
with Interfaces; use Interfaces;
procedure Check is
+--- gnatcoll-gpl-2016-src/testsuite/json/__init__.py.old 2017-04-24 17:52:34.158513249 +0200
++++ gnatcoll-gpl-2016-src/testsuite/json/__init__.py 2017-04-24 17:52:52.636207017 +0200
+@@ -21,7 +21,7 @@
+ @requires_not_aix # Storage_Error on that machine
+ @chdir("MB28-001")
+ def test_MB28_001(self):
+- self.runexec(["python", "make_json.py"])
++ self.runexec(["python2.7", "make_json.py"])
+ self.gprbuild()
+ self.runexec("json_stack_test", "test.out")
+
+--- gnatcoll-gpl-2016-src/testsuite/projects/aggregate_create/c1/c.gpr.old 2017-04-24 18:00:21.652975475 +0200
++++ gnatcoll-gpl-2016-src/testsuite/projects/aggregate_create/c1/c.gpr 2017-04-24 18:01:23.035983670 +0200
+@@ -15,6 +15,7 @@
+ for Default_Switches ("ada") use
+ ("-g", "-gnatQ", "-O1", "-gnatf", "-gnato", "-gnatwa.Xe", "-gnaty");
+ for Switches ("c") use ("-fdump-xref");
++ for Driver ("c") use External ("CC", "gcc");
+ end Compiler;
+
+ end c;
+--- gnatcoll-gpl-2016-src/testsuite/projects/aggregate_create/c2/c.gpr.old 2017-04-24 18:01:28.394896928 +0200
++++ gnatcoll-gpl-2016-src/testsuite/projects/aggregate_create/c2/c.gpr 2017-04-24 18:01:44.343638682 +0200
+@@ -15,6 +15,7 @@
+ for Default_Switches ("ada") use
+ ("-g", "-gnatQ", "-O1", "-gnatf", "-gnato", "-gnatwa.Xe", "-gnaty");
+ for Switches ("C") use ("-fdump-xref");
++ for Driver ("C") use External ("CC", "gcc");
+ end Compiler;
+
+ end c;
+--- gnatcoll-gpl-2016-src/testsuite/projects/__init__.py.old 2017-04-24 19:10:30.465246199 +0200
++++ gnatcoll-gpl-2016-src/testsuite/projects/__init__.py 2017-04-24 19:10:42.768035080 +0200
+@@ -105,25 +105,6 @@
+ self.gprbuild("default.gpr")
+ self.runexec("main", "")
+
+- @support.requires_not_windows
+- @chdir("N918-040")
+- def test_bareboard(self):
+- self.create_fake_bb_compiler('install', 'arm-eabi', '6.1.0w', '3.4.6')
+-
+- # Make sure auto.cgpr is not deleted on exit
+- try:
+- os.unlink('auto.cgpr')
+- except:
+- pass
+- self.gprbuild('main_prj', switches=['--autoconf=auto.cgpr'])
+- m = re.search('for Target use "(.*?)"', open('auto.cgpr').read())
+- target = m.group(1)
+-
+- def customFilter(actual):
+- return actual.replace(target, "<native>")
+-
+- self.runexec(['sh', 'test.sh'], 'test.out', customFilter=customFilter)
+-
+ @chdir("NB12-045")
+ def test_NB12_045(self):
+ # Test registering attribute in unknown package
+--- gnatcoll-gpl-2016-src/testsuite/xref/tabs/default.gpr.old 2017-04-24 20:01:55.535913959 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/tabs/default.gpr 2017-04-24 20:02:51.740950192 +0200
+@@ -1,3 +1,6 @@
+ project Default is
+ for Languages use ("Ada", "C");
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end Compiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/doc1/dummy.gpr.old 2017-04-24 20:04:12.012574064 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/doc1/dummy.gpr 2017-04-24 20:04:54.025853974 +0200
+@@ -6,4 +6,7 @@
+ for Body_Suffix ("c++") use ".cc";
+ end Naming;
+
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end Compiler;
+ end Dummy;
+--- gnatcoll-gpl-2016-src/testsuite/xref/cpp_ref3/default.gpr.old 2017-04-24 20:08:06.018564544 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/cpp_ref3/default.gpr 2017-04-24 20:08:53.682748215 +0200
+@@ -1,3 +1,7 @@
+ project Default is
+ for Languages use ("C");
++
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end Compiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/cpp_ref2/default.gpr.old 2017-04-24 20:10:00.146610101 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/cpp_ref2/default.gpr 2017-04-24 20:10:40.512919251 +0200
+@@ -1,3 +1,7 @@
+ project Default is
+ for Languages use ("C");
++
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end COmpiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/cpp_ref1/default.gpr.old 2017-04-24 20:13:28.543059408 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/cpp_ref1/default.gpr 2017-04-24 20:14:05.513430176 +0200
+@@ -1,3 +1,7 @@
+ project Default is
+ for Languages use ("C");
++
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end Compiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/cpp_expr1/default.gpr.old 2017-04-24 20:15:26.420053157 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/cpp_expr1/default.gpr 2017-04-24 20:16:12.695265558 +0200
+@@ -1,3 +1,6 @@
+ project Default is
+ for Languages use ("C");
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end Compiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/cpp_enum/dummy.gpr.old 2017-04-24 20:16:53.562570024 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/cpp_enum/dummy.gpr 2017-04-24 20:17:32.086914323 +0200
+@@ -4,4 +4,7 @@
+ for Spec_Suffix ("c++") use ".h";
+ for Body_Suffix ("c++") use ".cc";
+ end Naming;
++ package Compiler is
++ for Driver ("c") use External ("CC", "gcc");
++ end Compiler;
+ end Dummy;
+--- gnatcoll-gpl-2016-src/testsuite/xref/cpp_dbi_error/dummy.gpr.old 2017-04-24 20:18:03.688376474 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/cpp_dbi_error/dummy.gpr 2017-04-24 20:18:52.761541251 +0200
+@@ -1,3 +1,6 @@
+ project Dummy is
+ for Languages use ("c");
++ package Compiler is
++ for Driver ("c") use External ("CC", "gcc");
++ end Compiler;
+ end Dummy;
+--- gnatcoll-gpl-2016-src/testsuite/xref/L821-017-import/default.gpr.old 2017-04-24 20:19:40.401730504 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/L821-017-import/default.gpr 2017-04-24 20:22:52.303465944 +0200
+@@ -4,5 +4,6 @@
+ package Compiler is
+ for Switches ("C") use ("-fsyntax-only", "-fdump-xref");
+ for Switches ("C++") use ("-fsyntax-only", "-fdump-xref");
++ for Driver ("C") use External ("CC", "gcc");
+ end Compiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/E224-007-change_obj_dir-c/default.gpr.old 2017-04-24 20:31:02.679123516 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/E224-007-change_obj_dir-c/default.gpr 2017-04-24 20:31:42.515445784 +0200
+@@ -8,4 +8,7 @@
+ when "release" => for Object_Dir use "obj1";
+ when "debug" => for Object_Dir use "obj2";
+ end case;
++ package Compiler is
++ for Driver ("C") use External ("CC", "gcc");
++ end Compiler;
+ end Default;
+--- gnatcoll-gpl-2016-src/testsuite/xref/I401-027/default.gpr.old 2017-04-24 20:32:45.175379776 +0200
++++ gnatcoll-gpl-2016-src/testsuite/xref/I401-027/default.gpr 2017-04-24 20:33:16.130853112 +0200
+@@ -7,6 +7,7 @@
+ package Compiler is
+ for Default_Switches ("Ada") use ("-gnatws");
+ for Default_Switches ("C") use ("-fdump-xref");
++ for Driver ("C") use External ("CC", "gcc");
+ end Compiler;
+
+ end Default;
+--- gnatcoll-gpl-2016-src/src/tools/gnatcoll_db2ada.adb.old 2017-04-24 21:36:09.193973179 +0200
++++ gnatcoll-gpl-2016-src/src/tools/gnatcoll_db2ada.adb 2017-04-24 21:36:16.029858932 +0200
+@@ -211,7 +211,7 @@
+
+ declare
+ Output : constant String := Get_Command_Output
+- (Command => "python",
++ (Command => "python2.7",
+ Arguments => Args,
+ Input => "",
+ Status => Status'Access,
diff --git a/dev-ada/gnatcoll/gnatcoll-2016.ebuild b/dev-ada/gnatcoll/gnatcoll-2016.ebuild
index c7e5367ec214..7f00456dddf3 100644
--- a/dev-ada/gnatcoll/gnatcoll-2016.ebuild
+++ b/dev-ada/gnatcoll/gnatcoll-2016.ebuild
@@ -9,17 +9,27 @@ MYP=${PN}-gpl-${PV}
DESCRIPTION="GNAT Component Collection"
HOMEPAGE="http://libre.adacore.com"
-SRC_URI="http://mirrors.cdn.adacore.com/art/5739942ac7a447658d00e1e7 -> ${MYP}-src.tar.gz"
+SRC_URI="http://mirrors.cdn.adacore.com/art/5739942ac7a447658d00e1e7
+ -> ${MYP}-src.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64"
-IUSE="gmp iconv postgresql projects python readline +shared sqlite static syslog"
+IUSE="gmp gtk iconv postgresql projects readline +shared sqlite static syslog"
RDEPEND="dev-lang/gnat-gpl
+ ${PYTHON_DEPS}
gmp? ( dev-libs/gmp:* )
+ gtk? (
+ dev-ada/gtkada
+ dev-libs/atk
+ dev-libs/glib
+ x11-libs/cairo
+ x11-libs/gdk-pixbuf
+ x11-libs/gtk+:3
+ x11-libs/pango
+ )
postgresql? ( dev-db/postgresql:* )
- python? ( ${PYTHON_DEPS} )
sqlite? ( dev-db/sqlite )
projects? (
dev-ada/gprbuild[static?,shared?]
@@ -27,7 +37,7 @@ RDEPEND="dev-lang/gnat-gpl
DEPEND="${RDEPEND}
dev-ada/gprbuild"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
S="${WORKDIR}"/${MYP}-src
@@ -43,7 +53,7 @@ pkg_setup() {
eerror "2) set ADA=gcc-4.9.4 in make.conf"
die "ada compiler not available"
fi
- use python && python-single-r1_pkg_setup
+ python-single-r1_pkg_setup
}
src_prepare() {
@@ -53,26 +63,29 @@ src_prepare() {
}
src_configure() {
- local myConf=""
if use sqlite; then
- myConf="$myConf --with-sqlite=$(get_libdir)"
+ myConf="--with-sqlite=$(get_libdir)"
else
- myConf="$myConf --without-sqlite"
+ myConf="--without-sqlite"
+ fi
+ if use gtk ; then
+ myConf="$myConf --with-gtk=3.0"
+ else
+ myConf="$myConf --with-gtk=no"
fi
econf \
GNATCHOP="${GNATCHOP}" \
GNATMAKE="${GNATMAKE}" \
+ --with-python \
$(use_with gmp) \
$(use_with iconv) \
$(use_with postgresql) \
$(use_enable projects) \
- $(use_with python) \
$(use_enable readline gpl) \
$(use_enable readline) \
$(use_enable syslog) \
--with-python-exec=${EPYTHON} \
--enable-shared-python \
- --without-gtk \
--disable-pygtk \
--disable-pygobject \
$myConf
@@ -85,6 +98,7 @@ src_compile() {
if use static; then
emake PROCESSORS=$(makeopts_jobs) build_library_type/static
fi
+ python_fix_shebang .
}
src_install() {
@@ -96,13 +110,21 @@ src_install() {
fi
emake DESTDIR="${D}" install_gps_plugin
einstalldocs
- dodoc -r features-* known-problems-* examples
+ dodoc -r features-* known-problems-*
mv "${D}"/usr/share/doc/${PN}/GNATColl.pdf "${D}"/usr/share/doc/${PF}/
mv "${D}"/usr/share/doc/${PN}/html/html "${D}"/usr/share/doc/${PF}/
+ mv "${D}"/usr/share/examples/${PN} "${D}"/usr/share/doc/${PF}/examples
rm -rf "${D}"/usr/share/doc/${PN}
- use python && python_fix_shebang "${ED}"usr/share/gnatcoll/dborm.py
+ rmdir "${D}"/usr/share/examples
+ docompress -x /usr/share/doc/${PF}/examples
}
src_test() {
+ # The test suite is in
+ # To run you need to have the ada compiler available as gcc
+ # Even in this case there are still some problem
+ # Going into the testsuite directory and running
+ # ./run.py -v -v
+ # run here (having enabled most USE flags)
true
}