First time here? Check out the FAQ!

Ask Your Question
1

how to shift to source installed sage in Ubuntu

asked 3 years ago

anonymous user

Anonymous

I installed sage from the command line initially with 'sudo apt .....' and subsequently wanted to run the version from source. I have installed the source file successfully now but on the command line the older version runs when sage command is typed. I realize that the SAGE_ROOT path needs to be specified again and would want to know what is the best way to do this ?

Preview: (hide)

2 Answers

Sort by » oldest newest most voted
1

answered 3 years ago

Masacroso gravatar image

updated 3 years ago

You cannot run sage from source code, maybe you mean from a binary. I will assume that you have download the tar.bz2 file for sagemath in ubuntu from the web of sage. Then first uninstall the sage installed with sudo apt, this is to free space as you will not use this anymore. Now go to the folder where you have unzipped the tar.bz2 file and copy it direction to add it to the $PATH, to do this follow these instructions.

Once you have done this maybe you will need to reboot the system, and then you can call sage from any terminal just with the command sage.

Preview: (hide)
link
0

answered 3 years ago

slelievre gravatar image

If I understand correctly, you have installed Sage both

  • from the distribution, using sudo apt install ...
  • from source, by downloading the source file, extracting it, and running make configure, ./configure, and make

Let's say your installed-from-source Sage is at /home/yourname/sagemath/sage, then you add an alias to it and place it to some directory that is in your PATH.

For example:

ln -s /home/yourname/sagemath/sage /usr/local/bin

or with sudo if necessary:

sudo ln -s /home/yourname/sagemath/sage /usr/local/bin

After that, running sage should run the Sage you want.

Preview: (hide)
link

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: 3 years ago

Seen: 254 times

Last updated: Sep 12 '21