Skip to content

Commit

Permalink
gfan: 0.7
Browse files Browse the repository at this point in the history
  • Loading branch information
mahrud committed Oct 20, 2024
1 parent 6bf95eb commit 34c688d
Showing 1 changed file with 26 additions and 36 deletions.
62 changes: 26 additions & 36 deletions Formula/gfan.rb
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
class Gfan < Formula
desc "Grobner fans and tropical varieties"
homepage "https://users-math.au.dk/~jensen/software/gfan/gfan.html"
url "https://users-math.au.dk/~jensen/software/gfan/gfan0.6.2.tar.gz"
sha256 "a674d5e5dc43634397de0d55dd5da3c32bd358d05f72b73a50e62c1a1686f10a"
url "https://users-math.au.dk/~jensen/software/gfan/gfan0.7.tar.gz"
sha256 "ab833757e1e4d4a98662f4aa691394013ea9a226f6416b8f8565356d6fcc989e"
license "GPL-2.0-or-later"
revision 11

bottle do
root_url "https://ghcr.io/v2/macaulay2/tap"
Expand All @@ -16,22 +15,11 @@ class Gfan < Formula
sha256 cellar: :any_skip_relocation, x86_64_linux: "2ac80a1fd89713e142750d8adf6f976e4249d38f58c5c2eafcfc0f6aec35793a"
end

if OS.mac?
depends_on "gcc" => :build
fails_with :clang
else
fails_with gcc: "4"
fails_with gcc: "5"
end
depends_on "gcc@14" => :build

depends_on "cddlib"
depends_on "gmp"

patch do
url "https://raw.githubusercontent.com/Macaulay2/M2/d51564127d757a3132684e9730f4085cb89297bb/M2/libraries/gfan/patch-0.6.2"
sha256 "9ebbf25e6de16baec877050bef69c85504e7bfa81e79407c2ab00ea4433e838c"
end

patch :DATA

def install

Check failure on line 25 in Formula/gfan.rb

View workflow job for this annotation

GitHub Actions / test-bot (macos-13)

`brew install --verbose --formula --build-bottle macaulay2/tap/gfan` failed on macOS Ventura (13)!

g++-14 -O2 -DGMPRATIONAL -DNDEBUG -I/usr/local/opt/cddlib/include/cddlib -g -I/usr/local/opt/gmp/include -g -DNOCDDPREFIX -std=c++2a -c src/lp.cpp -o src/lp.o g++-14 -O2 -DGMPRATIONAL -DNDEBUG -I/usr/local/opt/cddlib/include/cddlib -g -I/usr/local/opt/gmp/include -g -DNOCDDPREFIX -std=c++2a -c src/enumeration.cpp -o src/enumeration.o In file included from src/buchberger.cpp:17: In file included from src/divisionobject.h:22: In file included from src/gfanlib_tableau.h:14: src/gfanlib_circuittableint.h:617:12: error: implicit instantiation of undefined template 'gfan::MyMakeUnsigned<long long>' typename MyMakeUnsigned<longword>::type positiveResultBoundTimesD=extMul(negabs(s).v,boundA.v); ^ src/gfanlib_tableau.h:466:15: note: in instantiation of member function 'gfan::CircuitTableIntPOD<int, long long>::scaleVector' requested here mvtyp::scaleVector(&combinedMatrix[k][0],combinedMatrix[i][j],divisorObject,getWidth(),boundK) ^ src/gfanlib_tableau.h:554:20: note: in instantiation of member function 'gfan::Tableau<gfan::CircuitTableInt32>::exchange' requested here Tableau<mvtyp>::exchange(i,j); ^ src/gfanlib_tableau.h:1093:12: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::exchange' requested here this->exchange(i,j); ^ src/gfanlib_tableau.h:1722:5: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::findOrthogonalComplementAndDimension' requested here findOrthogonalComplementAndDimension(); ^ src/gfanlib_tableau.h:1889:4: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::ensureStateAsMinimum' requested here ensureStateAsMinimum(2); ^ src/gfanlib_tableau.h:2548:20: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::getGenericSupportingHyperplane' requested here return dualCone.getGenericSupportingHyperplane(mr); ^ src/divisionobject.h:676:28: note: in instantiation of member function 'gfan::Cone<gfan::CircuitTableInt32>::getRelativeInteriorPoint' requested here return toIntegerVector(C2.getRelativeInteriorPoint()); ^ src/gfanlib_circuittableint.h:25:29: note: template is declared here template<typename> struct MyMakeUnsigned; ^ src/gfanlib_circuittableint.h:430:12: error: implicit instantiation of undefined template 'gfan::MyMakeUnsigned<long long>' typename MyMakeUnsigned<longword>::type positiveResultBoundTimesD=extMul(negabs(s).v,boundA.v)+extMul(negabs(t).v,boundB.v); ^ src/gfanlib_tableau.h:468:15: note: in instantiation of member function 'gfan::CircuitTableIntPOD<int, long long>::dotDivVector' requested here mvtyp::dotDivVector(&combinedMatrix[k][0],&combinedMatrix[i][0],combinedMatrix[i][j],temp,divisorObject,getWidth(),boundK,boundI); ^ src/gfanlib_tableau.h:554:20: note: in instantiation of member function 'gfan::Tableau<gfan::CircuitTableInt32>::exchange' requested here Tableau<mvtyp>::exchange(i,j); ^ src/gfanlib_tableau.h:1093:12: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::exchange' requested here this->exchange(i,j); ^ src/gfanlib_tableau.h:1722:5: note: in instantiation of member function 'gfan::GeneratedCo

