Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using Sundials #4094

Closed
ghost opened this issue Aug 18, 2013 · 16 comments
Closed

using Sundials #4094

ghost opened this issue Aug 18, 2013 · 16 comments

Comments

@ghost
Copy link

ghost commented Aug 18, 2013

1

Why is this happening??

@ivarne
Copy link
Member

ivarne commented Aug 18, 2013

Sundials.jl is a wrapper for a c library, and it looks like julia can not find the compilled module (.dll files on windows)

Reading the https://github.com/tshort/Sundials.jl/blob/master/README.md file says that you have to have sundials installed on your system before it is suposed to work. It looks like you need to install that first from http://computation.llnl.gov/casc/sundials/main.html , but I have no idea how to tell the Julia Sundalis.jl wrapper where to find the libsundials_cvode library on windows. It might just work, but I don't use windows.

If this does not help, try to ask on the julia-users mailing list, which might be a more appropriate forum get help on using Julia. Closed github issues does not rank high in google, so it will be hard for others to find the solution to this problem later.

@ghost
Copy link
Author

ghost commented Aug 18, 2013

@ivarne ..Well Sundials is installed in my system, but I guess julia cannot find the path for sundials-libraries.
have you worked with sundials? If yes, then as you use linux, does the sundials libraries get automatically linked up while using Pkg2.add("Sundials").
Or, how to link up the sundials library with Julia?

@mlubin
Copy link
Member

mlubin commented Aug 18, 2013

This should be filed as an issue under https://github.com/tshort/Sundials.jl. I'd suggest taking a look at using BinDeps for finding the library.

@ViralBShah
Copy link
Member

Cc @tshort

@ghost
Copy link
Author

ghost commented Aug 19, 2013

Sir,
I am trying the same thing in Linux. I have used, Ubuntu Software Center to Install 'libsundials-serial-dev:i386'.
Then,
sundials_installation_linux

I am unable to solve the problem.

@pao
Copy link
Member

pao commented Aug 19, 2013

Going out on a limb based on the error message--32-bit Sundials (":i386" multiarch package) and 64-bit Julia? Try installing libsundials-serial-dev:amd64.

@ivarne
Copy link
Member

ivarne commented Aug 19, 2013

I managed to install Sundials on OSX from source using cmake, but it took a lot documentation reading before I managed to build the required shared libraries.

after downloading sundials i tried

./configure --enable-shared
make
sudo make install

but the resulting shared library was empty, and I got missing symbols.

Then i tried to build using cmake

cmake ../sundials -i
# lots of options
Variable Name: BUILD_SHARED_LIBS
Description: Build shared libraries
Current Value: OFF
New Value (Enter to keep current value): on
# lots of more options

make
sudo make install

And then it seems to work (but I have not tested that the calculations are reasonable)

@ivarne
Copy link
Member

ivarne commented Aug 20, 2013

I have not installed Julia on a Windows computer, so I have no opportunity to test this. If you are able to locate your sundials install dir and find the directory that contains (lib)sundials_cvode.dll, the proper way to tell Julia where to find it is to call

push!(Sys.DL_LOAD_PATH, "C:\path\to\sundials")

@ViralBShah
Copy link
Member

How did you install sundials? I believe that sundials may not be building a shared library by default.

@ViralBShah
Copy link
Member

On ubuntu, with libsundials-serial-dev, I do notice that the shared library is included, and the example does work. @pao 's suggestion is right - just install libsundials-serial-dev or libsundials-serial-dev:amd64.

brew on mac does not build sundials as a shared library by default, but passing the configure option --enable-shared does build the shared libraries. @staticfloat Do you think we can request the brew folks to include --enable-shared in the sundials build?

@staticfloat
Copy link
Member

@mlubin
Copy link
Member

mlubin commented Aug 21, 2013

@staticfloat we'll also need to get BinDeps to pass that option to homebrew. There currently isn't syntax for that.

@ghost
Copy link
Author

ghost commented Aug 21, 2013

@ViralBShah ..Thanx sir, for the reply, waiting for the weekend....will give another try to solve as per the suggestions.....

@staticfloat
Copy link
Member

@mlubin Adam suggested we just always build the shared library. So I've changed the PR to do that. (Kind of dodging the issue at hand, but perhaps that's alright)

@staticfloat
Copy link
Member

We've got shared libraries on brew now.

@ViralBShah
Copy link
Member

@deepraj222 Can we close this one?

@ghost ghost closed this as completed Sep 7, 2013
KristofferC pushed a commit that referenced this issue Dec 4, 2024
Stdlib: Pkg
URL: https://github.com/JuliaLang/Pkg.jl.git
Stdlib branch: master
Julia branch: master
Old commit: 7b759d7f0
New commit: d84a1a38b
Julia version: 1.12.0-DEV
Pkg version: 1.12.0
Bump invoked by: @KristofferC
Powered by:
[BumpStdlibs.jl](https://github.com/JuliaLang/BumpStdlibs.jl)

Diff:
JuliaLang/Pkg.jl@7b759d7...d84a1a3

```
$ git log --oneline 7b759d7f0..d84a1a38b
d84a1a38b Allow use of a url and subdir in [sources] (#4039)
cd75456a8 Fix heading (#4102)
b61066120 rename FORMER_STDLIBS -> UPGRADABLE_STDLIBS (#4070)
814949ed2 Increase version of `StaticArrays` in `why` tests (#4077)
83e13631e Run CI on backport branch too (#4094)
```

Co-authored-by: Dilum Aluthge <dilum@aluthge.com>
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants