Compiler error in Upwelling test case
-
- Posts: 2
- Joined: Wed Jul 10, 2013 3:00 pm
- Location: Princeton University
Compiler error in Upwelling test case
Hi all,
I'm a new user and have been receiving the following error when I attempt to compile the Upwelling test case:
Undefined symbols for architecture x86_64:
"_curl_easy_cleanup", referenced from:
_occurlclose in libnetcdf.a(liboc_la-http.o)
"_curl_easy_getinfo", referenced from:
_ocfetchhttpcode in libnetcdf.a(liboc_la-http.o)
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
"_curl_easy_init", referenced from:
_occurlopen in libnetcdf.a(liboc_la-http.o)
"_curl_easy_perform", referenced from:
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
"_curl_easy_setopt", referenced from:
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_occurlopen in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
_set_compression in libnetcdf.a(liboc_la-curlfunctions.o)
_set_verify in libnetcdf.a(liboc_la-curlfunctions.o)
_set_cookies in libnetcdf.a(liboc_la-curlfunctions.o)
...
"_curl_easy_strerror", referenced from:
_ocsetcurlproperties in libnetcdf.a(liboc_la-http.o)
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
"_curl_version_info", referenced from:
_ocinitialize in libnetcdf.a(liboc_la-ocinternal.o)
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [/Users/Lisa/ROMS/Projects/Upwelling/oceanG] Error 1
I've looked through the forum before posting but I apologize if this has been answered before.
I'm using Mac OS 10.8.4 and gfortran (I was following this tutorial: https://www.myroms.org/wiki/index.php/R ... ow_Leopard)
Thank you!
-Lisa
I'm a new user and have been receiving the following error when I attempt to compile the Upwelling test case:
Undefined symbols for architecture x86_64:
"_curl_easy_cleanup", referenced from:
_occurlclose in libnetcdf.a(liboc_la-http.o)
"_curl_easy_getinfo", referenced from:
_ocfetchhttpcode in libnetcdf.a(liboc_la-http.o)
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
"_curl_easy_init", referenced from:
_occurlopen in libnetcdf.a(liboc_la-http.o)
"_curl_easy_perform", referenced from:
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
"_curl_easy_setopt", referenced from:
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_occurlopen in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
_set_compression in libnetcdf.a(liboc_la-curlfunctions.o)
_set_verify in libnetcdf.a(liboc_la-curlfunctions.o)
_set_cookies in libnetcdf.a(liboc_la-curlfunctions.o)
...
"_curl_easy_strerror", referenced from:
_ocsetcurlproperties in libnetcdf.a(liboc_la-http.o)
_ocfetchlastmodified in libnetcdf.a(liboc_la-http.o)
_ocfetchurl_file in libnetcdf.a(liboc_la-http.o)
_ocfetchurl in libnetcdf.a(liboc_la-http.o)
"_curl_version_info", referenced from:
_ocinitialize in libnetcdf.a(liboc_la-ocinternal.o)
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [/Users/Lisa/ROMS/Projects/Upwelling/oceanG] Error 1
I've looked through the forum before posting but I apologize if this has been answered before.
I'm using Mac OS 10.8.4 and gfortran (I was following this tutorial: https://www.myroms.org/wiki/index.php/R ... ow_Leopard)
Thank you!
-Lisa
Re: Compiler error in Upwelling test case
Can you show us the full link command? Are you using USE_NETCDF4? For me, I use USE_NETCDF4, which invokes "nc-config --flibs". On one system this gives:
and on another, it gives:
One of these links to a curl library, the other does not. What do you get from "nc-config --flibs"?
Did you compile the netcdf library and run its self-checks?
Code: Select all
delta.arsc.edu 360% nc-config --flibs
-L/usr/local/pkg/netcdf/netcdf-4.1.pgi/lib -lnetcdff -lnetcdf -L/usr/local/pkg/hdf5/hdf5-1.8.4.pgi/lib -lhdf5_hl -lhdf5 -lz -lm -L/usr/kerberos/lib64 -lcurl -ldl -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lidn -lssl -lcrypto -lz
Code: Select all
pacman6 396% nc-config --flibs
-L/usr/local/pkg/netcdf/netcdf-4.3.0.gnu-4.7.3/lib -lnetcdff -L/usr/local/pkg/hdf5/hdf5-1.8.10-p1.gnu-4.7.3/lib -L/usr/local/pkg/szip/szip-2.1.gnu/lib -L/usr/local/pkg/udunits/udunits-2.1.24.gnu-4.7.3/lib -L/usr/local/pkg/netcdf/netcdf-4.3.0.gnu-4.7.3/lib -lnetcdf -lnetcdf
Did you compile the netcdf library and run its self-checks?
-
- Posts: 2
- Joined: Wed Jul 10, 2013 3:00 pm
- Location: Princeton University
Re: Compiler error in Upwelling test case
Kate,
Thank you for pointing me in the right direction. I had some errors in the netcdf pathways, it's working now!
Lisa
Thank you for pointing me in the right direction. I had some errors in the netcdf pathways, it's working now!
Lisa
Re: Compiler error in Upwelling test case
kate wrote:Can you show us the full link command? Are you using USE_NETCDF4? For me, I use USE_NETCDF4, which invokes "nc-config --flibs". On one system this gives:and on another, it gives:Code: Select all
delta.arsc.edu 360% nc-config --flibs -L/usr/local/pkg/netcdf/netcdf-4.1.pgi/lib -lnetcdff -lnetcdf -L/usr/local/pkg/hdf5/hdf5-1.8.4.pgi/lib -lhdf5_hl -lhdf5 -lz -lm -L/usr/kerberos/lib64 -lcurl -ldl -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lidn -lssl -lcrypto -lz
One of these links to a curl library, the other does not. What do you get from "nc-config --flibs"?Code: Select all
pacman6 396% nc-config --flibs -L/usr/local/pkg/netcdf/netcdf-4.3.0.gnu-4.7.3/lib -lnetcdff -L/usr/local/pkg/hdf5/hdf5-1.8.10-p1.gnu-4.7.3/lib -L/usr/local/pkg/szip/szip-2.1.gnu/lib -L/usr/local/pkg/udunits/udunits-2.1.24.gnu-4.7.3/lib -L/usr/local/pkg/netcdf/netcdf-4.3.0.gnu-4.7.3/lib -lnetcdf -lnetcdf
Did you compile the netcdf library and run its self-checks?
Re: Compiler error in Upwelling test case
Helllo
i got the same error and when i type :
./nc-config --flibs
-L/opt/gfortransoft/serial/netcdf-4.1.1/lib -lnetcdf -lcurl
what should i do to fix it
thanks
i got the same error and when i type :
./nc-config --flibs
-L/opt/gfortransoft/serial/netcdf-4.1.1/lib -lnetcdf -lcurl
what should i do to fix it
thanks
Re: Compiler error in Upwelling test case
You're getting exactly the same errors with missing routines from the curl library? Is it really finding your curl library?
Did you install Netcdf and did it pass its self-checks?
Did you install Netcdf and did it pass its self-checks?
Re: Compiler error in Upwelling test case
hello
yes i did self check and it s working
yes i did self check and it s working
Re: Compiler error in Upwelling test case
and i m using netcdf 3 not 4
Re: Compiler error in Upwelling test case
When you ran the tests it must have linked to the curl library. Do you know where that library is? If so, you can view the symbols in it with the nm command. Do they match the symbols you are missing, including the same number of underscores?
-
- Posts: 5
- Joined: Thu Jan 08, 2015 11:16 pm
- Location: Institute of Atmospheric Physics, Chinese Academy
Re: Compiler error in Upwelling test case
YES.in the build.bash, you should set the HDF AND NETCDF path righ when you open USE_NETCDF.