summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Fabbro <bicatali@gentoo.org>2011-01-04 05:04:15 +0000
committerSebastien Fabbro <bicatali@gentoo.org>2011-01-04 05:04:15 +0000
commitfaaf98f5faacdc91710e842c790ee0094e18f15a (patch)
tree30d331857e9f5e31cb9a1382373fe2d8f6d71efc /dev-lang/gdl
parentQA: Remove redundant local use flag description (diff)
downloadgentoo-2-faaf98f5faacdc91710e842c790ee0094e18f15a.tar.gz
gentoo-2-faaf98f5faacdc91710e842c790ee0094e18f15a.tar.bz2
gentoo-2-faaf98f5faacdc91710e842c790ee0094e18f15a.zip
Install both python with gdl as a library and regular gdl exec. Also now uses bundled antlr to make it work on amd64.
(Portage version: 2.1.9.26/cvs/Linux x86_64)
Diffstat (limited to 'dev-lang/gdl')
-rw-r--r--dev-lang/gdl/ChangeLog12
-rw-r--r--dev-lang/gdl/files/gdl-0.9_rc4-antlr.patch40
-rw-r--r--dev-lang/gdl/files/gdl-0.9_rc4-wxwidgets.patch58
-rw-r--r--dev-lang/gdl/gdl-0.9-r1.ebuild (renamed from dev-lang/gdl/gdl-0.9.ebuild)74
4 files changed, 56 insertions, 128 deletions
diff --git a/dev-lang/gdl/ChangeLog b/dev-lang/gdl/ChangeLog
index bca397a09b97..e5ed9e527eab 100644
--- a/dev-lang/gdl/ChangeLog
+++ b/dev-lang/gdl/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for dev-lang/gdl
-# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/ChangeLog,v 1.22 2010/12/21 19:52:08 bicatali Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/ChangeLog,v 1.23 2011/01/04 05:04:15 bicatali Exp $
+
+*gdl-0.9-r1 (04 Jan 2011)
+
+ 04 Jan 2011; Sébastien Fabbro <bicatali@gentoo.org> -gdl-0.9.ebuild,
+ +gdl-0.9-r1.ebuild, -files/gdl-0.9_rc4-antlr.patch,
+ -files/gdl-0.9_rc4-wxwidgets.patch:
+ Install both python with gdl as a library and regular gdl exec. Also now uses
+ bundled antlr to make it work on amd64.
*gdl-0.9 (21 Dec 2010)
diff --git a/dev-lang/gdl/files/gdl-0.9_rc4-antlr.patch b/dev-lang/gdl/files/gdl-0.9_rc4-antlr.patch
deleted file mode 100644
index ab1ba5ee5431..000000000000
--- a/dev-lang/gdl/files/gdl-0.9_rc4-antlr.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-diff -Naur gdl-0.9rc4/configure.in gdl-0.9rc4.new/configure.in
---- gdl-0.9rc4/configure.in 2010-02-02 13:13:51.000000000 -0500
-+++ gdl-0.9rc4.new/configure.in 2010-02-04 22:39:56.000000000 -0500
-@@ -989,7 +989,7 @@
- dnl perform program name transformation
- dnl AC_ARG_PROGRAM
-
--AC_CONFIG_FILES(Makefile src/Makefile src/antlr/Makefile src/pro/Makefile src/pro/dicom/Makefile testsuite/Makefile doc/Makefile)
-+AC_CONFIG_FILES(Makefile src/Makefile src/pro/Makefile src/pro/dicom/Makefile testsuite/Makefile doc/Makefile)
- AC_OUTPUT
-
- dnl == summary table =======================================
-diff -Naur gdl-0.9rc4/src/Makefile.am gdl-0.9rc4.new/src/Makefile.am
---- gdl-0.9rc4/src/Makefile.am 2010-02-02 13:13:51.000000000 -0500
-+++ gdl-0.9rc4.new/src/Makefile.am 2010-02-04 22:40:42.000000000 -0500
-@@ -1,6 +1,6 @@
- # set the include path found by configure
- INCLUDES = $(EXT_INCLUDES) $(all_includes)
--SUBDIRS = antlr pro
-+SUBDIRS = pro
- noinst_HEADERS = gdlwidget.hpp prognode.hpp prognodeexpr.hpp
-
- cpp_hpp_files = accessdesc.hpp arrayindex.hpp assocdata.cpp assocdata.hpp \
-@@ -56,7 +56,7 @@
- gdl_CXXFLAGS = $(AM_CXXFLAGS)
- # the library search path.
- gdl_LDFLAGS = $(all_libraries)
--gdl_LDADD = $(top_builddir)/src/antlr/libantlr.a -L/usr/X11R6/lib64 -L/usr/X11R6/lib -lX11
-+gdl_LDADD = ANTLR_LIB -L/usr/X11R6/lib64 -L/usr/X11R6/lib -lX11
- endif
-
- # build as library (for python module)
-@@ -72,6 +72,6 @@
- libgdl_la_LDFLAGS = $(all_libraries) -Wl,-z,muldefs
- endif
-
--libgdl_la_LIBADD = $(top_builddir)/src/antlr/libantlr.la -L/usr/X11R6/lib64 -L/usr/X11R6/lib -lX11
-+libgdl_la_LIBADD = ANTLR_LIB -L/usr/X11R6/lib64 -L/usr/X11R6/lib -lX11
- endif
-
diff --git a/dev-lang/gdl/files/gdl-0.9_rc4-wxwidgets.patch b/dev-lang/gdl/files/gdl-0.9_rc4-wxwidgets.patch
deleted file mode 100644
index 0d9b87b6246b..000000000000
--- a/dev-lang/gdl/files/gdl-0.9_rc4-wxwidgets.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-diff --git a/configure.in b/configure.in
-index e77afe3..a012c7c 100644
---- a/configure.in
-+++ b/configure.in
-@@ -324,21 +324,25 @@ if test "x$with_wxWidgets" != "xno"; then
- dnl LDFLAGS="$LDFLAGS -Wl,-dylib_file,/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib:/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib"
- fi
-
-- tmp="`wx-config --basename`-`wx-config --release`"
-- AC_CHECK_LIB($tmp, wxFatalSignalHandler,
-- [AC_DEFINE([HAVE_LIBWXWIDGETS], [1], [wxWidgets library])], [
-- dnl SA: handling the multi-port wxWidgets installation case
-- tmp="`wx-config --basename --toolkit=base`-`wx-config --release`"
-- AC_CHECK_LIB($tmp, wxInteger_compare, [AC_DEFINE([HAVE_LIBWXWIDGETS], [1])], [
-- echo ""
-- echo "Error! wxWidgets version 2.8 or later is required but was not found"
-- echo " Use --with-wxWidgets=DIR to specify the wxWidgets directory tree"
-- echo " Use --with-wxWidgets=no to not use it"
-- echo " Check the README or use configure --help for other libraries needed"
-- echo " (--with-xxxdir = obligatory, --with-xxx = optional (--with-xxx=no to disable))"
-- exit -1
-- ])
-- ])
-+ AC_DEFINE([HAVE_LIBWXWIDGETS], [1], [wxWidgets library])
-+
-+ # SA: the code below worked for me on Ubuntu and Macports... but it does not work e.g. on Fedora
-+ #
-+ #tmp="`wx-config --basename`-`wx-config --release`"
-+ #AC_CHECK_LIB($tmp, wxFatalSignalHandler,
-+ # [AC_DEFINE([HAVE_LIBWXWIDGETS], [1], [wxWidgets library])], [
-+ # dnl SA: handling the multi-port wxWidgets installation case
-+ # tmp="`wx-config --basename --toolkit=base`-`wx-config --release`"
-+ # AC_CHECK_LIB($tmp, wxInteger_compare, [AC_DEFINE([HAVE_LIBWXWIDGETS], [1])], [
-+ # echo ""
-+ # echo "Error! wxWidgets version 2.8 or later is required but was not found"
-+ # echo " Use --with-wxWidgets=DIR to specify the wxWidgets directory tree"
-+ # echo " Use --with-wxWidgets=no to not use it"
-+ # echo " Check the README or use configure --help for other libraries needed"
-+ # echo " (--with-xxxdir = obligatory, --with-xxx = optional (--with-xxx=no to disable))"
-+ # exit -1
-+ # ])
-+ #])
- fi
-
- dnl == ImageMagick =========================================
-diff --git a/src/widget.cpp b/src/widget.cpp
-index dc65ad1..316d599 100644
---- a/src/widget.cpp
-+++ b/src/widget.cpp
-@@ -589,7 +589,7 @@ namespace lib {
-
- RefDNode theAST;
-
-- GDLLexer lexer(istr, "");
-+ GDLLexer lexer(istr, "", GDLParser::NONE);
- GDLParser& parser = lexer.Parser();
- parser.interactive();
-
diff --git a/dev-lang/gdl/gdl-0.9.ebuild b/dev-lang/gdl/gdl-0.9-r1.ebuild
index 2cf4ca46ce1c..0874d4f87bcf 100644
--- a/dev-lang/gdl/gdl-0.9.ebuild
+++ b/dev-lang/gdl/gdl-0.9-r1.ebuild
@@ -1,12 +1,16 @@
-# Copyright 1999-2010 Gentoo Foundation
+# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/gdl-0.9.ebuild,v 1.1 2010/12/21 19:52:08 bicatali Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/gdl-0.9-r1.ebuild,v 1.1 2011/01/04 05:04:15 bicatali Exp $
-EAPI="2"
+EAPI=3
WX_GTK_VER="2.8"
+PYTHON_DEPEND="python? 2"
+SUPPORT_PYTHON_ABIS="1"
-inherit autotools eutils wxwidgets
+inherit autotools eutils wxwidgets python
+
+RESTRICT_PYTHON_ABIS="3.*"
DESCRIPTION="An Interactive Data Language compatible incremental compiler"
HOMEPAGE="http://gnudatalanguage.sourceforge.net/"
@@ -32,7 +36,7 @@ RDEPEND="sys-libs/readline
wxwidgets? ( x11-libs/wxGTK:2.8[X] )"
DEPEND="${RDEPEND}
- dev-java/antlr[cxx]"
+ dev-java/antlr"
pkg_setup() {
use wxwidgets && wxwidgets_pkg_setup
@@ -40,40 +44,47 @@ pkg_setup() {
src_prepare() {
use hdf5 && has_version sci-libs/hdf5[mpi] && export CXX=mpicxx
+
epatch \
- "${FILESDIR}"/${PN}-0.9_rc4-antlr.patch \
"${FILESDIR}"/${PN}-0.9_rc2-gcc4.4.patch \
"${FILESDIR}"/${PN}-0.9_rc4-gcc4.3.patch \
"${FILESDIR}"/${PN}-0.9-numpy.patch \
"${FILESDIR}"/${PN}-0.9-configure.patch
- # we need to blow away the directory with antlr
- # otherwise the build system picks up bogus
- # header files
- rm -fr "${S}"/src/antlr || die "failed to remove antlr directory"
-
# adjust the *.pro file install path
- sed -i -e "s:datasubdir=.*$:datasubdir=\"${PN}\":" configure.in \
- || die "Failed to fix *.pro install patch."
-
- sed -i -e "s:ANTLR_LIB:-lantlr:" src/Makefile.am \
- || die "Failed to adjust link to libantlr."
+ sed -i \
+ -e "s:datasubdir=.*$:datasubdir=\"${PN}\":" \
+ configure.in || die "Failed to fix *.pro install patch."
eautoreconf
+ use python && python_copy_sources
}
src_configure() {
- econf \
- $(use_enable python python_module) \
- $(use_with X x) \
- $(use_with fftw) \
- $(use_with grib) \
- $(use_with hdf) \
- $(use_with hdf5) \
- $(use_with netcdf) \
- $(use_with imagemagick Magick) \
- $(use_with openmp) \
- $(use_with udunits) \
- $(use_with wxwidgets wxWidgets)
+ configuration() {
+ econf \
+ $(use_with X x) \
+ $(use_with fftw) \
+ $(use_with grib) \
+ $(use_with hdf) \
+ $(use_with hdf5) \
+ $(use_with netcdf) \
+ $(use_with imagemagick Magick) \
+ $(use_with openmp) \
+ $(use_with udunits) \
+ $(use_with wxwidgets wxWidgets) \
+ $@
+ }
+ configuration --disable-python_module
+ if use python; then
+ python_execute_function -s configuration --enable-python_module
+ fi
+}
+
+src_compile() {
+ default
+ if use python; then
+ python_src_compile
+ fi
}
src_test() {
@@ -83,5 +94,12 @@ src_test() {
src_install() {
emake DESTDIR="${D}" install || die "emake install failed"
+ if use python; then
+ installation() {
+ exeinto $(python_get_sitedir)
+ newexe src/.libs/libgdl.so.0.0.0 GDL.so || die
+ }
+ python_execute_function -s installation
+ fi
dodoc README PYTHON.txt AUTHORS ChangeLog NEWS TODO HACKING
}