Check failure on line 25 in Formula/gfan.rb

View workflow job for this annotation

GitHub Actions / test-bot (macos-14)

`brew install --verbose --formula --build-bottle macaulay2/tap/gfan` failed on macOS Sonoma (14) on Apple Silicon!

g++-14 -O2 -DGMPRATIONAL -DNDEBUG -I/opt/homebrew/opt/cddlib/include/cddlib -g -I/opt/homebrew/opt/gmp/include -g -DNOCDDPREFIX -std=c++2a -c src/wallideal.cpp -o src/wallideal.o g++-14 -O2 -DGMPRATIONAL -DNDEBUG -I/opt/homebrew/opt/cddlib/include/cddlib -g -I/opt/homebrew/opt/gmp/include -g -DNOCDDPREFIX -std=c++2a -c src/lp.cpp -o src/lp.o In file included from src/buchberger.cpp:17: In file included from src/divisionobject.h:22: In file included from src/gfanlib_tableau.h:14: src/gfanlib_circuittableint.h:617:12: error: implicit instantiation of undefined template 'gfan::MyMakeUnsigned<long long>' typename MyMakeUnsigned<longword>::type positiveResultBoundTimesD=extMul(negabs(s).v,boundA.v); ^ src/gfanlib_tableau.h:466:15: note: in instantiation of member function 'gfan::CircuitTableIntPOD<int, long long>::scaleVector' requested here mvtyp::scaleVector(&combinedMatrix[k][0],combinedMatrix[i][j],divisorObject,getWidth(),boundK) ^ src/gfanlib_tableau.h:554:20: note: in instantiation of member function 'gfan::Tableau<gfan::CircuitTableInt32>::exchange' requested here Tableau<mvtyp>::exchange(i,j); ^ src/gfanlib_tableau.h:1093:12: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::exchange' requested here this->exchange(i,j); ^ src/gfanlib_tableau.h:1722:5: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::findOrthogonalComplementAndDimension' requested here findOrthogonalComplementAndDimension(); ^ src/gfanlib_tableau.h:1889:4: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::ensureStateAsMinimum' requested here ensureStateAsMinimum(2); ^ src/gfanlib_tableau.h:2548:20: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::getGenericSupportingHyperplane' requested here return dualCone.getGenericSupportingHyperplane(mr); ^ src/divisionobject.h:676:28: note: in instantiation of member function 'gfan::Cone<gfan::CircuitTableInt32>::getRelativeInteriorPoint' requested here return toIntegerVector(C2.getRelativeInteriorPoint()); ^ src/gfanlib_circuittableint.h:25:29: note: template is declared here template<typename> struct MyMakeUnsigned; ^ src/gfanlib_circuittableint.h:430:12: error: implicit instantiation of undefined template 'gfan::MyMakeUnsigned<long long>' typename MyMakeUnsigned<longword>::type positiveResultBoundTimesD=extMul(negabs(s).v,boundA.v)+extMul(negabs(t).v,boundB.v); ^ src/gfanlib_tableau.h:468:15: note: in instantiation of member function 'gfan::CircuitTableIntPOD<int, long long>::dotDivVector' requested here mvtyp::dotDivVector(&combinedMatrix[k][0],&combinedMatrix[i][0],combinedMatrix[i][j],temp,divisorObject,getWidth(),boundK,boundI); ^ src/gfanlib_tableau.h:554:20: note: in instantiation of member function 'gfan::Tableau<gfan::CircuitTableInt32>::exchange' requested here Tableau<mvtyp>::exchange(i,j); ^ src/gfanlib_tableau.h:1093:12: note: in instantiation of member function 'gfan::GeneratedCone<gfan::CircuitTableInt32>::exchange' requested here this->exchange(i,j); ^ src/gfanlib_tableau.h:1722:5: note: in instantiation of member function 'gfan::Gen

