Switch Julia version

Hello,

I’ve been using Julia 1.0, but have now run into a package that requires 1.1 (Cxx.jl), so I downloaded it, but don’t know how to set up Julia Pro to use it. I would like to still be able to use version 1.0, so I don’t want to delete it.

I tried pkg> build IJulia, but that didn’t work, maybe because I haven’t deleted the old version.

Why not update to the latest version (1.6)? 1.0 and 1.1 are old.

2 Likes

If he wants Cxx.jl he will probably be stuck in at the most 1.3 unfortunately

1 Like

Why do you want to use 1.0?

1 Like

You’ll need to include the latest julia into system path, i.e., letting the system know you’ve installed it.
For pkg> build IJulia stuff, first you need to make sure the REPL you open is v1.1 (instead of your old v1.0).
You can check this by

julia> VERSION
1 Like

Because it’s the stable version, right? I had problems with some other packages with newer versions before (so I deleted and installed 1.0)

Thanks! that makes sense :slight_smile: How do I include the Julia version into the system path?

1.0 is currently marked as the long-term support version, but it’s about to be deprecated in favor of 1.6, the current version. (And probably already should have been; 1.0 is slow and more than 3 years old at this point.)

I assume that you had problems with getting Cxx.jl working in 1.6; unfortunately, that’s to do with Cxx.jl, which is no longer being updated/supported. I’d suggest trying 1.3, if you need Cxx.jl, but that will probably break down soon, completely. However, CxxWrap.jl provides similar functionality and is still being actively maintained. You can also call C (not C++) directly from Julia without having to use any packages, if that would work instead.

If there’s any other packages relying on pre-1.6 versions, we can probably help you find replacements. However, almost all packages will work just fine with 1.6, which (theoretically) shouldn’t have been a breaking update; I assume Cxx.jl was relying on some kind of unexported functionality that they shouldn’t have been using. Very few packages will maintain 1.0 support after the next few months.

2 Likes

1.6 is the latest stable version, and is better than 1.0 in pretty much every way. Unless you have very specific reasons, you should use the latest version.

Do you have any other reasons than Cxx.jl support?

2 Likes

I see, thank you all for the update on 1.0 being deprecated! I guess I will switch to 1.6 for common usage. I do still want 1.1 or 1.3 so that I can use Cxx though, because I don’t really want to go through shared libraries, and am interested in c++ code, not only c. Could anyone explain how I specify the Julia version in the system path? Thanks!