davydden / homebrew-dealiisuite

dealii suite using linuxbrew
6 stars 1 forks source link

deal.II on Ubuntu 14.04 with system blas/lapack #5

Closed jppelteret closed 9 years ago

jppelteret commented 9 years ago

@davydden There appears to be an issue with the way that the system BLAS/LAPACK libraries are passed to deal.II. See here for install logs.

# In 01.cmake, line 15
-DLAPACK_LIBRARIES=/libblas.so;/liblapack.so

It appears that the path is missing. This leads to a strange error during build:

[ 98%] make[2]: *** No rule to make target `/libblas.so', needed by `lib/libdeal_II.g.so.8.3.0'. Stop.

Do you know why this happens?

davydden commented 9 years ago

that has to do with this line https://github.com/davydden/homebrew-dealiisuite/blob/master/requirements/blas_requirement.rb#L64

effectively, when lib directory is empty the path ends up being absolute-like /libblas.so.

could you please try with:

 def self.full_path(blas_lib,blas_names,separator)
    exten = (OS.mac?) ? "dylib" : "so"
    tmp = blas_lib.chomp("/")
    tmp = "#{tmp}/" if tmp != ""
    return blas_names.split(";").map { |word| "#{tmp}lib#{word}.#{exten}" }.join(separator)
  end
davydden commented 9 years ago

p.s. i am surprised that petsc worked as it uses the same full-path as an input: https://github.com/davydden/homebrew-dealiisuite/blob/master/petsc.rb#L97