回 帖 发 新 帖 刷新版面

主题:ubuntu系统下gfortran代替inelfortran编译程序问题请教

在编译一个程序包时,提示可以用inelfortran和gfortran编译
但给的文件默认用ifort,我想用gfortran编译这个程序,请问下面的Makefile.local如何更改?
我用64位ubuntu 12.04,不知道gfortran的库文件在哪儿。

# DEFMKL = MKL or NOMKL
DEFMKL = MKL
MKLDIR = /opt/intel/MKL/lib/64       #这句不知道怎么改,gfortran用apt-get安装的,不知道库放哪儿了!
MKLLIBS = -L$(MKLDIR) -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -liomp5

# 2. Compiler/linker choices for serial/parallel compilation
F95     = ifort
MPIF95  = ifort


目前只知道ifort要改成gfortran

回复列表 (共14个回复)

沙发

请各路高手指点啊!

板凳

安装ifort后,编译没问题,运行时总是提示一个库文件找不到,
 error while loading shared libraries: libhdf5.so.0: cannot open shared object file: No such file or director
网上也没查到解决办法。
编译其他程序ifort均能正常使用。
再次请教修改成gfortran的方法。

3 楼

编译另外一个算例时,编译时出错:
fortcom: Severe: **Internal compiler error: internal abort** Please report this error along with the circumstances in which it occurred in a Software Problem Report.  Note: File and line given may not be explicit cause of this error.

ipo-4: error #11005: multi-object compilation 4 returned error status 3
ifort: error #10014: problem during multi-file optimization compilation (code 3)
make: *** [****] 错误 3

4 楼

64位系统安装ifort比较麻烦,上面的错误有人说可能是ifort与系统不兼容。
不知大家有没有遇到过类似问题。
我编译运行另外一个fortran程序就不存在这个问题。

5 楼

-------------

6 楼

[quote]-------------[/quote]
哈哈哈哈哈

7 楼

是我的问题太低级了吗?

两位高手都不屑出手?

我在linux下编译程序,目前还是新手,请多多指教!

8 楼

以前主要是自己編一些小程序,还能应付。
随着程序逐渐增大,想借鉴一下网上开源程序的思想。但大部分开源程序都是基于linux的。调试时出现了很多问题。
希望大侠们多多指点。

9 楼

在linux中总是会遇到一些奇怪的错误。比如我在windows下正常的程序,在ubuntu下编译好,运行就提示下面的错误。
open(unit=100,file="tecbin.plt",form="UNFORMATTED")

错误提示:
sue: unformatted io not allowed
apparent state: unit 100 named tecbin.plt
lately writing sequential unformatted external IO
已放弃 (核心已转储)

10 楼

周围用linux系统编程的太少了!所以只能发到网上求助。

linux俺是半路出家,希望高手不要见笑。

我来回复

您尚未登录,请登录后再回复。点此登录或注册