From 5a776c13fd5e3f135040783d8c86a5d9870ede9c Mon Sep 17 00:00:00 2001 From: Jerry James Date: Mar 11 2015 14:21:40 +0000 Subject: Update URLs. Also: - Link with $RPM_LD_FLAGS. - Reenable tests. --- diff --git a/gfan-warning.patch b/gfan-warning.patch index 066ab65..7b5970b 100644 --- a/gfan-warning.patch +++ b/gfan-warning.patch @@ -1,3 +1,47 @@ +--- ./app_fancoarsening.cpp.orig 2011-01-25 08:33:15.000000000 -0700 ++++ ./app_fancoarsening.cpp 2012-01-09 11:27:29.299438352 -0700 +@@ -33,12 +33,14 @@ public: + return false; + } + ++#if 0 + IntegerVectorList inequalitiesForCone(IntegerVector const &codim1interior, IntegerVector const &newDirection) + { + + int i=0; + + } ++#endif + + const char *helpText() + { +--- ./application.cpp.orig 2011-01-25 08:33:16.000000000 -0700 ++++ ./application.cpp 2012-01-09 11:27:29.312437096 -0700 +@@ -3,6 +3,8 @@ + #include + #include + #include ++#include ++#include + #include + #include + +@@ -546,10 +548,11 @@ void Application::makeSymbolicLinks(cons + if(all || p->includeInDefaultInstallation()) + if(strlen(p->name())>0) + { +- char c[1024]; +- sprintf(c,"ln -s %s%s %s%s%s\n",path,name,path,name,p->name()); +- fprintf(stderr,"%s",c); +- system(c); ++ char c[PATH_MAX], d[PATH_MAX]; ++ snprintf(c,PATH_MAX,"%s%s",path,name); ++ snprintf(d,PATH_MAX,"%s%s%s",path,name,p->name()); ++ fprintf(stderr,"ln -s %s %s\n",c,d); ++ symlink(c,d); + } + p=p->next; + } --- ./app_minkowski.cpp.orig 2011-01-25 08:33:15.000000000 -0700 +++ ./app_minkowski.cpp 2012-01-09 11:28:20.926240318 -0700 @@ -160,7 +160,7 @@ public: @@ -9,8 +53,8 @@ //log0 fprintf(Stderr,"inserted:%i\n",++i); } log1 fprintf(Stderr,"Resolving symmetries.\n"); ---- ./app_test.cpp.orig 2011-01-25 08:33:15.000000000 -0700 -+++ ./app_test.cpp 2012-01-09 11:27:29.305437764 -0700 +--- ./app_test.cpp.orig 2011-04-27 13:49:04.826968542 -0600 ++++ ./app_test.cpp 2015-03-10 16:40:15.157574168 -0600 @@ -1,5 +1,7 @@ #include #include @@ -62,16 +106,6 @@ return ret; } ---- ./gfanlib_vector.h.orig 2011-01-25 08:33:18.000000000 -0700 -+++ ./gfanlib_vector.h 2012-01-09 11:27:29.307437580 -0700 -@@ -288,6 +288,7 @@ public: - f<<*i; - } - f<<")"; -+ return f; - } - typ gcd()const - { --- ./app_tropicalintersection.cpp.orig 2011-01-25 08:33:15.000000000 -0700 +++ ./app_tropicalintersection.cpp 2012-01-09 11:27:29.304437850 -0700 @@ -42,6 +42,7 @@ public: @@ -82,33 +116,25 @@ } }; ---- ./application.cpp.orig 2011-01-25 08:33:16.000000000 -0700 -+++ ./application.cpp 2012-01-09 11:27:29.312437096 -0700 -@@ -3,6 +3,8 @@ - #include - #include - #include -+#include -+#include - #include - #include +--- ./enumeration.h.orig 2011-01-25 08:33:17.000000000 -0700 ++++ ./enumeration.h 2015-03-10 16:48:12.249941222 -0600 +@@ -36,7 +36,7 @@ class EnumerationFilePrinter: public Enu + FILE *file; + public: + EnumerationFilePrinter(); +- ~EnumerationFilePrinter(); ++ virtual ~EnumerationFilePrinter(); -@@ -546,10 +548,11 @@ void Application::makeSymbolicLinks(cons - if(all || p->includeInDefaultInstallation()) - if(strlen(p->name())>0) - { -- char c[1024]; -- sprintf(c,"ln -s %s%s %s%s%s\n",path,name,path,name,p->name()); -- fprintf(stderr,"%s",c); -- system(c); -+ char c[PATH_MAX], d[PATH_MAX]; -+ snprintf(c,PATH_MAX,"%s%s",path,name); -+ snprintf(d,PATH_MAX,"%s%s%s",path,name,p->name()); -+ fprintf(stderr,"ln -s %s %s\n",c,d); -+ symlink(c,d); - } - p=p->next; - } + void open(std::string filename); + void open(FILE *file); +@@ -61,6 +61,7 @@ class EnumerationAlgorithm + bool targetBasis(const PolynomialSet &groebnerBasis){bool ret=true;if(target)ret=target->basis(groebnerBasis);printProgress();return ret;} + public: + EnumerationAlgorithm(){target=0;progressCounter=0;} ++ virtual ~EnumerationAlgorithm(){} + void setEnumerationTarget(EnumerationTarget *target){this->target=target;} + virtual void enumerate(const PolynomialSet &groebnerBasis){} + }; --- ./field_rationals.cpp.orig 2011-01-25 08:33:16.000000000 -0700 +++ ./field_rationals.cpp 2012-01-09 11:27:29.300438251 -0700 @@ -326,17 +326,17 @@ const char *FieldRationalsImplementation @@ -132,17 +158,37 @@ //FieldRationals Q; Field Q(new FieldRationalsImplementation()); ---- ./vektor.cpp.orig 2011-01-25 08:33:17.000000000 -0700 -+++ ./vektor.cpp 2012-01-09 11:27:29.303437946 -0700 -@@ -96,7 +96,7 @@ int gcdGFAN(int r, int s) - int gcdOfVector(IntegerVector const &v) +--- ./gfanapplication.cpp.orig 2011-01-25 08:33:16.000000000 -0700 ++++ ./gfanapplication.cpp 2015-03-10 16:41:48.563450249 -0600 +@@ -51,7 +51,7 @@ GFanApplication::StdinFileOption::StdinF + + void GFanApplication::StdinFileOption::onOptionsParsed() { - int ret=0; -- for(int i=0;i0)freopen(getValue(),"r",stdin); ++ if(strlen(getValue())>0)stdin=freopen(getValue(),"r",stdin); + } + + GFanApplication::StdoutFileOption::StdoutFileOption(): +@@ -62,7 +62,7 @@ GFanApplication::StdoutFileOption::Stdou + + void GFanApplication::StdoutFileOption::onOptionsParsed() + { +- if(strlen(getValue())>0)freopen(getValue(),"w",stdout); ++ if(strlen(getValue())>0)stdout=freopen(getValue(),"w",stdout); + } + + +--- ./gfanlib_polymakefile.cpp.orig 2011-01-25 08:33:16.000000000 -0700 ++++ ./gfanlib_polymakefile.cpp 2012-01-09 11:27:29.306437673 -0700 +@@ -51,7 +51,7 @@ static list readIntList(istream &s) + { + list ret; + int c=s.peek(); +- while((c>='0') && (c<='9')|| (c==' ')) ++ while((c>='0' && c<='9')|| c==' ') + { + // fprintf(Stderr,"?\n"); + int r; --- ./gfanlib_symmetriccomplex.cpp.orig 2011-01-25 08:33:16.000000000 -0700 +++ ./gfanlib_symmetriccomplex.cpp 2012-01-09 11:27:29.311437193 -0700 @@ -215,13 +215,12 @@ bool SymmetricComplex::isMaximal(Cone co @@ -169,6 +215,26 @@ void SymmetricComplex::buildConeLists(bool onlyMaximal, bool compressed, std::vector >*conelist/*, ZMatrix *multiplicities*/)const { +--- ./gfanlib_vector.h.orig 2011-01-25 08:33:18.000000000 -0700 ++++ ./gfanlib_vector.h 2012-01-09 11:27:29.307437580 -0700 +@@ -288,6 +288,7 @@ public: + f<<*i; + } + f<<")"; ++ return f; + } + typ gcd()const + { +--- ./gfanlib_zcone.cpp.orig 2011-01-25 08:33:16.000000000 -0700 ++++ ./gfanlib_zcone.cpp 2012-01-09 11:27:29.309437387 -0700 +@@ -726,6 +726,7 @@ std::ostream &operator<<(std::ostream &f + f< readIntList(istream &s) @@ -180,44 +246,17 @@ { // fprintf(Stderr,"?\n"); int r; ---- ./app_fancoarsening.cpp.orig 2011-01-25 08:33:15.000000000 -0700 -+++ ./app_fancoarsening.cpp 2012-01-09 11:27:29.299438352 -0700 -@@ -33,12 +33,14 @@ public: - return false; - } - -+#if 0 - IntegerVectorList inequalitiesForCone(IntegerVector const &codim1interior, IntegerVector const &newDirection) - { - - int i=0; - - } -+#endif - - const char *helpText() - { ---- ./gfanlib_polymakefile.cpp.orig 2011-01-25 08:33:16.000000000 -0700 -+++ ./gfanlib_polymakefile.cpp 2012-01-09 11:27:29.306437673 -0700 -@@ -51,7 +51,7 @@ static list readIntList(istream &s) +--- ./vektor.cpp.orig 2011-01-25 08:33:17.000000000 -0700 ++++ ./vektor.cpp 2012-01-09 11:27:29.303437946 -0700 +@@ -96,7 +96,7 @@ int gcdGFAN(int r, int s) + int gcdOfVector(IntegerVector const &v) { - list ret; - int c=s.peek(); -- while((c>='0') && (c<='9')|| (c==' ')) -+ while((c>='0' && c<='9')|| c==' ') - { - // fprintf(Stderr,"?\n"); - int r; ---- ./gfanlib_zcone.cpp.orig 2011-01-25 08:33:16.000000000 -0700 -+++ ./gfanlib_zcone.cpp 2012-01-09 11:27:29.309437387 -0700 -@@ -726,6 +726,7 @@ std::ostream &operator<<(std::ostream &f - f< - 0.5-12 +- Update URLs +- Link with RPM_LD_FLAGS +- Reenable tests + * Tue Feb 17 2015 Jerry James - 0.5-11 - Use license macro