ppl: make this build with gmp>=5.1; cross build support.

This commit is contained in:
Juan RP 2013-02-18 13:57:36 +01:00
parent c4dd7a3394
commit df6e5f2fec
3 changed files with 61 additions and 18 deletions

View File

@ -0,0 +1,51 @@
From 9f843aecc23981aec6ed1eaa8be06e6786a47f0d Mon Sep 17 00:00:00 2001
From: Roberto Bagnara <bagnara@cs.unipr.it>
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<mpz_class>::is_specialized;
const int std::numeric_limits<mpz_class>::digits;
const int std::numeric_limits<mpz_class>::digits10;
@@ -70,3 +73,6 @@ const bool std::numeric_limits<mpq_class>::is_modulo;
const bool std::numeric_limits<mpq_class>::traps;
const bool std::numeric_limits<mpq_class>::tininess_before;
const std::float_round_style std::numeric_limits<mpq_class>::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)

View File

@ -1,9 +1,6 @@
# Template file for 'ppl-devel'. # Template file for 'ppl-devel'.
# #
short_desc="${short_desc} -- development files)" short_desc="${short_desc} -- development files"
long_desc="${long_desc}
This package contains files for development, headers, static libs, etc."
do_install() { do_install() {
for d in bin include share; do for d in bin include share; do

View File

@ -1,29 +1,24 @@
# Template file for 'ppl' # Template file for 'ppl'
pkgname=ppl pkgname=ppl
version=1.0 version=1.0
revision=1 revision=2
subpackages="ppl-devel" subpackages="ppl-devel"
build_style=gnu-configure build_style=gnu-configure
configure_args="--enable-interfaces=c,cxx" 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" short_desc="The Parma Polyhedra Library"
homepage="http://bugseng.com/products/ppl" homepage="http://bugseng.com/products/ppl"
license="GPL-3" license="GPL-3"
maintainer="Juan RP <xtraeme@gmail.com>" maintainer="Juan RP <xtraeme@gmail.com>"
distfiles="http://bugseng.com/products/ppl/download/ftp/releases/${version}/ppl-${version}.tar.gz" distfiles="http://bugseng.com/products/ppl/download/ftp/releases/${version}/ppl-${version}.tar.gz"
checksum=fd346687482ad51c1e98eb260bd61dd5a35a0cff5f580404380c88b0089a71b4 checksum=fd346687482ad51c1e98eb260bd61dd5a35a0cff5f580404380c88b0089a71b4
long_desc="
The Parma Polyhedra Library (PPL) provides numerical abstractions especially disable_debug=yes
targeted at applications in the field of analysis and verification of complex
systems. These abstractions include convex polyhedra, defined as the pre_configure() {
intersection of a finite number of (open or closed) halfspaces, each autoreconf -fi
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."
post_install() { post_install() {
rm -rf ${DESTDIR}/usr/share/doc rm -rf ${DESTDIR}/usr/share/doc