Jerry James 74d8a20
--- ./apps/polytope/src/Makefile.inc.orig	2014-01-17 12:40:57.000000000 -0700
Jerry James 74d8a20
+++ ./apps/polytope/src/Makefile.inc	2014-01-17 14:57:44.958255450 -0700
4ad1335
@@ -1,12 +1,12 @@
4ad1335
 ifeq (${ExtensionTop},)
4ad1335
   StaticLibs := cdd lrs
Jerry James ba7c267
 
Jerry James ba7c267
-  lrs_interface$O : ExtraCXXFLAGS = -I$(ProjectTop)/external/lrs
4ad1335
-  cdd_interface$O : ExtraCXXFLAGS = -I$(ProjectTop)/external/cdd/lib-src-gmp $(call addinclude, $(ProjectTop)/staticlib/cdd/globals_gmp.h)
Jerry James ba7c267
-  cdd_float_interface$O : ExtraCXXFLAGS = -I$(ProjectTop)/external/cdd/lib-src
Jerry James ba7c267
+  lrs_interface$O : ExtraCXXFLAGS = -I/usr/include/lrslib
4ad1335
+  cdd_interface$O : ExtraCXXFLAGS = -I/usr/include/cddlib $(call addinclude, $(ProjectTop)/staticlib/cdd/globals_gmp.h)
Jerry James ba7c267
+  cdd_float_interface$O : ExtraCXXFLAGS = -I/usr/include/cddlib
4ad1335
   to_interface$O : ExtraCXXFLAGS = -I$(ProjectTop)/external/TOSimplex
Jerry James ba7c267
 
4ad1335
-  LIBS += $(BuildDir)/staticlib/lrs/liblrsgmp$A $(BuildDir)/staticlib/cdd/libcddgmp$A $(BuildDir)/staticlib/cdd/libcdd$A
4ad1335
+  LIBS += -llrsgmp -lcddgmp -lcdd
Jerry James ba7c267
 endif
Jerry James ba7c267
 
4ad1335
 ifneq ($(filter 4.4% 4.5%,${GCCversion}),)
Jerry James 74d8a20
--- ./bundled/group/apps/polytope/src/Makefile.inc.orig	2014-01-17 12:40:59.000000000 -0700
Jerry James 74d8a20
+++ ./bundled/group/apps/polytope/src/Makefile.inc	2014-01-17 14:57:44.958255450 -0700
Jerry James 74d8a20
@@ -1,14 +1,10 @@
4ad1335
 ifeq (${ImportedIntoExtension},)
4ad1335
   StaticLibs := sympol
4ad1335
 
4ad1335
-  sympol_interface$O : ExtraCXXFLAGS += -I${ExtensionTop}/external/sympol
4ad1335
-  sympol_raycomputation_beneathbeyond$O : ExtraCXXFLAGS += -I${ExtensionTop}/external/sympol
Jerry James 74d8a20
-
Jerry James 74d8a20
-  LIBS += ${BuildDir}/staticlib/sympol/libsympol$A ${BuildDir}/../../staticlib/cdd/libcddgmp$A
Jerry James 74d8a20
-endif
4ad1335
+  sympol_interface$O : ExtraCXXFLAGS += -I/usr/include/sympol
4ad1335
+  sympol_raycomputation_beneathbeyond$O : ExtraCXXFLAGS += -I/usr/include/sympol
4ad1335
 
Jerry James 74d8a20
-ifneq ($(filter 4.4%,${GCCversion}),)
Jerry James 74d8a20
-  universal_polytope_ilps$O : ExtraCXXFLAGS += -O1
4ad1335
+  LIBS += -lsympol -lcddgmp
Jerry James ba7c267
 endif
4ad1335
 
4ad1335
 # Local Variables:
