【问题】要编译Adcirc+Swan时,碰到个提示
../work/odir4/global_3dvs.o:在函数‘global_3dvs_mp_alloc_3dvs_’中:
global_3dvs.F:(.text+0x2c4f):对‘boundaries_mp_neta_’未定义的引用(undefined
reference)
【参考】网络上有间接的回复:
This means something is missing in your link statement. As the name of the missing routines starts with "boundaries_mp_", I deduce that you have a module "boundaries" and the compiler is happy about it, but the linker is not fed the object file that contains the compiled implementation of the routines in that module. Add the name of the object file to the link statement.
【解决】在Swan的Makefile中添加boundaries.o库,操作如下:
MSG_OBJS = \
$(O_DIR)mkdir.$(EXTO) \
$(O_DIR)sizes.$(EXTO) \
$(O_DIR)global.$(EXTO) \
$(O_DIR)boundaries.o \
$(O_DIR)global_3dvs.$(EXTO) \
$(O_DIR)version.$(EXTO) \
$(O_DIR)messenger.$(EXTO)