Compiling Elmer on OS X Lion, ranlib problem

Discussion about building and installing Elmer
Post Reply
flavien
Posts: 3
Joined: 14 Feb 2013, 05:07
Antispam: Yes

Compiling Elmer on OS X Lion, ranlib problem

Post by flavien »

Hi,

So I'm trying to compile Elmer on my mac book pro with os x lion installed. I installed the most recent compiler for gcc (4.7) and gfortran (4.7.2) with homebrew. After going through quite a lot of struggling I making some progresses but still running in some problems. The later is with the building of the library libbinio.a. When the install code try to create it with:

Code: Select all

Making all in binio
Making all in test
make[4]: Nothing to be done for `all'.
gcc-4.7 -DHAVE_CONFIG_H -I. -I../.. -L/usr/local/bin -I/usr/include -I/opt/elmer/include 
        -MT binio.o -MD -MP -MF .deps/binio.Tpo -c -o binio.o binio.c
mv -f .deps/binio.Tpo .deps/binio.Po
gfortran -I.  -I.. -L/usr/local/bin   -I. -Ibinio -I../binio -c -o kinds.o kinds.f90
gfortran -I.  -I.. -L/usr/local/bin   -I. -Ibinio -I../binio -c -o biniomod.o biniomod.f90
I then get the error:

Code: Select all

 /usr/bin/ranlib: file: libbinio.a(kinds.o) has no symbols
ranlib libbinio.a
ranlib: file: libbinio.a(kinds.o) has no symbols
My installation script lokks like that:

Code: Select all

 7 export FC=gfortran
8 export F77=gfortran
9 export CC=gcc-4.7 
10 export CXX=g++-4.7 
11 #export ld=/usr/bin/ld
12 
13 export CFLAGS="-L/usr/local/bin" 
14 export FFLAGS="-L/usr/local/bin" 
15 export CXXFLAGS="-L/usr/local/bin"
16 export FCFLAGS="-L/usr/local/bin" 
17 export LDFLAGS="-lstdc++ -L/usr/bin -L/usr/local/bin" 
18 
19 modules="matc umfpack mathlibs elmergrid meshgen2d eio hutiter fem"
20 for m in $modules; do
21     cd $m
22     make clean
23     cd ..
24 done
25 
26 modules="matc umfpack mathlibs elmergrid meshgen2d eio hutiter fem"
27 for m in $modules; do
28     cd $m
29     ./configure --with-debug --prefix=/opt/elmer
30     make
31     make install
32     cd ..
33 done
If someone has any clue about what it might be due to, that would be greatly appreciated.
Thanks,
Flavien
Post Reply