Jerry James 74d8a20
--- ./bundled/group/configure.pl.orig	2014-01-17 12:40:59.000000000 -0700
Jerry James 74d8a20
+++ ./bundled/group/configure.pl	2014-01-17 14:57:44.958255450 -0700
4ad1335
@@ -29,7 +29,7 @@ sub proceed {
4ad1335
    my ($options)=@_;
4ad1335
    my $boost_path;
4ad1335
    # everything can include permlib headers
4ad1335
-   $CXXflags='-I${ExtensionTop}/external/permlib/include';
4ad1335
+   $CXXflags='-I/usr/include/permlib';
4ad1335
 
4ad1335
    if (defined ($boost_path=$options->{boost})) {
4ad1335
       $boost_path .= '/include' if (-d "$boost_path/include/boost");
Jerry James 74d8a20
--- ./bundled/group/staticlib/sympol/Makefile.inc.orig	2014-01-17 12:40:59.000000000 -0700
Jerry James 74d8a20
+++ ./bundled/group/staticlib/sympol/Makefile.inc	2014-01-17 14:57:44.959255521 -0700
4ad1335
@@ -4,7 +4,7 @@ src := $(ExtensionTop)/external/sympol/s
4ad1335
 
4ad1335
 vpath %.cpp $(src)
4ad1335
 
4ad1335
-libsympol : ExtraCXXFLAGS := -I$(ExtensionTop)/external/permlib/include -I$(ExtensionTop)/external/sympol/sympol -I$(ProjectTop)/external/lrs -DGMP -DLRS_QUIET -DGMPRATIONAL -I$(ProjectTop)/external/cdd/lib-src-gmp $(call addinclude, $(ProjectTop)/staticlib/cdd/globals_gmp.h)
4ad1335
+libsympol : ExtraCXXFLAGS := -I/usr/include/permlib -I/usr/include/sympol -I/usr/include/lrslib -DGMP -DLRS_QUIET -DGMPRATIONAL -I/usr/include/cddlib $(call addinclude, $(ProjectTop)/staticlib/cdd/globals_gmp.h)
4ad1335
 
4ad1335
 # Local Variables:
4ad1335
 # mode: Makefile
Jerry James 74d8a20
--- ./bundled/libnormaliz/apps/polytope/src/Makefile.inc.orig	2014-01-17 12:40:58.000000000 -0700
Jerry James 74d8a20
+++ ./bundled/libnormaliz/apps/polytope/src/Makefile.inc	2014-01-17 15:29:22.981405715 -0700
Jerry James 74d8a20
@@ -1,4 +1,5 @@
Jerry James 74d8a20
-  ExtraCXXFLAGS = -I$(ExtensionTop)/external/libnormaliz
Jerry James 74d8a20
+  ExtraCXXFLAGS = -I/usr/include/libnormaliz
Jerry James 74d8a20
+  LIBS += -lnormaliz
Jerry James 74d8a20
 
Jerry James 74d8a20
 # Local Variables:
Jerry James 74d8a20
 # mode: Makefile
Jerry James 74d8a20
--- ./bundled/libnormaliz/apps/polytope/src/normaliz.cc.orig	2014-01-17 12:40:58.000000000 -0700
Jerry James 74d8a20
+++ ./bundled/libnormaliz/apps/polytope/src/normaliz.cc	2014-01-17 15:55:35.601204574 -0700
Jerry James 74d8a20
@@ -40,7 +40,7 @@ namespace libnormaliz {
Jerry James 74d8a20
 
Jerry James 74d8a20
 }
Jerry James 74d8a20
 
Jerry James 74d8a20
-#include "libnormaliz-all.cpp"
Jerry James 74d8a20
+#include <libnormaliz/cone.h>
Jerry James 74d8a20
 
Jerry James 74d8a20
 namespace polymake { namespace polytope {
Jerry James 74d8a20
 
Jerry James 74d8a20
--- ./perl/polymake-config.orig	2014-01-17 12:40:55.000000000 -0700
Jerry James 74d8a20
+++ ./perl/polymake-config	2014-01-17 14:57:44.959255521 -0700
Jerry James 74d8a20
@@ -126,9 +126,6 @@ while (defined ($_=shift)) {
Jerry James 74d8a20
 
Jerry James 74d8a20
    } elsif ($_ eq "--ldflags") {
Jerry James 74d8a20
       my $ldflags=$conf{LDflags};
Jerry James 74d8a20
-      if ($ldflags !~ /(?:^|\s)-L$conf{InstallLib}(?:\s|$)/) {
Jerry James 74d8a20
-         $ldflags="-L$conf{InstallLib} $ldflags";
Jerry James 74d8a20
-      }
Jerry James 74d8a20
       my $add_rpath=1;
Jerry James 74d8a20
       open CF, ">$tmpfile.cc" or die "can't create temporary file $tmpfile.cc: $!\n";
Jerry James 74d8a20
       print CF "int main() { return 0; }\n";
Jerry James 74d8a20
@@ -146,8 +143,6 @@ while (defined ($_=shift)) {
Jerry James 74d8a20
       close CC;
Jerry James 74d8a20
       if ($^O eq "darwin") {
Jerry James 74d8a20
          $ldflags="$conf{ARCHFLAGS} $ldflags -flat_namespace";
Jerry James 74d8a20
-      } elsif ($add_rpath) {
Jerry James 74d8a20
-         $ldflags.=" -Wl,-rpath,$conf{InstallLib}";
Jerry James 74d8a20
       }
Jerry James 74d8a20
       $ldflags=~s/^\s+//; $ldflags=~s/\s+$//; $ldflags=~s/\s{2,}/ /g;
Jerry James 74d8a20
       if ($debug_asked=defined($debug)) {
Jerry James 74d8a20
--- ./staticlib/cdd/Makefile.inc.orig	2014-01-17 12:40:59.000000000 -0700
98bd214
+++ ./staticlib/cdd/Makefile.inc	2014-03-31 12:00:00.000000000 -0700
Jerry James 74d8a20
@@ -1,6 +1,3 @@
Jerry James 74d8a20
-OwnLibraries := libcdd libcddgmp
Jerry James 74d8a20
-LibModules := cddio cddmp cddlib cddcore cddlp cddproj setoper
Jerry James 74d8a20
-
Jerry James 74d8a20
 ExtraCFLAGS := -fvisibility=hidden 
Jerry James 74d8a20
 
98bd214
 ifeq "$(OwnLibraries)" "libcdd"
98bd214
@@ -8,8 +5,6 @@ ifeq "$(OwnLibraries)" "libcdd"
Jerry James 74d8a20
 else
Jerry James 74d8a20
   src := $(ProjectTop)/external/cdd/lib-src-gmp
Jerry James 74d8a20
 
Jerry James 74d8a20
-  LibModules := $(LibModules) $(patsubst cdd%,cdd%_f,$(LibModules))
Jerry James 74d8a20
-
Jerry James 74d8a20
   $(addsuffix $(LO), $(LibModules)) : $(SourceDir)/globals_gmp.h
Jerry James 74d8a20
 
Jerry James 74d8a20
   libcddgmp : ExtraCFLAGS += -DGMPRATIONAL $(call addinclude, $(SourceDir)/globals_gmp.h)
Jerry James 74d8a20
--- ./staticlib/lrs/Makefile.inc.orig	2014-01-17 12:40:59.000000000 -0700
Jerry James 74d8a20
+++ ./staticlib/lrs/Makefile.inc	2014-01-17 14:57:44.960255584 -0700
Jerry James 74d8a20
@@ -1,5 +1,3 @@
Jerry James 74d8a20
-OwnLibraries := liblrsgmp
Jerry James 74d8a20
-LibModules := lrslib lrsgmp
Jerry James 74d8a20
 src := $(ProjectTop)/external/lrs
Jerry James 74d8a20
 vpath %.c $(src)
Jerry James 74d8a20
 
Jerry James 74d8a20
--- ./support/configure.pl.orig	2014-01-17 12:40:58.000000000 -0700
Jerry James 74d8a20
+++ ./support/configure.pl	2014-01-17 14:57:44.960255584 -0700
4ad1335
@@ -372,7 +372,7 @@ if (defined $CC) {
4ad1335
 print "ok ($CXX is ", defined($GCCversion) ? "GCC $GCCversion" : defined($CLANGversion) ? "CLANG $CLANGversion" : "ICC $ICCversion", ")\n";
4ad1335
 
4ad1335
 $PERL     =$vars{PERL}     || $^X;
4ad1335
-$CXXOPT   =$vars{CXXOPT}   || "-O3";
4ad1335
+$CXXOPT   =$vars{CXXOPT}   || "-O2";
4ad1335
 $CXXDEBUG =$vars{CXXDEBUG} || "";
4ad1335
 $Cflags   =$vars{CFLAGS}   || "";
4ad1335
 $CXXflags =$vars{CXXFLAGS} || $Cflags;
4ad1335
@@ -557,10 +557,6 @@ if (defined $GMP) {
Jerry James ba7c267
    $CXXflags .= " -I$GMP/include";
Jerry James ba7c267
    my $libdir=get_libdir($GMP, "gmp");
Jerry James ba7c267
    $LDflags .= " -L$libdir";
4ad1335
-   if (($^O ne "darwin" || $options{fink} eq ".none.") && exists $options{gmp}) {
Jerry James ba7c267
-      # non-standard location
Jerry James ba7c267
-      $LDflags .= " -Wl,-rpath,$libdir";
Jerry James ba7c267
-   }
Jerry James ba7c267
 }
Jerry James ba7c267
 
Jerry James ba7c267
 my $MPFR=$options{mpfr};
4ad1335
@@ -569,10 +565,6 @@ if (defined($MPFR) && $MPFR ne $GMP) {
Jerry James ba7c267
    $CXXflags .= " -I$MPFR/include";
Jerry James ba7c267
    my $libdir=get_libdir($MPFR, "mpfr");
Jerry James ba7c267
    $LDflags .= " -L$libdir";
4ad1335
-   if ($^O ne "darwin" || $options{fink} eq ".none.") {
Jerry James ba7c267
-      # non-standard location
Jerry James ba7c267
-      $LDflags .= " -Wl,-rpath,$libdir";
Jerry James ba7c267
-   }
Jerry James ba7c267
 }
Jerry James ba7c267
 
4ad1335
 if ($check_prereq) {