Check failure on line 25 in Formula/gfan.rb

View workflow job for this annotation

GitHub Actions / test-bot (macos-15)

`brew install --verbose --formula --build-bottle macaulay2/tap/gfan` failed on macOS Sequoia (15) on Apple Silicon!

In file included from src/buchberger.cpp:17: In file included from src/divisionobject.h:21: In file included from src/gfanlibglue.h:14: In file included from src/gfanlib.h:12: In file included from src/gfanlib_vector.h:17: src/gfanlib_memoryresource.h:9:10: fatal error: 'experimental/memory_resource' file not found 9 | #include <experimental/memory_resource> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 error generated. make: *** [src/buchberger.o] Error 1 make: *** Waiting for unfinished jobs.... ==> Formula Tap: macaulay2/tap Path: /opt/homebrew/Library/Taps/macaulay2/homebrew-tap/Formula/gfan.rb ==> Configuration HOMEBREW_VERSION: 4.4.1-64-gd0ab3d3 ORIGIN: https://github.com/Homebrew/brew HEAD: d0ab3d3bc881291b00d2fc9a598d851b2726885d Last commit: 3 hours ago Core tap HEAD: db9a843066d27d7217ab0e813b17a7f6c880af52 Core tap last commit: 7 days ago Core tap JSON: 20 Oct 21:03 UTC Core cask tap HEAD: c0fd9d20c432ea2470b6f46415cce46ced667348 Core cask tap last commit: 7 days ago Core cask tap JSON: 20 Oct 21:03 UTC HOMEBREW_PREFIX: /opt/homebrew HOMEBREW_CACHE: /Users/runner/Library/Caches/Homebrew HOMEBREW_CASK_OPTS: ["--no-quarantine"] HOMEBREW_COLOR: set HOMEBREW_CURL_PATH: /usr/bin/curl HOMEBREW_FAIL_LOG_LINES: 150 HOMEBREW_GITHUB_API_TOKEN: set HOMEBREW_GIT_EMAIL: [email protected] HOMEBREW_GIT_NAME: BrewTestBot HOMEBREW_GIT_PATH: /usr/bin/git HOMEBREW_LOGS: /Users/runner/work/homebrew-tap/homebrew-tap/logs HOMEBREW_MAKE_JOBS: 3 HOMEBREW_NO_AUTO_UPDATE: set HOMEBREW_NO_EMOJI: set HOMEBREW_NO_ENV_HINTS: set HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK: set HOMEBREW_NO_INSTALL_CLEANUP: set HOMEBREW_SORBET_RUNTIME: set Homebrew Ruby: 3.3.5 => /opt/homebrew/Library/Homebrew/vendor/portable-ruby/3.3.5/bin/ruby CPU: 3-core 64-bit dunno Clang: 16.0.0 build 1600 Git: 2.39.5 => /usr/bin/git Curl: 8.7.1 => /usr/bin/curl macOS: 15.0-arm64 CLT: 16.0.0.0.1.1724870825 Xcode: 16.0 => /Applications/Xcode_16.app/Contents/Developer Rosetta 2: false ==> ENV HOMEBREW_CC: clang HOMEBREW_CXX: clang++ MAKEFLAGS: -j3 CMAKE_PREFIX_PATH: /opt/homebrew CMAKE_INCLUDE_PATH: /Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers CMAKE_LIBRARY_PATH: /Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries PKG_CONFIG_PATH: /opt/homebrew/opt/gmp/lib/pkgconfig:/opt/homebrew/opt/cddlib/lib/pkgconfig PKG_CONFIG_LIBDIR: /usr/lib/pkgconfig:/opt/homebrew/Library/Homebrew/os/mac/pkgconfig/15 HOMEBREW_MAKE_JOBS: 3 HOMEBREW_GIT: /usr/bin/git HOMEBREW_SDKROOT: /Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk PATH: /opt/homebrew/Library/Homebrew/shims/mac/super:/opt/homebrew/opt/gcc/bin:/opt/homebrew/opt/cddlib/bin:/usr/bin:/bin:/usr/sbin:/sbin Logs: /Users/runner/work/homebrew-tap/homebrew-tap/logs/gfan/00.options.out /Users/runner/work/homebrew-tap/homebrew-tap/logs/gfan/01.make /Users/runner/work/homebrew-tap/homebrew-tap/logs/gfan/01.make.cc If reporting this issue please do so at (not Homebrew/brew or Homebrew/homebrew-core): https://github.com/macaulay2/homebrew-tap/issues ::error::macaulay2/tap/gfan 0.7 did not build
Expand All @@ -57,31 +45,33 @@ def install

