SLIBS in Macros file

Hi,I put
SLIBS+= -L$(LIB_NETCDF) -lnetcdff -lnetcdf  $(shell $(NETCDF_PATH)/bin/nc-config --flibs)in the Macros file, It seesms working but I dont't know where the value $(LIB_NETCDF) comes from and what the value of it is. Does anyone know and can tell me? thanks
 

jedwards

CSEG and Liaisons
Staff member
can either add -L$(LIB_NETCDF) -lnetcdff -lnetcdf  or $(shell $(NETCDF_PATH)/bin/nc-config --flibs)   but you shouldn't need both.   Also note that newer versions of netcdf use nf-config rather than nc-config.Define NETCDF_PATH in your env_mach_specific file LIB_NETCDF is defined in the Makefile depending on that definition.
 

jedwards

CSEG and Liaisons
Staff member
can either add -L$(LIB_NETCDF) -lnetcdff -lnetcdf  or $(shell $(NETCDF_PATH)/bin/nc-config --flibs)   but you shouldn't need both.   Also note that newer versions of netcdf use nf-config rather than nc-config.Define NETCDF_PATH in your env_mach_specific file LIB_NETCDF is defined in the Makefile depending on that definition.
 

jedwards

CSEG and Liaisons
Staff member
can either add -L$(LIB_NETCDF) -lnetcdff -lnetcdf  or $(shell $(NETCDF_PATH)/bin/nc-config --flibs)   but you shouldn't need both.   Also note that newer versions of netcdf use nf-config rather than nc-config.Define NETCDF_PATH in your env_mach_specific file LIB_NETCDF is defined in the Makefile depending on that definition.
 

jedwards

CSEG and Liaisons
Staff member
can either add -L$(LIB_NETCDF) -lnetcdff -lnetcdf  or $(shell $(NETCDF_PATH)/bin/nc-config --flibs)   but you shouldn't need both.   Also note that newer versions of netcdf use nf-config rather than nc-config.Define NETCDF_PATH in your env_mach_specific file LIB_NETCDF is defined in the Makefile depending on that definition.
 
Hi, jedwards: I don't know how to change the env_mach_specific file, since I don't know if my machine use module to define system variables. Can I just useSLIBS+= -L/opt/netcdf/lib -lnetcdff -lnetcdf thanks for your answering!
 
Hi, jedwards: I don't know how to change the env_mach_specific file, since I don't know if my machine use module to define system variables. Can I just useSLIBS+= -L/opt/netcdf/lib -lnetcdff -lnetcdf thanks for your answering!
 
Hi, jedwards: I don't know how to change the env_mach_specific file, since I don't know if my machine use module to define system variables. Can I just useSLIBS+= -L/opt/netcdf/lib -lnetcdff -lnetcdf thanks for your answering!
 
Hi, jedwards: I don't know how to change the env_mach_specific file, since I don't know if my machine use module to define system variables. Can I just useSLIBS+= -L/opt/netcdf/lib -lnetcdff -lnetcdf thanks for your answering!
 
Back
Top