Skip to content

Commit 9782e9b

Browse files
Merge pull request #19 from mohamed-barakat/4ti2
Fix use of lib4ti2_jll
2 parents 360a65d + 0671701 commit 9782e9b

File tree

8 files changed

+47
-7
lines changed

8 files changed

+47
-7
lines changed

.travis.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ env:
1919
dist: bionic
2020

2121
before_install:
22-
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo apt-get update; sudo apt-get install -y libglpk-dev; fi
23-
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew update; brew install glpk; fi
22+
# - if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo apt-get update; fi # sudo apt-get install -y libglpk-dev;
23+
# - if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew update; fi # brew install glpk;
2424

2525
script:
2626
- travis_wait 60 julia --color=yes -e 'using Pkg;

Project.toml

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ authors = ["Mohamed Barakat <[email protected]>"]
44
version = "0.4.0"
55

66
[deps]
7+
BinaryProvider = "b99e7846-7c00-51b0-8f62-c81ae34c0232"
78
GAP = "c863536a-3901-11e9-33e7-d5cd0df7b904"
89
Singular = "bcd08a7b-43d2-5ff7-b6d4-c458787f915c"
910
lib4ti2_jll = "1493ae25-0f90-5c0e-a06c-8c5077d6d66f"

deps/usr/bin/graver

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
# graver
3+
julia -e 'import lib4ti2_jll
4+
lib4ti2_jll.zsolve() do x
5+
p=run(ignorestatus(`$x -G $ARGS`))
6+
exit(p.exitcode)
7+
end' -- "$@"

deps/usr/bin/groebner

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
# groebner
3+
julia -e 'import lib4ti2_jll
4+
lib4ti2_jll.exe4ti2gmp() do x
5+
p=run(ignorestatus(`$x groebner $ARGS`))
6+
exit(p.exitcode)
7+
end' -- "$@"

deps/usr/bin/hilbert

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
# hilbert
3+
julia -e 'import lib4ti2_jll
4+
lib4ti2_jll.zsolve() do x
5+
p=run(ignorestatus(`$x -H $ARGS`))
6+
exit(p.exitcode)
7+
end' -- "$@"

deps/usr/bin/markov

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
# markov
3+
julia -e 'import lib4ti2_jll
4+
lib4ti2_jll.exe4ti2gmp() do x
5+
p=run(ignorestatus(`$x markov $ARGS`))
6+
exit(p.exitcode)
7+
end' -- "$@"

deps/usr/bin/zsolve

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
# graver
3+
julia -e 'import lib4ti2_jll
4+
lib4ti2_jll.zsolve() do x
5+
p=run(ignorestatus(`$x $ARGS`))
6+
exit(p.exitcode)
7+
end' -- "$@"

src/HomalgProject.jl

+9-5
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,6 @@ import Singular.libSingular: call_interpreter
7474

7575
export call_interpreter
7676

77-
import lib4ti2_jll
78-
7977
import Pkg
8078
import Markdown
8179

@@ -98,7 +96,13 @@ include("../deps/homalg-project.jl")
9896

9997
global SINGULAR_PATH = dirname(dirname(pathof(Singular)))
10098

101-
global HOMALG_EXTRA_PATHS = [ lib4ti2_jll.PATH_list ]
99+
global HOMALG_PATHS = [ ]
100+
101+
## $(HOMALG_PROJECT_PATH)/deps/usr/bin should be the last entry
102+
HOMALG_PATHS = vcat( HOMALG_PATHS,
103+
[ [ joinpath(HOMALG_PROJECT_PATH,"deps","usr","bin") ] ] )
104+
105+
export HOMALG_PATHS
102106

103107
##
104108
function UseExternalSingular( bool::Bool )
@@ -188,8 +192,8 @@ function __init__()
188192
## add "~/.julia/.../HomalgProject/" at the beginning of GAPInfo.RootPaths
189193
GAP.Globals.EnhanceRootDirectories( GAP.julia_to_gap( [ GAP.julia_to_gap( HOMALG_PROJECT_PATH * "/" ) ] ) )
190194

191-
## add ~/.julia/artifacts/*/bin to GAPInfo.DirectoriesSystemPrograms
192-
for paths in HOMALG_EXTRA_PATHS
195+
## add more paths to GAPInfo.DirectoriesSystemPrograms
196+
for paths in HOMALG_PATHS
193197
paths = GAP.Globals.List( GAP.julia_to_gap( paths ), GAP.julia_to_gap )
194198
paths = GAP.Globals.Concatenation( paths, GAP.Globals.GAPInfo.DirectoriesSystemPrograms )
195199
paths = GAP.Globals.Unique( paths )

0 commit comments

Comments
 (0)