__END__

diff --git a/Makefile-orig b/Makefile
index 737208abfb..52e010e0b3 100644
diff --git a/Makefile b/Makefile
index 67c8164..ab0b9c6 100644
--- a/Makefile
+++ b/Makefile
@@ -110,15 +110,15 @@ MKDIR=mkdir -p
PREFIX =
@@ -117,9 +117,9 @@ PREFIX =
SHELL = /bin/sh
#ARCH = LINUX

-CC = $(PREFIX)gcc
-CLINKER = $(CC)
+CC = $(PREFIX)gcc-14
CLINKER = $(CC)
-CXX = $(PREFIX)g++
-CCLINKER = $(CXX)
+#CC = $(PREFIX)gcc
+#CLINKER = $(CC)
+#CXX = $(PREFIX)g++
+#CCLINKER = $(CXX)
#OPTFLAGS = -O2 -DGMPRATIONAL -DNDEBUG
# Note that gcc produces wrong code with -O3
-OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O2 #-O3 -fno-guess-branch-probability #-DNDEBUG
+#OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O2 #-O3 -fno-guess-branch-probability #-DNDEBUG
#OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O3 -mavx -msse2 -finline-limit=1000 -ffast-math -Wuninitialized # -fno-guess-branch-probability #-DNDEBUG -ftree-vectorizer-verbose=2
-#OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O1 -fno-guess-branch-probability
+OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O1 -fno-guess-branch-probability
#-DNDEBUG
#OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O3 -mavx -msse2 -ftree-vectorizer-verbose=2 -finline-limit=1000 -ffast-math #-DNDEBUG
#OPTFLAGS = -DGMPRATIONAL -Wuninitialized -fno-omit-frame-pointer -O3 -mavx -msse2 -ftree-vectorizer-verbose=2 -march=native -unroll-loops --param max-unroll-times=4 -ffast-math #-DNDEBUG
+CXX = $(PREFIX)g++-14
CCLINKER = $(CXX)

#CC = $(PREFIX)gcc-8.1
diff --git a/src/gfanlib_z.h b/src/gfanlib_z.h
index f56597c..8c84ed1 100644
--- a/src/gfanlib_z.h
+++ b/src/gfanlib_z.h
@@ -9,6 +9,7 @@
#define LIB_Z_H_

#include <string.h>
+#include <cstdint>
#include <ostream>
#include <iostream>
#define OLD 1
--
2.31.1
2.46.0

0 comments on commit 34c688d

Please sign in to comment.