mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-01-17 23:34:07 +00:00
community/gap to 4.11.1-1
This commit is contained in:
parent
3dfe3f2ae7
commit
b4d193732c
6 changed files with 27 additions and 526 deletions
|
@ -7,56 +7,36 @@
|
|||
|
||||
pkgbase=gap
|
||||
pkgname=(gap gap-doc gap-packages)
|
||||
pkgver=4.11.0
|
||||
pkgrel=9
|
||||
pkgver=4.11.1
|
||||
pkgrel=1
|
||||
pkgdesc="Groups, Algorithms, Programming: a system for computational discrete algebra"
|
||||
arch=(x86_64)
|
||||
url="https://www.gap-system.org/"
|
||||
license=(GPL)
|
||||
source=("https://files.gap-system.org/gap-${pkgver%.*}/tar.gz/gap-$pkgver.tar.gz" gap.sh
|
||||
git+https://github.com/gap-packages/NormalizInterface#commit=cd69a42
|
||||
gap-polymake-4.0.patch
|
||||
gap-cddlib-0.94k.patch
|
||||
gap-normaliz-3.8.8.patch
|
||||
gap-libsemigroups-1.3.patch
|
||||
source=(https://github.com/gap-system/gap/releases/download/v$pkgver/$pkgbase-$pkgver.tar.gz
|
||||
gap.sh
|
||||
gap-libsemigroups-1.3.4.patch)
|
||||
sha256sums=('6fda7af23394708aeb3b4bca8885f5fdcb7c3ae4419639dfb2d9f67d3f590abb'
|
||||
sha256sums=('6635c5da7d82755f8339486b9cac33766f58712f297e8234fba40818902ea304'
|
||||
'143fb8a79a52c007903cce13407850df309ef803a9b00398d05169355917de46'
|
||||
'SKIP'
|
||||
'e3f6d671c8df9acb6143a7c279391957967cd44f0a00b949323401d5b54ed685'
|
||||
'151ddbd7cf234158c8bd79153ac0ded3076f103859a65b238dd5c86084be3d98'
|
||||
'4023aaf1617d653f84d711d5642485984395a01464d64ded0a7e884c48b2a332'
|
||||
'c69c35293c194528a0beeeea533d3bae93208cc6a6bed9ffab2c2ebdb1c6d444'
|
||||
'e4024342332fd583967b2797627dfae61eb6ebcb5b73baced1e2a464be4d679b')
|
||||
makedepends=(libxaw givaro mpfi normaliz polymake boost libsemigroups c-xsc zeromq fplll wget chrpath fmt git)
|
||||
'b24cda7763bbdf249f4693c22231c17a682aacdc4bc5754e88e0ace9700af7e7')
|
||||
makedepends=(libxaw givaro mpfi cddlib boost libsemigroups c-xsc zeromq fplll wget chrpath fmt)
|
||||
# TODO: unbundle normaliz
|
||||
|
||||
prepare() {
|
||||
cd gap-$pkgver
|
||||
|
||||
# Use system normaliz
|
||||
sed -e '/build-normaliz.sh/d' -i bin/BuildPackages.sh
|
||||
# Use system libsemigroups
|
||||
sed -e 's|test "$with_external_libsemigroups" = yes|true|' -i pkg/semigroups-*/configure
|
||||
# Fix https://bugs.archlinux.org/task/55174
|
||||
sed -e '/xgap/d' -i pkg/sonata-*/PackageInfo.g
|
||||
sed -e '/XGAP/d' -i pkg/cryst/PackageInfo.g
|
||||
|
||||
# Update NormalizInterface to support recent normaliz
|
||||
rm -r pkg/NormalizInterface-1.1.0
|
||||
cp -r ../NormalizInterface pkg
|
||||
|
||||
cd pkg/semigroups-*
|
||||
patch -p1 -i "$srcdir"/gap-libsemigroups-1.3.patch # Fix build with libsemigroups 1.3
|
||||
patch -p1 -i "$srcdir"/gap-libsemigroups-1.3.4.patch # Fix build with libsemigroups 1.3.4
|
||||
|
||||
cd ../PolymakeInterface-*
|
||||
patch -p2 -i "$srcdir"/gap-polymake-4.0.patch # Fix build with polymake 4.0
|
||||
|
||||
cd ../CddInterface-*
|
||||
patch -p1 -i "$srcdir"/gap-cddlib-0.94k.patch # Fix build with cddlib 0.94k
|
||||
|
||||
cd ../NormalizInterface
|
||||
patch -p1 -i "$srcdir"/gap-normaliz-3.8.8.patch # Fix build with normaliz 3.8.8
|
||||
sed -e 's|/usr/include/cdd|/usr/include/cddlib|' -i configure.ac # Fix build with cddlib 0.94k
|
||||
rm configure
|
||||
}
|
||||
|
||||
build() {
|
||||
|
@ -72,17 +52,17 @@ build() {
|
|||
# Install libgap so we can link packages against it
|
||||
mkdir -p tmp-install
|
||||
libtool --mode=install install libgap.la "$srcdir"/gap-$pkgver/tmp-install
|
||||
rm "$srcdir"/gap-$pkgver/tmp-install/libgap.la
|
||||
|
||||
cd pkg
|
||||
export CFLAGS+=" -fcommon" # Fix anupq and cohomolo build with GCC 10
|
||||
export CXXFLAGS+=" -I/usr/include/cxsc" # Find c-xsc headers
|
||||
export LDFLAGS+=" -L$srcdir/gap-$pkgver/tmp-install -lgap" # See https://trac.sagemath.org/ticket/27372
|
||||
export LD_LIBRARY_PATH="$srcdir"/gap-$pkgver/tmp-install
|
||||
export MAKEFLAGS="-j1"
|
||||
../bin/BuildPackages.sh
|
||||
}
|
||||
|
||||
_standardpkgs=(GAPDoc-* primgrp-* SmallGrp-* transgrp atlasrep autpgrp-* alnuth-* crisp-* ctbllib FactInt-* fga irredsol-* laguna-*
|
||||
_standardpkgs=(GAPDoc-* primgrp-* SmallGrp-* transgrp atlasrep autpgrp-* alnuth-* crisp-* ctbllib-* FactInt-* fga irredsol-* laguna-*
|
||||
polenta-* polycyclic-* resclasses-* sophus-* tomlib-*)
|
||||
|
||||
package_gap() {
|
||||
|
@ -125,9 +105,9 @@ package_gap-doc() {
|
|||
package_gap-packages() {
|
||||
depends=(gap)
|
||||
replaces=(gap-4.8-packages)
|
||||
optdepends=('normaliz: Normaliz interface package' 'libxaw: xgap package' 'c-xsc: float package' 'mpfi: float package'
|
||||
optdepends=('libxaw: xgap package' 'c-xsc: float package' 'mpfi: float package'
|
||||
'libmpc: float package' 'fplll: float package' 'zeromq: ZeroMQ interface package' 'planarity: digraph package'
|
||||
'curl: curl interface package' 'libsemigroups: semigroups package' 'polymake: Polymake interface package')
|
||||
'curl: curl interface package' 'libsemigroups: semigroups package' 'cddlib: CddLib interface package')
|
||||
pkgdesc="Extra packages for GAP"
|
||||
cd gap-$pkgver
|
||||
|
||||
|
@ -156,6 +136,5 @@ package_gap-packages() {
|
|||
find "$pkgdir"/usr/lib/gap/pkg -type d -name src | xargs rm -fr
|
||||
rm -r "$pkgdir"/usr/lib/gap/pkg/digraphs*/extern
|
||||
rm -r "$pkgdir"/usr/lib/gap/pkg/semigroups*/libsemigroups
|
||||
rm -r "$pkgdir"/usr/lib/gap/pkg/NormalizInterface/{.git*,.release,.c*,.t*,autom4te.cache}
|
||||
rm -r "$pkgdir"/usr/lib/gap/pkg/log
|
||||
}
|
||||
|
|
|
@ -1,15 +0,0 @@
|
|||
diff --git a/src/CddInterface.c b/src/CddInterface.c
|
||||
index da948e0..e025492 100644
|
||||
--- a/src/CddInterface.c
|
||||
+++ b/src/CddInterface.c
|
||||
@@ -4,8 +4,8 @@
|
||||
|
||||
#include "src/compiled.h" /* GAP headers */
|
||||
|
||||
-#include "setoper.h"
|
||||
-#include "cdd.h"
|
||||
+#include "cddlib/setoper.h"
|
||||
+#include "cddlib/cdd.h"
|
||||
|
||||
#include "gmp.h"
|
||||
|
|
@ -1,3 +1,15 @@
|
|||
diff --git a/src/semigrp.h b/src/semigrp.h
|
||||
index f2d5463a..327a7f14 100644
|
||||
--- a/src/semigrp.h
|
||||
+++ b/src/semigrp.h
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
#include "compiled.h" // GAP headers
|
||||
|
||||
+#include "libsemigroups/element-adapters.hpp"
|
||||
#include "libsemigroups/froidure-pin.hpp"
|
||||
|
||||
#include "converter.h"
|
||||
diff --git a/src/pkg.cc b/src/pkg.cc
|
||||
index 31987a1c..cd94e0d9 100644
|
||||
--- a/src/pkg.cc
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
diff --git a/src/semigrp.h b/src/semigrp.h
|
||||
index f2d5463a..327a7f14 100644
|
||||
--- a/src/semigrp.h
|
||||
+++ b/src/semigrp.h
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
#include "compiled.h" // GAP headers
|
||||
|
||||
+#include "libsemigroups/element-adapters.hpp"
|
||||
#include "libsemigroups/froidure-pin.hpp"
|
||||
|
||||
#include "converter.h"
|
|
@ -1,13 +0,0 @@
|
|||
diff --git a/src/normaliz.cc b/src/normaliz.cc
|
||||
index 979152d..f4a5748 100644
|
||||
--- a/src/normaliz.cc
|
||||
+++ b/src/normaliz.cc
|
||||
@@ -26,7 +26,7 @@
|
||||
#include "compiled.h" // GAP headers
|
||||
|
||||
#include "libnormaliz/cone.h"
|
||||
-#include "libnormaliz/map_operations.h"
|
||||
+#include "libnormaliz/list_and_map_operations.h"
|
||||
|
||||
#include <vector>
|
||||
|
|
@ -1,450 +0,0 @@
|
|||
diff --git a/PolymakeInterface/src/polymake_cone.cpp b/PolymakeInterface/src/polymake_cone.cpp
|
||||
index 6c17f49d..637266a0 100644
|
||||
--- a/PolymakeInterface/src/polymake_cone.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_cone.cpp
|
||||
@@ -110,16 +110,16 @@ Obj REAL_GENERATING_RAYS_OF_CONE( Polymake_Data* data, Obj cone){
|
||||
matr2 = -matr2;
|
||||
Obj RETLI3 = GAP_MATRIX_POLYMAKE_INTEGER_MATRIX( &matr2 );
|
||||
|
||||
- int len1 = LEN_PLIST( RETLI1 );
|
||||
- int len2 = LEN_PLIST( RETLI2 );
|
||||
+ Int len1 = LEN_PLIST( RETLI1 );
|
||||
+ Int len2 = LEN_PLIST( RETLI2 );
|
||||
|
||||
Obj RETLI = NEW_PLIST( T_PLIST, len1 + 2*len2 );
|
||||
SET_LEN_PLIST( RETLI, len1 + 2*len2 );
|
||||
|
||||
- for( int i = 1; i <= len1; i++ )
|
||||
+ for( Int i = 1; i <= len1; i++ )
|
||||
SET_ELM_PLIST( RETLI, i, ELM_PLIST( RETLI1, i ) );
|
||||
|
||||
- for( int i = 1; i <= len2; i++ ){
|
||||
+ for( Int i = 1; i <= len2; i++ ){
|
||||
SET_ELM_PLIST( RETLI, len1 + i, ELM_PLIST( RETLI2, i ) );
|
||||
SET_ELM_PLIST( RETLI, len1 + len2 + i, ELM_PLIST( RETLI3, i ) );
|
||||
}
|
||||
@@ -168,7 +168,7 @@ Obj REAL_HILBERT_BASIS_OF_CONE( Polymake_Data* data, Obj cone){
|
||||
polymake::Array<polymake::Matrix<polymake::Integer>> arr;
|
||||
try
|
||||
{
|
||||
- arr = coneobj->give("HILBERT_BASIS_GENERATORS");
|
||||
+ coneobj->give("HILBERT_BASIS_GENERATORS") >> arr;
|
||||
}
|
||||
|
||||
POLYMAKE_GAP_CATCH
|
||||
@@ -232,16 +232,16 @@ Obj REAL_DEFINING_INEQUALITIES_OF_CONE( Polymake_Data* data, Obj cone){
|
||||
matr2 = -matr2;
|
||||
Obj RETLI3 = GAP_MATRIX_POLYMAKE_INTEGER_MATRIX( &matr2 );
|
||||
|
||||
- int len1 = LEN_PLIST( RETLI1 );
|
||||
- int len2 = LEN_PLIST( RETLI2 );
|
||||
+ Int len1 = LEN_PLIST( RETLI1 );
|
||||
+ Int len2 = LEN_PLIST( RETLI2 );
|
||||
|
||||
Obj RETLI = NEW_PLIST( T_PLIST, len1 + 2*len2 );
|
||||
SET_LEN_PLIST( RETLI, len1 + 2*len2 );
|
||||
|
||||
- for( int i = 1; i <= len1; i++ )
|
||||
+ for( Int i = 1; i <= len1; i++ )
|
||||
SET_ELM_PLIST( RETLI, i, ELM_PLIST( RETLI1, i ) );
|
||||
|
||||
- for( int i = 1; i <= len2; i++ ){
|
||||
+ for( Int i = 1; i <= len2; i++ ){
|
||||
SET_ELM_PLIST( RETLI, len1 + i, ELM_PLIST( RETLI2, i ) );
|
||||
SET_ELM_PLIST( RETLI, len1 + len2 + i, ELM_PLIST( RETLI3, i ) );
|
||||
}
|
||||
diff --git a/PolymakeInterface/src/polymake_data.cpp b/PolymakeInterface/src/polymake_data.cpp
|
||||
index 3fc25241..ea3a4ed7 100644
|
||||
--- a/PolymakeInterface/src/polymake_data.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_data.cpp
|
||||
@@ -50,7 +50,7 @@ Obj ExternalPolymakeObjectTypeFunc(Obj o) {
|
||||
void polymake_start( Polymake_Data* data ){
|
||||
if( ! data->initialized ){
|
||||
data->main_polymake_session = new polymake::Main;
|
||||
- data->main_polymake_scope = new polymake::perl::Scope(data->main_polymake_session->newScope());
|
||||
+ data->main_polymake_scope = new pm::perl::Scope(data->main_polymake_session->newScope());
|
||||
data->initialized = true;
|
||||
}
|
||||
return;
|
||||
diff --git a/PolymakeInterface/src/polymake_data.h b/PolymakeInterface/src/polymake_data.h
|
||||
index b7d678ed..fcc3543c 100644
|
||||
--- a/PolymakeInterface/src/polymake_data.h
|
||||
+++ b/PolymakeInterface/src/polymake_data.h
|
||||
@@ -30,15 +30,15 @@ extern Obj TheTypeExternalPolymakeTropicalHypersurface;
|
||||
extern Obj TheTypeExternalPolymakeTropicalPolytope;
|
||||
extern Obj TheTypeExternalPolymakeMatroid;
|
||||
|
||||
-typedef pair<int, polymake::perl::Object*> object_pair;
|
||||
-typedef polymake::perl::Object perlobj;
|
||||
-typedef map<int, polymake::perl::Object*>::iterator iterator;
|
||||
+typedef pair<int, pm::perl::BigObject*> object_pair;
|
||||
+typedef pm::perl::BigObject perlobj;
|
||||
+typedef map<int, pm::perl::BigObject*>::iterator iterator;
|
||||
|
||||
struct Polymake_Data {
|
||||
bool initialized;
|
||||
polymake::Main *main_polymake_session;
|
||||
- polymake::perl::Scope *main_polymake_scope;
|
||||
- map<int, polymake::perl::Object*> *polymake_objects;
|
||||
+ pm::perl::Scope *main_polymake_scope;
|
||||
+ map<int, pm::perl::BigObject*> *polymake_objects;
|
||||
int new_polymake_object_number;
|
||||
};
|
||||
|
||||
diff --git a/PolymakeInterface/src/polymake_fan.cpp b/PolymakeInterface/src/polymake_fan.cpp
|
||||
index 6ea650c8..43c2e982 100644
|
||||
--- a/PolymakeInterface/src/polymake_fan.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_fan.cpp
|
||||
@@ -8,14 +8,14 @@ Obj REAL_FAN_BY_CONES( Polymake_Data* data, Obj cones ){
|
||||
return NULL;
|
||||
}
|
||||
|
||||
- int numberofcones = LEN_PLIST( cones );
|
||||
+ Int numberofcones = LEN_PLIST( cones );
|
||||
Obj akt;
|
||||
Obj elem;
|
||||
Obj numb;
|
||||
- int numberofrays = 0;
|
||||
+ Int numberofrays = 0;
|
||||
data->main_polymake_session->set_application("fan");
|
||||
|
||||
- for(int i=1;i<=numberofcones;i++){
|
||||
+ for(Int i=1;i<=numberofcones;i++){
|
||||
akt = ELM_PLIST( cones, i );
|
||||
#ifdef MORE_TESTS
|
||||
if( !IS_PLIST( akt ) ){
|
||||
@@ -27,15 +27,15 @@ Obj REAL_FAN_BY_CONES( Polymake_Data* data, Obj cones ){
|
||||
|
||||
}
|
||||
|
||||
- int dimension = LEN_PLIST( ELM_PLIST( ELM_PLIST( cones, 1 ), 1 ) );
|
||||
- polymake::Array<polymake::Set<int>> incMatr(numberofcones);
|
||||
+ Int dimension = LEN_PLIST( ELM_PLIST( ELM_PLIST( cones, 1 ), 1 ) );
|
||||
+ polymake::Array<polymake::Set<Int>> incMatr(numberofcones);
|
||||
polymake::Matrix<polymake::Rational> matr(numberofrays+1,dimension);
|
||||
- int raycounter = 1;
|
||||
- for(int i = 1; i <= numberofcones; i++){
|
||||
+ Int raycounter = 1;
|
||||
+ for(Int i = 1; i <= numberofcones; i++){
|
||||
akt = ELM_PLIST( cones, i );
|
||||
- for( int j = 1; j <= LEN_PLIST( akt ); j++){
|
||||
+ for( Int j = 1; j <= LEN_PLIST( akt ); j++){
|
||||
elem = ELM_PLIST( akt, j );
|
||||
- for( int k = 1; k <= LEN_PLIST( elem ); k++){
|
||||
+ for( Int k = 1; k <= LEN_PLIST( elem ); k++){
|
||||
numb = ELM_PLIST( elem, k );
|
||||
|
||||
#ifdef MORE_TESTS
|
||||
@@ -75,9 +75,9 @@ Obj REAL_FAN_BY_RAYS_AND_CONES( Polymake_Data* data, Obj rays, Obj cones ){
|
||||
|
||||
POLYMAKE_RATIONAL_MATRIX_GAP_MATRIX( &matr, rays );
|
||||
|
||||
- int numberofcones = LEN_PLIST( cones );
|
||||
- polymake::Array<polymake::Set<int>> incMatr(numberofcones);
|
||||
- for(int i=0;i<numberofcones;i++){
|
||||
+ Int numberofcones = LEN_PLIST( cones );
|
||||
+ polymake::Array<polymake::Set<Int>> incMatr(numberofcones);
|
||||
+ for(Int i=0;i<numberofcones;i++){
|
||||
akt = ELM_PLIST( cones, i+1 );
|
||||
#ifdef MORE_TESTS
|
||||
if( !IS_PLIST( akt ) ){
|
||||
@@ -85,7 +85,7 @@ Obj REAL_FAN_BY_RAYS_AND_CONES( Polymake_Data* data, Obj rays, Obj cones ){
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
- for(int j = 0; j < LEN_PLIST( akt ) ; j++){
|
||||
+ for(Int j = 0; j < LEN_PLIST( akt ) ; j++){
|
||||
numb = ELM_PLIST( akt, j+1 );
|
||||
#ifdef MORE_TESTS
|
||||
if( ! IS_INTOBJ( numb ) ){
|
||||
@@ -93,7 +93,7 @@ Obj REAL_FAN_BY_RAYS_AND_CONES( Polymake_Data* data, Obj rays, Obj cones ){
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
- incMatr[i] += static_cast<int>(INT_INTOBJ( numb ) - 1);
|
||||
+ incMatr[i] += static_cast<Int>(INT_INTOBJ( numb ) - 1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -123,9 +123,9 @@ Obj REAL_FAN_BY_RAYS_AND_CONES_UNSAVE( Polymake_Data* data, Obj rays, Obj cones
|
||||
polymake::Matrix<polymake::Rational> matr(0,0);
|
||||
POLYMAKE_RATIONAL_MATRIX_GAP_MATRIX( &matr, rays );
|
||||
|
||||
- int numberofcones = LEN_PLIST( cones );
|
||||
+ Int numberofcones = LEN_PLIST( cones );
|
||||
polymake::IncidenceMatrix<> incMatr(numberofcones,matr.rows());
|
||||
- for(int i=0;i<numberofcones;i++){
|
||||
+ for(Int i=0;i<numberofcones;i++){
|
||||
akt = ELM_PLIST( cones, i+1 );
|
||||
#ifdef MORE_TESTS
|
||||
if( !IS_PLIST( akt ) ){
|
||||
@@ -133,7 +133,7 @@ Obj REAL_FAN_BY_RAYS_AND_CONES_UNSAVE( Polymake_Data* data, Obj rays, Obj cones
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
- for(int j = 0; j < LEN_PLIST( akt ) ; j++){
|
||||
+ for(Int j = 0; j < LEN_PLIST( akt ) ; j++){
|
||||
numb = ELM_PLIST( akt, j+1 );
|
||||
#ifdef MORE_TESTS
|
||||
if( ! IS_INTOBJ( numb ) ){
|
||||
@@ -275,8 +275,8 @@ Obj REAL_F_VECTOR( Polymake_Data* data, Obj fan){
|
||||
UInt matr_rows = matr.size();
|
||||
Obj RETLI = NEW_PLIST( T_PLIST , matr.size() );
|
||||
SET_LEN_PLIST( RETLI , matr_rows );
|
||||
- for(int i = 0;i<matr.size(); i++){
|
||||
- SET_ELM_PLIST(RETLI,i+1,INTOBJ_INT( static_cast<int>(matr[i]) ));
|
||||
+ for(Int i = 0;i<matr.size(); i++){
|
||||
+ SET_ELM_PLIST(RETLI,i+1,INTOBJ_INT( static_cast<Int>(matr[i]) ));
|
||||
CHANGED_BAG(RETLI);
|
||||
}
|
||||
return RETLI;
|
||||
diff --git a/PolymakeInterface/src/polymake_fktn.cpp b/PolymakeInterface/src/polymake_fktn.cpp
|
||||
index c8e6ad8b..6ed28e25 100644
|
||||
--- a/PolymakeInterface/src/polymake_fktn.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_fktn.cpp
|
||||
@@ -120,12 +120,12 @@ Obj REAL_POLYMAKE_SKETCH_WITH_OPTIONS( Polymake_Data* data, Obj cone, Obj filena
|
||||
#endif
|
||||
perlobj* coneobj = PERLOBJ_POLYMAKEOBJ( cone );
|
||||
data->main_polymake_session->set_application_of(*coneobj);
|
||||
- polymake::perl::OptionSet sketch_options;
|
||||
+ pm::perl::OptionSet sketch_options;
|
||||
if( IS_STRING( filename ) ){
|
||||
sketch_options["File"] << CSTR_STRING( filename );
|
||||
}
|
||||
|
||||
- polymake::perl::OptionSet visual_options;
|
||||
+ pm::perl::OptionSet visual_options;
|
||||
if( IS_PLIST( options ) ){
|
||||
for( int i = 1; i <= LEN_PLIST( options ); i++ ){
|
||||
Obj current_option = ELM_PLIST( options, i );
|
||||
diff --git a/PolymakeInterface/src/polymake_fktn.h b/PolymakeInterface/src/polymake_fktn.h
|
||||
index cabc6e12..e372c95e 100644
|
||||
--- a/PolymakeInterface/src/polymake_fktn.h
|
||||
+++ b/PolymakeInterface/src/polymake_fktn.h
|
||||
@@ -23,7 +23,7 @@ using std::pair;
|
||||
// load the package.
|
||||
|
||||
//static polymake::Main *main_polymake_session;
|
||||
-//static polymake::perl::Scope *main_polymake_scope;
|
||||
+//static pm::perl::Scope *main_polymake_scope;
|
||||
//static map<int, pm::perl::Object*> *polymake_objects;
|
||||
//static int new_polymake_object_number;
|
||||
|
||||
diff --git a/PolymakeInterface/src/polymake_main.cpp b/PolymakeInterface/src/polymake_main.cpp
|
||||
index d4f45650..a114b932 100644
|
||||
--- a/PolymakeInterface/src/polymake_main.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_main.cpp
|
||||
@@ -490,7 +490,7 @@ Obj FuncPOLYMAKE_RESET_WORKSPACE( Obj self ){
|
||||
|
||||
delete akt_data.main_polymake_session;
|
||||
akt_data.main_polymake_session = new polymake::Main;
|
||||
- akt_data.main_polymake_scope = new polymake::perl::Scope(akt_data.main_polymake_session->newScope());
|
||||
+ akt_data.main_polymake_scope = new pm::perl::Scope(akt_data.main_polymake_session->newScope());
|
||||
|
||||
return True;
|
||||
|
||||
@@ -827,7 +827,7 @@ static Int InitLibrary ( StructInitInfo *module )
|
||||
// // We start with initialising the polymake classes.
|
||||
// akt_data.initialized = false;
|
||||
// // akt_data.main_polymake_session = new polymake::Main;
|
||||
-// // akt_data.main_polymake_scope = new polymake::perl::Scope(akt_data.main_polymake_session->newScope());
|
||||
+// // akt_data.main_polymake_scope = new pm::perl::Scope(akt_data.main_polymake_session->newScope());
|
||||
// // akt_data.main_polymake_session->set_application("polytope");
|
||||
// // akt_data.main_polymake_session->set_custom("$Verbose::scheduler",1);
|
||||
// //This is pretty slow.
|
||||
diff --git a/PolymakeInterface/src/polymake_matroid.cpp b/PolymakeInterface/src/polymake_matroid.cpp
|
||||
index 5a92c09e..98d91896 100644
|
||||
--- a/PolymakeInterface/src/polymake_matroid.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_matroid.cpp
|
||||
@@ -30,17 +30,17 @@ Obj REAL_CREATE_MATROID_ABSTRACT( Polymake_Data* data, Obj size, Obj elements ){
|
||||
return NULL;
|
||||
}
|
||||
|
||||
- int matroid_size = INT_INTOBJ( size );
|
||||
+ Int matroid_size = INT_INTOBJ( size );
|
||||
|
||||
if( ! IS_PLIST( elements ) ){
|
||||
ErrorMayQuit( "second argument is not a plain list", 0, 0);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
- int nr_of_basis = LEN_PLIST( elements );
|
||||
- polymake::Array<polymake::Set<int>> incMatr(nr_of_basis);
|
||||
+ Int nr_of_basis = LEN_PLIST( elements );
|
||||
+ polymake::Array<polymake::Set<Int>> incMatr(nr_of_basis);
|
||||
|
||||
- for( int current_basis=1;current_basis<=nr_of_basis;current_basis++){
|
||||
+ for( Int current_basis=1;current_basis<=nr_of_basis;current_basis++){
|
||||
|
||||
Obj current_basis_list = ELM_PLIST( elements, current_basis );
|
||||
|
||||
@@ -49,10 +49,10 @@ Obj REAL_CREATE_MATROID_ABSTRACT( Polymake_Data* data, Obj size, Obj elements ){
|
||||
return NULL;
|
||||
}
|
||||
|
||||
- int current_length = LEN_PLIST( current_basis_list );
|
||||
+ Int current_length = LEN_PLIST( current_basis_list );
|
||||
|
||||
- for( int i=1;i<=current_length;i++){
|
||||
- incMatr[current_basis] += static_cast<int>(INT_INTOBJ( ELM_PLIST( current_basis_list, i ) ) - 1);
|
||||
+ for( Int i=1;i<=current_length;i++){
|
||||
+ incMatr[current_basis] += static_cast<Int>(INT_INTOBJ( ELM_PLIST( current_basis_list, i ) ) - 1);
|
||||
}
|
||||
|
||||
}
|
||||
diff --git a/PolymakeInterface/src/polymake_polytopes.cpp b/PolymakeInterface/src/polymake_polytopes.cpp
|
||||
index b82f9819..e7553ae5 100644
|
||||
--- a/PolymakeInterface/src/polymake_polytopes.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_polytopes.cpp
|
||||
@@ -11,7 +11,7 @@ Obj REAL_CREATE_POLYTOPE_BY_POINTS( Polymake_Data* data, Obj polytope ){
|
||||
}
|
||||
#endif
|
||||
|
||||
- int len = LEN_PLIST( polytope );
|
||||
+ Int len = LEN_PLIST( polytope );
|
||||
Obj akt = ELM_PLIST( polytope, 1 );
|
||||
Obj elem;
|
||||
|
||||
@@ -22,7 +22,7 @@ Obj REAL_CREATE_POLYTOPE_BY_POINTS( Polymake_Data* data, Obj polytope ){
|
||||
}
|
||||
#endif
|
||||
|
||||
- int len_elem = LEN_PLIST( akt );
|
||||
+ Int len_elem = LEN_PLIST( akt );
|
||||
data->main_polymake_session->set_application("polytope");
|
||||
|
||||
polymake::Matrix<polymake::Rational> matr(len,len_elem+1);
|
||||
@@ -96,7 +96,7 @@ Obj REAL_VERTICES_OF_POLYTOPE( Polymake_Data* data, Obj polytope){
|
||||
LIZeil = NEW_PLIST( T_PLIST, matr.cols()-1);
|
||||
SET_LEN_PLIST( LIZeil , matr_cols );
|
||||
for(int j = 1;j<matr.cols();j++){
|
||||
- SET_ELM_PLIST(LIZeil,j,INTOBJ_INT(static_cast<int>(matr(i,j))));
|
||||
+ SET_ELM_PLIST(LIZeil,j,INTOBJ_INT(static_cast<Int>(matr(i,j))));
|
||||
}
|
||||
SET_ELM_PLIST(RETLI,k,LIZeil);
|
||||
CHANGED_BAG(RETLI);
|
||||
@@ -123,7 +123,7 @@ Obj REAL_LATTICE_POINTS_OF_POLYTOPE( Polymake_Data* data, Obj polytope){
|
||||
data->main_polymake_session->set_application_of(*polyobj);
|
||||
polymake::Array<polymake::Matrix<polymake::Integer>> arr;
|
||||
try{
|
||||
- arr = polyobj->give("LATTICE_POINTS_GENERATORS");
|
||||
+ polyobj->give("LATTICE_POINTS_GENERATORS") >> arr;
|
||||
}
|
||||
|
||||
POLYMAKE_GAP_CATCH
|
||||
@@ -138,7 +138,7 @@ Obj REAL_LATTICE_POINTS_OF_POLYTOPE( Polymake_Data* data, Obj polytope){
|
||||
LIZeil = NEW_PLIST( T_PLIST, matr.cols()-1);
|
||||
SET_LEN_PLIST( LIZeil , matr_cols );
|
||||
for(int j = 1;j<matr.cols();j++){
|
||||
- SET_ELM_PLIST(LIZeil,j,INTOBJ_INT(static_cast<int>(matr(i,j))));
|
||||
+ SET_ELM_PLIST(LIZeil,j,INTOBJ_INT(static_cast<Int>(matr(i,j))));
|
||||
}
|
||||
SET_ELM_PLIST(RETLI,i+1,LIZeil);
|
||||
CHANGED_BAG(RETLI);
|
||||
@@ -242,7 +242,7 @@ Obj REAL_INTERIOR_LATTICE_POINTS( Polymake_Data* data, Obj polytope){
|
||||
LIZeil = NEW_PLIST( T_PLIST, matr.cols()-1);
|
||||
SET_LEN_PLIST( LIZeil , matr_cols );
|
||||
for(int j = 1;j<matr.cols();j++){
|
||||
- SET_ELM_PLIST(LIZeil,j,INTOBJ_INT(static_cast<int>(matr(i,j))));
|
||||
+ SET_ELM_PLIST(LIZeil,j,INTOBJ_INT(static_cast<Int>(matr(i,j))));
|
||||
}
|
||||
SET_ELM_PLIST(RETLI,i+1,LIZeil);
|
||||
CHANGED_BAG(RETLI);
|
||||
@@ -327,7 +327,7 @@ Obj REAL_TAIL_CONE_OF_POLYTOPE( Polymake_Data* data, Obj polytope){
|
||||
LIZeil = NEW_PLIST( T_PLIST, matr.cols()-1);
|
||||
SET_LEN_PLIST( LIZeil , matr_cols );
|
||||
for(int j = 1;j<matr.cols();j++){
|
||||
- SET_ELM_PLIST(LIZeil,j, INTOBJ_INT( static_cast<int>(matr(i,j)) ) );
|
||||
+ SET_ELM_PLIST(LIZeil,j, INTOBJ_INT( static_cast<Int>(matr(i,j)) ) );
|
||||
}
|
||||
SET_ELM_PLIST(RETLI,k,LIZeil);
|
||||
CHANGED_BAG(RETLI);
|
||||
@@ -413,7 +413,7 @@ Obj REAL_LATTICE_POINTS_GENERATORS( Polymake_Data* data, Obj polytope ){
|
||||
data->main_polymake_session->set_application_of(*polyobj);
|
||||
polymake::Array<polymake::Matrix<polymake::Integer>> array;
|
||||
try{
|
||||
- array = polyobj->give("LATTICE_POINTS_GENERATORS");
|
||||
+ polyobj->give("LATTICE_POINTS_GENERATORS") >> array;
|
||||
}
|
||||
|
||||
POLYMAKE_GAP_CATCH
|
||||
diff --git a/PolymakeInterface/src/polymake_templates.h b/PolymakeInterface/src/polymake_templates.h
|
||||
index 5acfb733..82445aa9 100644
|
||||
--- a/PolymakeInterface/src/polymake_templates.h
|
||||
+++ b/PolymakeInterface/src/polymake_templates.h
|
||||
@@ -18,7 +18,7 @@ using std::pair;
|
||||
template<typename T>
|
||||
void POLYMAKE_RATIONAL_MATRIX_GAP_MATRIX( T* polymake_matrix, Obj gap_matrix ){
|
||||
|
||||
- int rows = LEN_PLIST( gap_matrix );
|
||||
+ Int rows = LEN_PLIST( gap_matrix );
|
||||
Obj current = ELM_PLIST( gap_matrix, 1 );
|
||||
Obj elem;
|
||||
|
||||
@@ -29,7 +29,7 @@ void POLYMAKE_RATIONAL_MATRIX_GAP_MATRIX( T* polymake_matrix, Obj gap_matrix ){
|
||||
}
|
||||
#endif
|
||||
|
||||
- int columns = LEN_PLIST( current );
|
||||
+ Int columns = LEN_PLIST( current );
|
||||
|
||||
polymake_matrix->resize( rows, columns );
|
||||
|
||||
@@ -72,7 +72,7 @@ Obj GAP_MATRIX_POLYMAKE_INTEGER_MATRIX( T* polymake_matrix ){
|
||||
LIZeil = NEW_PLIST( T_PLIST, polymake_matrix->cols() );
|
||||
SET_LEN_PLIST( LIZeil ,matr_cols);
|
||||
for(int j = 0;j<polymake_matrix->cols();j++){
|
||||
- SET_ELM_PLIST(LIZeil,j+1,INTOBJ_INT(static_cast<int>((*polymake_matrix)(i,j))));
|
||||
+ SET_ELM_PLIST(LIZeil,j+1,INTOBJ_INT(static_cast<Int>((*polymake_matrix)(i,j))));
|
||||
}
|
||||
SET_ELM_PLIST(RETLI,i+1,LIZeil);
|
||||
}
|
||||
diff --git a/PolymakeInterface/src/polymake_tropical.cpp b/PolymakeInterface/src/polymake_tropical.cpp
|
||||
index cf3134d0..3d26fc61 100644
|
||||
--- a/PolymakeInterface/src/polymake_tropical.cpp
|
||||
+++ b/PolymakeInterface/src/polymake_tropical.cpp
|
||||
@@ -11,7 +11,7 @@ Obj REAL_TROPICAL_HYPERSURFACE_BY_MONOMS_AND_COEFFICIENTS( Polymake_Data* data,
|
||||
}
|
||||
#endif
|
||||
|
||||
- int len = LEN_PLIST( monomials );
|
||||
+ Int len = LEN_PLIST( monomials );
|
||||
Obj akt = ELM_PLIST( monomials, 1 );
|
||||
Obj elem;
|
||||
|
||||
@@ -30,13 +30,13 @@ Obj REAL_TROPICAL_HYPERSURFACE_BY_MONOMS_AND_COEFFICIENTS( Polymake_Data* data,
|
||||
#endif
|
||||
|
||||
|
||||
- int len_elem = LEN_PLIST( akt );
|
||||
+ Int len_elem = LEN_PLIST( akt );
|
||||
data->main_polymake_session->set_application("tropical");
|
||||
|
||||
- polymake::Matrix<int> matr(len, len_elem);
|
||||
- polymake::Vector<int> coeff(len);
|
||||
+ polymake::Matrix<Int> matr(len, len_elem);
|
||||
+ polymake::Vector<Int> coeff(len);
|
||||
|
||||
- for(int i=1;i<=len;i++){
|
||||
+ for(Int i=1;i<=len;i++){
|
||||
akt = ELM_PLIST( monomials, i );
|
||||
#ifdef MORE_TESTS
|
||||
if( !IS_PLIST( akt ) ){
|
||||
@@ -49,7 +49,7 @@ Obj REAL_TROPICAL_HYPERSURFACE_BY_MONOMS_AND_COEFFICIENTS( Polymake_Data* data,
|
||||
}
|
||||
#endif
|
||||
|
||||
- for(int j = 1; j <= len_elem; j++){
|
||||
+ for(Int j = 1; j <= len_elem; j++){
|
||||
elem = ELM_PLIST( akt, j);
|
||||
|
||||
#ifdef MORE_TESTS
|
||||
@@ -94,7 +94,7 @@ Obj REAL_MONOMIALS_OF_HYPERSURFACE( Polymake_Data* data, Obj hypersurf){
|
||||
|
||||
perlobj* polyobj = PERLOBJ_POLYMAKEOBJ( hypersurf );
|
||||
data->main_polymake_session->set_application_of(*polyobj);
|
||||
- polymake::Matrix<int> matr;
|
||||
+ polymake::Matrix<Int> matr;
|
||||
try{
|
||||
polyobj->give("MONOMIALS") >> matr;
|
||||
}
|
Loading…
Reference in a new issue