加载中…
个人资料
昏眼看日
昏眼看日
  • 博客等级:
  • 博客积分:0
  • 博客访问:96,979
  • 关注人气:51
  • 获赠金笔:0支
  • 赠出金笔:0支
  • 荣誉徽章:
相关博文
推荐博文
谁看过这篇博文
加载中…
正文 字体大小:

Build IOAPI-3.1 with netcdf4.4 and intel compiler

(2016-02-28 19:47:19)
标签:

cmaq

smoke

modeling

installation

Requirements:

1. Assume hdf5, zlib, netcdf4.4 were successfully built, netcdf needs to be built with the same compiler.
2. The intel compiler version here is v2013 (v13)

Steps:

For no-coupling option only -nocpl
Assume base dir is: /opt/opt_app_tgz/ioapi/i31, target dir is: /opt/ioapi31_i13_nc4

0. create target dir
mkdir -p /opt/ioapi31_i13_nc4/Linux2_x86_64ifort
1.  set BIN env-var 
export BIN=Linux2_x86_64ifort
2. create $BIN dir, which also holds required libs. 
mkdir $BIN 
3. copy netcdf libs to $BIN
cp /opt/nc4.4_i13/lib/libnetcdf* $BIN 
4. copy hdf5 libs to $BIN - since ncdf is dynamically linked to hdf
cp /usr/local/hdf5/lib/libhdf5*.a $BIN 
5. copy zlib libs to $BIN
cp /opt/zlib-1.2.8/*.a $BIN
6. modify Top Level Makefile - $IOAPI/Makefile. switch to nocpl, the new file looks like:

BASEDIR    = /opt/opt_app_tgz/ioapi/i31
INSTALL    = /opt/ioapi31_i13_nc4
..
#CPLMODE    = cpl
#IOAPIDEFS  = -DIOAPICPL
#PVMINCL    = $(PVM_ROOT)/conf/$(PVM_ARCH).def

#               ****   Variants   ****
#
#  turn off PVM coupling mode
CPLMODE  = nocpl
IOAPIDEFS=
PVMINCL  = /dev/null

7. configure -> essentially using sed to modify the Makefile in 4 dirs
make configure

8. modify m3tools/Makefile, linking hdf and zlib libraries, change line "LIBS = ..." to:
LIBS  = -L${OBJDIR} -lioapi -lnetcdff -lnetcdf -lhdf5_hl -lhdf5 -lz $(OMPLIBS) \
$(ARCHLIB) $(ARCHLIBS)

The linking order is important, lhdf5_hl should be ahead of lhdf5

9. build ioapi lib and tool programs
make

10. install: copy lib and tool programs to target dir
make install

0

阅读 评论 收藏 转载 喜欢 打印举报/Report
  • 评论加载中,请稍候...
发评论

    发评论

    以上网友发言只代表其个人观点,不代表新浪网的观点或立场。

      

    新浪BLOG意见反馈留言板 电话:4000520066 提示音后按1键(按当地市话标准计费) 欢迎批评指正

    新浪简介 | About Sina | 广告服务 | 联系我们 | 招聘信息 | 网站律师 | SINA English | 会员注册 | 产品答疑

    新浪公司 版权所有