Ask Your Question
1

still getting Malform expression using giac in 9.6

asked 2022-05-17 10:49:33 +0100

Nasser gravatar image

updated 2022-05-19 20:28:39 +0100

How to use giac 1.9 with sagemath 9.6?

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
2

answered 2022-05-18 09:25:12 +0100

slelievre gravatar image

So far, Sage does not accept Giac 1.9 from the system.

Changing that is the object of

where a change has been submitted and positively reviewed.

So hopefully it should become part of the next beta release.

To apply it before that, if you built Sage from source, try this:

$ cd $(sage -c "print(SAGE_ROOT)")
$ git remote add trac git://trac.sagemath.org/sage.git -t develop
$ git checkout -b 33717
$ git fetch trac u/tornaria/33717
$ git merge FETCH_HEAD
$ ./sage -b

Next time you start Sage, it should have the fix.

Next time you want to upgrade Sage, start by checking out the develop branch:

$ git checkout develop
$ git pull origin develop
$ ./bootstrap -q && ./configure -q && make -s V=0
edit flag offensive delete link more

Comments

Thanks. I am trying this now. I never used git before (one day I need to learn it). Do I need to do make distclean before doing all the above? I also did git remote add trac git://trac.sagemath.org/sage.git -t develop now and got error error: remote trac already exists. should I just ignore this and continue?

Nasser gravatar imageNasser ( 2022-05-18 09:31:17 +0100 )edit

I think I will just wait for sage 9.7 in this case. I tried the above but it is not working for me. I keep getting same error. May be I did something wrong. But it is no problem now that I know what the cause. I will wait for 9.7 and try again.

Nasser gravatar imageNasser ( 2022-05-18 10:01:51 +0100 )edit

You will need to do make distclean for these changes to have an effect.

John Palmieri gravatar imageJohn Palmieri ( 2022-05-19 02:05:20 +0100 )edit
2

answered 2022-05-19 02:07:27 +0100

updated 2022-05-20 01:28:04 +0100

You could try editing the file build/pkgs/giac/spkg-configure.m4: change the line

   m4_pushdef([GIAC_MAX_VERSION], [1.7.999])

to something with a larger number, maybe

   m4_pushdef([GIAC_MAX_VERSION], [1.9.999])

Then try make distclean and make configure and ./configure and see what config.log says about whether it's going to build giac or use the system package.

(The files spkg-configure.m4 for the various packages are used to construct the main configure script, which is what make configure does.)

Edit: my answer is essentially equivalent to the other one. The cited trac ticket makes exactly my proposed change to spkg-configure.m4, after which one should do

  • make distclean to remove all traces of any previous build
  • make configure to rebuild the configure script — this automatically runs ./bootstrap as recommended in the other answer.
  • ./configure with any relevant arguments
  • at this point, look at config.log to see what it says about building giac. There is a section with the heading "Build status for each package", and the hope is that for giac it will say, "using system package; SPKG will not be installed"
  • then make to actually build Sage
edit flag offensive delete link more

Comments

I actually did what you show before,. It was one of the things I did try, but I did not mention it in my post. (btw, you have typo, it is .m4 file not .g4). But it did not work., I found out that the configure file itself, has hardcoded values for giac allowed version number,. Yes, hardcoded inside the configure file. If you look at it, you will see. But I am now trying this yet again. All from a brand new sagemath 9.6 folder (I deleted everything and extracted the tar file again just to make sure). I am now building it. will let you know the result. But I am sure it will not work. It will still use old giac. But will let you know when done. The thing I still do not understand, is where sagemath finding the old giac code it is calling ...(more)

Nasser gravatar imageNasser ( 2022-05-19 04:02:15 +0100 )edit

Ok, build is complete. It did not work. Build said it is using system giac, which is correct. I have giac 1.9 on system. But when it is completed, and called integrate command, it called giac 1.7. How, I do not know. I assume sagemath 9.6 comes with giac 1.7 library hiding somewhere and it uses that, even though it says it will use system giac. I know I only have giac 1.9 on my Linux box.

Nasser gravatar imageNasser ( 2022-05-19 05:11:28 +0100 )edit

Try the new directions, including make configure to rebuild the main configure script.

John Palmieri gravatar imageJohn Palmieri ( 2022-05-19 07:12:22 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2022-05-17 10:49:33 +0100

Seen: 323 times

Last updated: May 20 '22