爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博登陆

只需一步, 快速开始

搜索
查看: 5310|回复: 3

求助:WRF安装前Test #4: 和 NetCDF出现错误

[复制链接]

新浪微博达人勋

发表于 2020-4-22 23:25:41 | 显示全部楼层 |阅读模式

登录后查看更多精彩内容~

您需要 登录 才可以下载或查看,没有帐号?立即注册 新浪微博登陆

x
华为云服务器  CentOS 7.6 64bit with ARM
按照官网教程来的,到System Environment Tests 的Test #4出现问题,网上找了很久没查到解决方法

[root@ecs-kc1-large-2-linux-20200408152217 TESTS]# gcc -c -m64 TEST_4_fortran+c_c.c
gcc: error: unrecognized command line option ‘-m64’
[root@ecs-kc1-large-2-linux-20200408152217 TESTS]# gfortran -m64 TEST_4_fortran+c_f.o TEST_4_fortran+c_c.o
gfortran: error: TEST_4_fortran+c_f.o: No such file or directory
gfortran: error: TEST_4_fortran+c_c.o: No such file or directory
gfortran: error: unrecognized command line option ‘-m64’


然后没有解决之后准备直接安装NetCDF,到./configure这一步出现如下问题
[root@ecs-kc1-large-2-linux-20200408152217 netcdf-4.1.3]# ./configure --prefix=$DIR/netcdf --disable-dap \--disable-netcdf-4 --disable-shared
configure: netCDF 4.1.3
checking build system type... ./config.guess: unable to guess system type

This script, last modified 2009-11-20, has failed to recognize
the operating system you are using. It is advised that you
download the most up to date version of the config scripts from

  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
and
  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD

If the version you run (./config.guess) is already up to date, please
send the following data and any information you think might be
pertinent to <config-patches@gnu.org> in order to provide the needed
information to handle your system.

config.guess timestamp = 2009-11-20

uname -m = aarch64
uname -r = 4.18.0-80.7.2.el7.aarch64
uname -s = Linux
uname -v = #1 SMP Thu Sep 12 16:13:20 UTC 2019

/usr/bin/uname -p = aarch64
/bin/uname -X     =

hostinfo               =
/bin/universe          =
/usr/bin/arch -k       =
/bin/arch              = aarch64
/usr/bin/oslevel       =
/usr/convex/getsysinfo =

UNAME_MACHINE = aarch64
UNAME_RELEASE = 4.18.0-80.7.2.el7.aarch64
UNAME_SYSTEM  = Linux
UNAME_VERSION = #1 SMP Thu Sep 12 16:13:20 UTC 2019
configure: error: cannot guess build type; you must specify one

跪求指教^_^
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2020-4-23 08:26:09 | 显示全部楼层
-m64 是Linux系统的命令吧。你用的教程是 针对CentOS系统的吗
密码修改失败请联系微信:mofangbao
回复 支持 反对

使用道具 举报

新浪微博达人勋

发表于 2020-4-23 14:08:43 | 显示全部楼层
ARM的锅居多,因为不同平台编译器的使用存在区别的,X86-64的命令直接搬到ARM平台翻车很正常的
编译器说明如下
These `-m’ switches are supported in addition to the above on AMD x86-64 processors in 64-bit environments.
-m32
-m64
-mx32
Generate code for a 32-bit or 64-bit environment.

The -m32 option sets int, long and pointer to 32 bits and generates code that runs on any i386 system.
The -m64 option sets int to 32bits and long and pointer to 64 bits and generates code for AMD’s x86-64 architecture.
The -mx32 option sets int, long and pointer to 32 bits and generates code for AMD’s x86-64 architecture.
For darwin only the -m64 option turns off the -fno-pic and -mdynamic-no-pic options.
TESTS的内容去掉-m64就能过,但是configure肯定翻车,因为脚本本身就不支持你的系统LINUX-ARM,所以看看新的脚本有没有支持,要么换成X86-64的云机器再试,其他的就不要想了
密码修改失败请联系微信:mofangbao
回复 支持 反对

使用道具 举报

新浪微博达人勋

 楼主| 发表于 2020-4-24 22:36:55 | 显示全部楼层
SherlockMuco 发表于 2020-4-23 14:08
ARM的锅居多,因为不同平台编译器的使用存在区别的,X86-64的命令直接搬到ARM平台翻车很正常的
编译器说明 ...

谢谢,用X86-64机器已解决
密码修改失败请联系微信:mofangbao
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册 新浪微博登陆

本版积分规则

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

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

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