How to upgrade to Julia 0.7 in Mac OS X - julia

Amazingly, I can't find a straight answer to this. This page How to upgrade Julia to a new release? answered the question of upgrading Julia back in 2015, and linked to this page https://github.com/staticfloat/homebrew-julia#upgrading-julia for Mac OS, but (a) the latter page starts with a big "This tap is not actively maintained" warning, and (b) the upgrade instructions only say how to get "the latest development version", which is not what I want (I want Julia 0.7, not 1.0).
So, how do I upgrade Julia from 0.6 to 0.7 on Mac OS X? I installed Julia 0.6 using the command "brew cask install julia".

Since nobody answered your question, I shall do it even thought I am not a good writer.
First uninstall julia from home-brew using "brew uninstall julia"
Next go to the julia website and grab the julia dmg for Mac
https://julialang.org/downloads/
Because you can install multiple version of julia at the same time, I suggest you install the following versions
julia 1.0
julia 0.7
julia 0.6
My suggestion is that you install julia 0.6 first by downloading the dmg file. Then double click on it (the dmg file) on the "/user/yourname/Download" directory. Drag the julia to the Application folder (just like how you would install any mac application). Don't forget to eject the dmg image after you have done with it.
Do the same for julia 0.7
Do the same for julia 1.0
Next you need to open the Terminal and create 4 symbolic links. See the commands below and do not type in the "$" character, it is just the command prompt.
$ cd /usr/local/bin
$ ln -s /Applications/Julia-1.0.app/Contents/Resources/julia/bin/julia julia
$ ln -s /Applications/Julia-0.6.app/Contents/Resources/julia/bin/julia julia06
$ ln -s /Applications/Julia-0.7.app/Contents/Resources/julia/bin/julia julia07
$ ln -s /Applications/Julia-1.0.app/Contents/Resources/julia/bin/julia julia10
Now you have 4 different commands you can use
julia
julia06
julia07
julia10
Now you can close the terminal. All done.

Related

Sagemath 9.2 documentation not working on Ubuntu Focal

I've downloaded the Sage 9.2 tarball from sagemath.org for Ubuntu Focal. The software works in every other regard but when I load a Jupyter notebook and click on one of the Help topics, I get a 404 File not Found saying the page I'm requesting doesn't exist.
How do I get the docs to work? Thanks for any help with this.
This is a bug in Sage 9.2. See
Ask Sage question 54581: 9.2 download for Ubuntu 20.04 documentation
Sage-Windows issue 52: broken symbolic link: doc -> /doesnotexist/html/en
The issue is fixed at the following ticket,
which was merged in Sage 9.3.beta3:
Sage Trac ticket 30903: Fix broken symlink to documentation in the Sage jupyter kernelspec
Two solutions to get the fix:
wait for Sage 9.3 in a few weeks
install 9.3.beta3
One can also fix one's installation as suggested
at Sage-Windows issue 52 referenced above.
For this run the following commands:
$ SR=`sage -c 'print(SAGE_ROOT)'`
$ A=$SR/local/share/doc/sage/html/en
$ B=$SR/local/share/jupyter/kernels/sagemath/doc
$ ln -sf $A $B
This works fine and restarting Sage is not even needed.

Gcc versions later than 7 are not supported by CUDA 10 - Qt Error in Arch Linux

