[CIG-SEISMO] SPECFEM3D - SunOS - Help Reqd (strndup error)

Walter Landry walter at geodynamics.org
Tue Mar 29 11:06:24 PDT 2011


D-Durga-Prasad <ddprasad at gmail.com> wrote:
> Hi,
> 
> When I am using gmake, it seems the code gets complied until an error with
> strndup is encountered:
> 
> Make Error:=
> 
> mpif90   -I../shared -c -o ../../obj/gen/parallel.o ../shared/parallel.f90
> mpif90   -I../shared -o ../../bin/xgenerate_databases
> ../../obj/gen/program_generate_databases.o ../../lib/libgendatabases.a
> ../../obj/gen/parallel.o
> Undefined                       first referenced
>  symbol                             in file
> strndup

strndup is a gnu extension not provided by the Sun libc.  In the file
src/shared/param_reader.c, try removing the lines

  #ifdef __APPLE__

and 

  #endif

Cheers,
Walter Landry
walter at geodynamics.org


More information about the CIG-SEISMO mailing list