thliebig / openEMS-Project

openEMS is a free and open electromagnetic field solver using the FDTD method.
356 stars 65 forks source link

Missing dependencies? #3

Closed jeffsf closed 8 years ago

jeffsf commented 8 years ago

In trying to install using brew install --HEAD https://raw.github.com/thliebig/openEMS-Project/master/brew/openEMS.rb I am finding missing dependencies (at the vtk dependency point), including:

This may be a problem with the vtk brew recipe.

After installing vtk the build eventually fails with

==> Checking out branch master
==> cmake . -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/openEMS/HEAD -DCMAKE_BUILD_TYPE=Release -DCMAKE_F
==> make
Last 15 lines from /Users/jkletsky/Library/Logs/Homebrew/openEMS/02.make:
[ 84%] Building CXX object src/CMakeFiles/CSXCAD.dir/CSPropConductingSheet.cpp.o
[ 87%] Building CXX object src/CMakeFiles/CSXCAD.dir/CSPropExcitation.cpp.o
[ 89%] Building CXX object src/CMakeFiles/CSXCAD.dir/CSPropProbeBox.cpp.o
[ 92%] Building CXX object src/CMakeFiles/CSXCAD.dir/CSPropDumpBox.cpp.o
[ 94%] Building CXX object src/CMakeFiles/CSXCAD.dir/CSPropResBox.cpp.o
[ 97%] Building CXX object src/CMakeFiles/CSXCAD.dir/CSBackgroundMaterial.cpp.o
[100%] Linking CXX shared library libCSXCAD.dylib
ld: library not found for -lvtkCommon
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[5]: *** [src/libCSXCAD.0.6.0.dylib] Error 1
make[4]: *** [src/CMakeFiles/CSXCAD.dir/all] Error 2
make[3]: *** [all] Error 2
make[2]: *** [CSXCAD-prefix/src/CSXCAD-stamp/CSXCAD-build] Error 2
make[1]: *** [CMakeFiles/CSXCAD.dir/all] Error 2
make: *** [all] Error 2

Looking into this further now

thliebig commented 8 years ago

Maybe brew updated vtk to version 7. Until yesterday that was not taken care of in openEMS. I just now updated this repo too to reflect this. Maybe you just try again?

jeffsf commented 8 years ago

Yes, brew is now using v7

==> Installing openEMS dependency: vtk
==> Downloading http://www.vtk.org/files/release/7.0/VTK-7.0.0.tar.gz

The build succeeds now, thank you! (I did configure vtk previously with --with-qt --with-qt5)

$ brew install --HEAD https://raw.github.com/thliebig/openEMS-Project/master/brew/openEMS.rb
######################################################################## 100.0%
==> Cloning https://github.com/thliebig/openEMS-Project.git
Updating /Library/Caches/Homebrew/openEMS--git
==> Checking out branch master
==> cmake . -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/openEMS/HEAD -DCMAKE_BUILD_TYPE=Release -DCMAKE_F
==> make
🍺  /usr/local/Cellar/openEMS/HEAD: 246 files, 4.3M, built in 2 minutes 11 seconds
thliebig commented 8 years ago

Well thats sounds good, closing the issue then. About the --with-qt5, is it necessary to put it in the brew file?

jeffsf commented 8 years ago

OpenEMS does build without adding --with-qt --with-qt5 I'm puzzled as to why it re-installed vtk from source, but at least OpenEMS built! I now have to learn how to use it...

Thanks again!

$ brew uninstall vtk
Uninstalling /usr/local/Cellar/vtk/7.0.0... (3,188 files, 107.8M)

$ brew uninstall openEMS
Uninstalling /usr/local/Cellar/openEMS/HEAD... (246 files, 4.3M)

$ brew install vtk
==> Installing vtk from homebrew/science
==> Downloading https://homebrew.bintray.com/bottles-science/vtk-7.0.0.el_capitan.bottle.1.tar.gz
Already downloaded: /Library/Caches/Homebrew/vtk-7.0.0.el_capitan.bottle.1.tar.gz
==> Pouring vtk-7.0.0.el_capitan.bottle.1.tar.gz
==> Caveats
Even without the --with-qt option, you can display native VTK render windows
from python. Alternatively, you can integrate the RenderWindowInteractor
in PyQt, PySide, Tk or Wx at runtime. Read more:
    import vtk.qt4; help(vtk.qt4) or import vtk.wx; help(vtk.wx)

==> Summary
🍺  /usr/local/Cellar/vtk/7.0.0: 3,015 files, 107.6M

$ brew install --HEAD https://raw.github.com/thliebig/openEMS-Project/master/brew/openEMS.rb
######################################################################## 100.0%
==> Installing dependencies for openEMS: vtk
==> Installing openEMS dependency: vtk
==> Downloading http://www.vtk.org/files/release/7.0/VTK-7.0.0.tar.gz
Already downloaded: /Library/Caches/Homebrew/vtk-7.0.0.tar.gz
==> cmake -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/vtk/7.0.0 -DCMAKE_BUILD_TYPE=Release -DCMAKE_FIND_F
==> make
==> make install
==> Caveats
Even without the --with-qt option, you can display native VTK render windows
from python. Alternatively, you can integrate the RenderWindowInteractor
in PyQt, PySide, Tk or Wx at runtime. Read more:
    import vtk.qt4; help(vtk.qt4) or import vtk.wx; help(vtk.wx)

==> Summary
🍺  /usr/local/Cellar/vtk/7.0.0: 3,188 files, 107.8M, built in 22 minutes 48 seconds
==> Installing openEMS
==> Cloning https://github.com/thliebig/openEMS-Project.git
Updating /Library/Caches/Homebrew/openEMS--git
==> Checking out branch master
==> cmake . -DCMAKE_C_FLAGS_RELEASE=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/openEMS/HEAD -DCMAKE_BUILD_TYPE=Release -DCMAKE_F
==> make
🍺  /usr/local/Cellar/openEMS/HEAD: 246 files, 4.2M, built in 1 minute 12 seconds