From df6e5f2fec69335d6d292fe8a8425a7c9b75d48e Mon Sep 17 00:00:00 2001 From: Juan RP Date: Mon, 18 Feb 2013 13:57:36 +0100 Subject: [PATCH] ppl: make this build with gmp>=5.1; cross build support. --- srcpkgs/ppl/patches/gmp-5.1-compat.patch | 51 ++++++++++++++++++++++++ srcpkgs/ppl/ppl-devel.template | 5 +-- srcpkgs/ppl/template | 23 +++++------ 3 files changed, 61 insertions(+), 18 deletions(-) create mode 100644 srcpkgs/ppl/patches/gmp-5.1-compat.patch diff --git a/srcpkgs/ppl/patches/gmp-5.1-compat.patch b/srcpkgs/ppl/patches/gmp-5.1-compat.patch new file mode 100644 index 00000000000..64e1a303f5f --- /dev/null +++ b/srcpkgs/ppl/patches/gmp-5.1-compat.patch @@ -0,0 +1,51 @@ +From 9f843aecc23981aec6ed1eaa8be06e6786a47f0d Mon Sep 17 00:00:00 2001 +From: Roberto Bagnara +Date: Wed, 19 Dec 2012 08:42:19 +0100 +Subject: [PATCH] GMP version 5.1.0 (and, presumably, later versions) defines std::numeric_limits. + +--- + src/mp_std_bits.cc | 6 ++++++ + src/mp_std_bits_defs.hh | 6 ++++++ + 2 files changed, 12 insertions(+), 0 deletions(-) + +--- src/mp_std_bits.cc ++++ src/mp_std_bits.cc +@@ -25,6 +25,9 @@ site: http://bugseng.com/products/ppl/ . */ + #include "ppl-config.h" + #include "mp_std_bits_defs.hh" + ++#if __GNU_MP_VERSION < 5 \ ++ || (__GNU_MP_VERSION == 5 && __GNU_MP_VERSION_MINOR < 1) ++ + const bool std::numeric_limits::is_specialized; + const int std::numeric_limits::digits; + const int std::numeric_limits::digits10; +@@ -70,3 +73,6 @@ const bool std::numeric_limits::is_modulo; + const bool std::numeric_limits::traps; + const bool std::numeric_limits::tininess_before; + const std::float_round_style std::numeric_limits::round_style; ++ ++#endif // __GNU_MP_VERSION < 5 ++ // || (__GNU_MP_VERSION == 5 && __GNU_MP_VERSION_MINOR < 1) +--- src/mp_std_bits.defs.hh.orig 2013-02-16 17:19:52.254341676 +0100 ++++ src/mp_std_bits.defs.hh 2013-02-16 17:20:49.171965855 +0100 +@@ -38,6 +38,9 @@ void swap(mpz_class& x, mpz_class& y); + #endif // defined(PPL_DOXYGEN_INCLUDE_IMPLEMENTATION_DETAILS) + void swap(mpq_class& x, mpq_class& y); + ++#if __GNU_MP_VERSION < 5 \ ++ || (__GNU_MP_VERSION == 5 && __GNU_MP_VERSION_MINOR < 1) ++ + namespace std { + + #ifdef PPL_DOXYGEN_INCLUDE_IMPLEMENTATION_DETAILS +@@ -164,6 +167,9 @@ public: + + } // namespace std + ++#endif // __GNU_MP_VERSION < 5 ++ // || (__GNU_MP_VERSION == 5 && __GNU_MP_VERSION_MINOR < 1 ++ + #include "mp_std_bits.inlines.hh" + + #endif // !defined(PPL_mp_std_bits_defs_hh) diff --git a/srcpkgs/ppl/ppl-devel.template b/srcpkgs/ppl/ppl-devel.template index a2c428a579c..4b250698bd3 100644 --- a/srcpkgs/ppl/ppl-devel.template +++ b/srcpkgs/ppl/ppl-devel.template @@ -1,9 +1,6 @@ # Template file for 'ppl-devel'. # -short_desc="${short_desc} -- development files)" -long_desc="${long_desc} - - This package contains files for development, headers, static libs, etc." +short_desc="${short_desc} -- development files" do_install() { for d in bin include share; do diff --git a/srcpkgs/ppl/template b/srcpkgs/ppl/template index 950953a9bed..0a5a8bca23f 100644 --- a/srcpkgs/ppl/template +++ b/srcpkgs/ppl/template @@ -1,29 +1,24 @@ # Template file for 'ppl' pkgname=ppl version=1.0 -revision=1 +revision=2 subpackages="ppl-devel" build_style=gnu-configure configure_args="--enable-interfaces=c,cxx" -makedepends="gmp-devel" +makedepends="automake gmp-devel>=5.1.1" +crossmakedepends="gmp-devel>=5.1.1" short_desc="The Parma Polyhedra Library" homepage="http://bugseng.com/products/ppl" license="GPL-3" maintainer="Juan RP " distfiles="http://bugseng.com/products/ppl/download/ftp/releases/${version}/ppl-${version}.tar.gz" checksum=fd346687482ad51c1e98eb260bd61dd5a35a0cff5f580404380c88b0089a71b4 -long_desc=" - The Parma Polyhedra Library (PPL) provides numerical abstractions especially - targeted at applications in the field of analysis and verification of complex - systems. These abstractions include convex polyhedra, defined as the - intersection of a finite number of (open or closed) halfspaces, each - described by a linear inequality (strict or non-strict) with rational - coefficients; some special classes of polyhedra shapes that offer interesting - complexity/precision tradeoffs; and grids which represent regularly spaced - points that satisfy a set of linear congruence relations. The library also - supports finite powersets and products of (any kind of) polyhedra and grids - and a mixed integer linear programming problem solver using an - exact-arithmetic version of the simplex algorithm." + +disable_debug=yes + +pre_configure() { + autoreconf -fi +} post_install() { rm -rf ${DESTDIR}/usr/share/doc