Skip to content

Commit 573a6e8

Browse files
authored
Merge pull request #332 from wegank/maple-mspath
Allow overriding msolve path globally in Maple interface
2 parents e0f880f + 5e70a2d commit 573a6e8

1 file changed

Lines changed: 14 additions & 5 deletions

File tree

interfaces/msolve-to-maple-file-interface.mpl

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
macro(_MSPATH="msolve"):
2-
31
# /* This file is part of msolve.
42
# *
53
# * msolve is free software: you can redistribute it and/or modify
@@ -50,7 +48,8 @@ MSolve:=module()
5048
option package;
5149

5250
export MSolveGroebner, MSolveGroebnerLM,
53-
MSolveRealRoots,MSolveParam;
51+
MSolveRealRoots,MSolveParam,
52+
SetMSolvePath, GetMSolvePath;
5453

5554
local GetSystem, ToMSolve, GetOptions, CheckCharacteristic, ReadPolynomial,
5655
ExtractParametrization, RemoveFiles,
@@ -63,9 +62,19 @@ BuildSolution, Eval_linform, MakeBinaryInterval,
6362
Parametrization,
6463
RefineSolutions,
6564
SplitAndRefinePerCoordinates,
66-
SplitAndRefinePerConstraints;
65+
SplitAndRefinePerConstraints,
66+
DefaultMSolvePath;
67+
68+
DefaultMSolvePath := "msolve":
6769

70+
GetMSolvePath:=proc()
71+
return DefaultMSolvePath:
72+
end proc:
6873

74+
SetMSolvePath:=proc(path::string)
75+
DefaultMSolvePath := path:
76+
return DefaultMSolvePath:
77+
end proc:
6978

7079
GetSystem:=proc()
7180
local sys;
@@ -173,7 +182,7 @@ verb, param, nthreads, output, gb, elim, linalg;
173182
printf("Error in format options");
174183
end if;
175184
else
176-
msolve_path := _MSPATH;
185+
msolve_path := DefaultMSolvePath;
177186
end if;
178187

179188
if member("file_dir", map(lhs, opts)) then

0 commit comments

Comments
 (0)