I am running Arch Linux and trying to build a project in Qt however, Qt spits the following error:
/opt/cuda/include/crt/host_config.h:129: error: #error -- unsupported GNU version! gcc versions later than 7 are not supported!
I have already tried a suggestion from a previous Stack Overflow post found here:
CUDA incompatible with my gcc version
I did not use the exact command as my cuda is located in /opt/cuda/bin/gcc. I did the same command for g++. However, the terminal outputs that these files are already linked. I did confirm this by going to the actual file and looking at it's properties.
Can someone please suggest a solution to my issue?
I managed to do so usung this two lines, this will update the symbolic links of cuda to gcc7
ln -s /usr/bin/gcc-7 /usr/local/cuda/bin/gcc
ln -s /usr/bin/g++-7 /usr/local/cuda/bin/g++
The issue comes from cuda-10.0/targets/x86_64-linux/include/crt/host_config.h in the main CUDA-10 directory tree. The target for your architecture was placed in /opt.
Some posts recommend faking the inequality
if __GNUC__ > 7
to say
if __GNUC__ > 8
but that is a bad idea. Using
make 'NVCCFLAGS=-m64 -D__GNUC__=7' -k
is permissible in some trivial cases, but still fundamentally the same bad hack.
You probably have alternates on your system which has constructed symbolic links pointing to the version 8 gnu tool chain files. That's why you get an indication version 7 is already installed.
You can learn how to modify your alternates for just your developer users BUT NOT for root or any system admin accounts. You may want to remember how to switch back and forth between 7 and 8 so you only use 7 when actually needed, since many other things may be tested only with 8.
If that doesn't work for you, you can build gcc-7 from source. The preparatory system admin work includes a dnf install, a build from source, an install of 7.4 gnu compiler, and a set up of paths for CUDA development only. If you have gnu gcc and g++ version 8 installed with the appropriate standard libraries and it works, the version 7 compiler can be installed with relative ease.
Browse and find the nearest mirror listed on https://gcc.gnu.org/mirrors.html and then copy the link location for gcc-7.4.0.tar.xz and place it in the shell variable u like this example.
u="http://mirrors.concertpass.com/gcc/releases/gcc-7.4.0/gcc-7.4.0.tar.xz"
Then you can do the rest as commands.
sudo dnf install libmpc-devel
cd
mkdir -p scratch
cd scratch
wget -O - "$u" |tar Jxf -
cd gcc-7.4.0
mkdir build
cd build
../configure --prefix=/usr/local/gcc-7
make
sudo bash -c "cd \"`pwd`\"; make install"
Then you execute this in the shells and tools you develop with. Do NOT put this in the system login apparatus or in .bashrc or .bash_profile, for the same reason as above. Other things may be tested with version 8 only. Instead place them in your development environment where they belong.
LD_LIBRARY_PATH=/usr/local/gcc-7/lib64:$LD_LIBRARY_PATH
LD_LIBRARY_PATH=/usr/local/gcc-7/lib:$LD_LIBRARY_PATH
LD_LIBRARY_PATH=/usr/local/cuda-10.0/NsightCompute-1.0/host/linux-desktop-glibc_2_11_3-glx-x64/Plugins:$LD_LIBRARY_PATH
LD_LIBRARY_PATH=/usr/local/cuda-10.0/NsightCompute-1.0/target/linux-desktop-glibc_2_11_3-glx-x64:$LD_LIBRARY_PATH
LD_LIBRARY_PATH=/usr/local/cuda-10.0/targets/x86_64-linux/lib/stubs:$LD_LIBRARY_PATH
PATH=/usr/local/gcc-7/bin:$PATH
PATH=/usr/local/cuda-10.0/bin:$PATH
PATH=$HOME/big/cuda.samples/NVIDIA_CUDA-10.0_Samples/bin/x86_64/linux/release:$PATH

Virtuoso appears to be installed... but isn't (and won't run)

I've followed the instructions to install the stable branch of Virtuoso Open Source 7 on Ubuntu 16.04. There don't appear to be any errors throughout the process of —
./autogen.sh
CFLAGS="-O2 -m64"
export CFLAGS
./configure
make
make install
However, when I go to /usr/local/virtuoso-opensource/var/lib/virtuoso/db (which contains only virtuoso.ini) and run —
virtuoso-t -f &
The first time I do this the terminal just vanishes. When I reopen the terminal and run the same again it just reads The program 'virtuoso-t' is currently not installed. You can install it by typing: apt install virtuoso-opensource-6.1-bin.
I've tried installing both 7 stable and develop from github and both produce the same result. I'd rather use 7 but tried installing 6 via the ubuntu package and conductor wouldn't work for me - not having much luck all round, one of those days.
Thanks for assistance you can provide.
Sounds like you didn't adjust your $PATH variable after make install.
$PATH should include the path to the directory which contains the virtuoso-t, or you can include that path in the launch command, e.g. —
/path/to/virtuoso-t -f -c /usr/local/virtuoso-opensource/var/lib/virtuoso/db/virtuoso.ini &
(Note that the develop/7 branch is recommended over stable/7 at the moment, due to the number of fixes there.)

