爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
楼主: 小莹子

WPS安装——metgrib.exe未生成(未解决)

[复制链接]
发表于 2017-10-31 21:51:27 | 显示全部楼层
小莹子 发表于 2017-10-31 20:41
您好,我没懂安装netcdf指定编译器,是什么意思?不好意思

编译的时候加上FC=pgf90
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2017-10-31 23:45:47 | 显示全部楼层
尽头的尽头 发表于 2017-10-31 21:51
编译的时候加上FC=pgf90

使用命令 sudo ./configure --prefix=/usr/local/wrf/netcdf --disable-netcdf-4 FC=pgf90

checking whether a CURLOPT_KEYPASSWD is defined... no
configure: finding Fortran compiler (will not be used if Fortran API is not desired)
checking whether we are using the GNU Fortran compiler... no
checking whether pgf90 accepts -g... no
checking whether we are using the GNU Fortran 77 compiler... no
checking whether pgf90 accepts -g... no
configure: setting up Fortran 90
checking what FC is set to... pgf90
checking for Fortran flag to compile .f90 files... unknown
configure: error: Fortran could not compile .f90 files
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2017-10-31 23:55:11 | 显示全部楼层
小莹子 发表于 2017-10-31 23:45
使用命令 sudo ./configure --prefix=/usr/local/wrf/netcdf --disable-netcdf-4 FC=pgf90

checking w ...

sudo ./configure --prefix=/usr/local/wrf/netcdf --disable-netcdf-4 FC=gfortran
之后使用 make check 显示 All 7 tests passed
make install / sudo make install出现下面错误:

make[2]: 对“install-exec-am”无需做任何事。
test -z "/usr/local/wrf/netcdf/include" || /bin/mkdir -p "/usr/local/wrf/netcdf/include"
/bin/install -c -m 644 netcdf.h '/usr/local/wrf/netcdf/include'
/bin/install: "netcdf.h" 与"/usr/local/wrf/netcdf/include/netcdf.h" 为同一文件
make[2]: *** [install-includeHEADERS] 错误 1
make[2]: 离开目录“/usr/local/wrf/netcdf/include”
make[1]: *** [install-am] 错误 2
make[1]: 离开目录“/usr/local/wrf/netcdf/include”
make: *** [install-recursive] 错误 1
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2017-11-1 00:10:48 | 显示全部楼层
小莹子 发表于 2017-10-31 23:55
sudo ./configure --prefix=/usr/local/wrf/netcdf --disable-netcdf-4 FC=gfortran
之后使用 make che ...

sudo./configure --disable-dap --disable-netcdf-4 --prefix=/usr/local/wrf/netcdf FC=gfortran成功
sudo  ./configure --disable-dap --disable-netcdf-4 --prefix=/usr/local/wrf/netcdf FC=pgf90失败。
我明天再试一试,有点着急了,就给您发的消息有点多,打扰了
密码修改失败请联系微信:mofangbao
发表于 2017-11-1 09:48:01 | 显示全部楼层
小莹子 发表于 2017-10-31 20:40
我在台式机上装的,就是PGI,然后WRF已经跑起来了,不可能是ifort等编译器,

netcdf也需要编译器编译,你安装netcdf之前要告诉系统我要用pgi编译,是需要指定一下,你现在只会照着装,其中的原理估计还是不大明白。
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2017-11-1 11:15:06 | 显示全部楼层
愛、星晴 发表于 2017-11-1 09:48
netcdf也需要编译器编译,你安装netcdf之前要告诉系统我要用pgi编译,是需要指定一下,你现在只会照着装 ...

是的,我不明白,只会照着装,然后就失败了之后,就找不到根源问题,我尝试指定编译器安装,是centos7.0,我指定了FC=pgf90失败,然后FC=gfortran安装成功netcdf,我在尝试下一步,谢谢您
密码修改失败请联系微信:mofangbao
发表于 2017-11-1 12:24:13 | 显示全部楼层
小莹子 发表于 2017-10-31 23:45
使用命令 sudo ./configure --prefix=/usr/local/wrf/netcdf --disable-netcdf-4 FC=pgf90

checking w ...

不清楚你的具体情况为啥pgf会失败,你可以尝试所有的都用gfortran和gcc编译,看这样能否成功编译wrf,如果可以再继续查找pgi哪里出了问题
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2017-11-1 12:47:45 | 显示全部楼层
小莹子 发表于 2017-11-1 00:10
sudo./configure --disable-dap --disable-netcdf-4 --prefix=/usr/local/wrf/netcdf FC=gfortran成功
...

我这里有点先入为主了,FC=gfortran只能在目录/usr/local/netcdf下才能成功,我自己的目录/usr/local/wrf/netcdf失败。
对应的修改了.bashrc。
export NETCDF=/usr/local/wrf/netcdf
export NETCDF_LIB=/usr/local/netcdf/lib
export NETCDF_INC=/usr/local/netcdf/include
export PATH=/usr/local/netcdf/bin:/usr/local/netcdf/include:/usr/local/netcdf/lib:/usr/local/netcdf/share/man:$PATH
export CC=/usr/bin/gcc
export CXX=$PGI/bin/pgcc
export FC=$PGI/bin/pgf90
export F90=$PGI/bin/pgf90
export LD_LIBRARY=$LD_LIBRARY_PATH:/usr/local/netcdf/lib

之后的WRF安装选择的时候PGI(pgf90/gcc)和gfortran不符合,硬着头皮跑了下,安装失败——problems building executables,这个问题我之前碰到过,归根结底是netcdf的安装和环境配置路径不一致。但我已经进行了相应的路径修改。

针对这台电脑,我现在已经无法验证是否是没有指定编译器,才导致WPS安装失败,因为我WRF都跑步下去。只能换回原来的不指定编译器安装。

谢谢您。
密码修改失败请联系微信:mofangbao
 楼主| 发表于 2017-11-1 13:04:32 | 显示全部楼层
尽头的尽头 发表于 2017-11-1 12:24
不清楚你的具体情况为啥pgf会失败,你可以尝试所有的都用gfortran和gcc编译,看这样能否成功编译wrf,如 ...

好的嘞,我多试一试,感谢您的时间和耐心。怎么检查PGI是否有问题那?我之前用pgf90命令是出现了pgf90-Warning-No files to process
密码修改失败请联系微信:mofangbao
发表于 2017-11-1 17:14:03 | 显示全部楼层
小莹子 发表于 2017-11-1 13:04
好的嘞,我多试一试,感谢您的时间和耐心。怎么检查PGI是否有问题那?我之前用pgf90命令是出现了pgf90-Wa ...

有可能是pgi没有安装好
密码修改失败请联系微信:mofangbao
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Copyright ©2011-2014 bbs.06climate.com All Rights Reserved.  Powered by Discuz! (京ICP-10201084)

本站信息均由会员发表,不代表气象家园立场,禁止在本站发表与国家法律相抵触言论

快速回复 返回顶部 返回列表