How to install ADA IDE and compiler on mac (OSX)?

I downloaded GNAT ADA GPL 2014 and now trying to install on my Mac.
The directions below are the ones I am following, but I do not know where to look to find the file called doinstall. I might still need some help after finding it, but can anyone help me out here?
Navigate to the directory that contains a file called: doinstall
Enter: sudo mkdir /usr/local/gnat
Enter: sudo ./doinstall
Update your path as needed for your shell
You should have downloaded gnat-gpl-2014-x86_64-darwin-bin.tar.gz.
Go to some temporary directory (I use ~/tmp):
cd ~/tmp
Unpack the download, which creates a directory gnat-gpl-2014-x86_64-darwin-bin containing the binary distribution to be installed:
tar zxvf ~/Downloads/gnat-gpl-2014-x86_64-darwin-bin.tar.gz
Enter that directory, which contains (amongst others) doinstall:
cd gnat-gpl-2014-x86_64-darwin-bin
Execute doinstall to enter the installation dialog:
sudo ./doinstall
Remove the unpacked download:
cd ..
rm -rf gnat-gpl-2014-x86_64-darwin-bin
Now you can update PATH as needed for your shell.
What Simon Wright said is correct, but if you're running on Yosemite there's an extra problem: for some obscure reason, Adacore GNAT is broken on Yosemite. You have to make it think it's compiling for Mavericks:
export MACOSX_DEPLOYMENT_TARGET=10.9 # Yosemite workaround
That can go in a few different places, but I put it near the top of the /usr/local/gnat/bin/gps script so it doesn't interfere with the xcodebuild environment.
Also, I found GTKAda to be nearly impossible to install from source; if you download the XNAdaLib-GPL package from http://sourceforge.net/projects/gnuada/ you can install that and get everything you need without having to wade through Adacore's mess. (You may want to use the Adacore version of Glade for GUI design though; for some reason the Sourceforge package's version is localized in French and I'm not sure if it can be switched to English.)
Finally, since this is a bit duct-tape-and-baling-wire, I would recommend not shipping any production mission-critical code with this environment; either roll back to Mavericks or wait for GNAT 2015.

How to replace ZSH 4 with ZSH 5

I'd like to use zsh5 instead of the old 4. So I installed 5 with homebrew:
brew install zsh
and it did download the 5.0.2 tar and installed successfully, but after I restart iTerm2, type
zsh --version
it still shows me
zsh 4.3.11 (i386-apple-darwin12.0)
I didn't remember how I installed 4, so not sure how to uninstall it? How could I remove 4 and use 5 as default?
when I looked /usr/local/Cellar/zsh/5.0.2/bin/, I see 2 files:
zsh zsh-5.0.2
Should I link zsh-5.0.2 to /bin/zsh ?
Your older zsh version may be in a location in your path with higher priority than the homebrew installation.
$ which zsh # Check what path zsh refers to
/usr/local/bin/zsh
$ ls `which zsh` # It may be a link to homebrew's cellar
lrwxr-xr-x ... /usr/local/bin/zsh -> ../Cellar/zsh/5.0.2/bin/zsh
$ echo $PATH # Make sure /usr/local is before other places in you $PATH
/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
You can also check which versions homebrew has installed and which is currently active using
brew info like below. In this case there are two versions of node installed, and 0.10.13 is currently selected (see the *)
$ brew info node
node: stable 0.10.13, devel 0.11.4, HEAD
http://nodejs.org/
/usr/local/Cellar/node/0.10.12 (1104 files, 16M)
Built from source
/usr/local/Cellar/node/0.10.13 (1085 files, 15M) *
Built from source
If brew does have multiple versions listed you can switch between them using brew switch node 0.10.12 for this example.

Resources