不能在Ubuntu上使用gfortran和Abaqus 2016
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了不能在Ubuntu上使用gfortran和Abaqus 2016相关的知识,希望对你有一定的参考价值。
我正在尝试在Ubuntu 16.04上使用gfortran和Abaqus 2016。我已经根据这个修改了.env文件:http://home.iitk.ac.in/~saiwal/computing/abaqus2016-2017-gfortran-compiler/
所以gfortran本身不会再给我任何错误了。但在使用abaqus -verify -user_std -verbose之后
我明白了:
Begin Compiling Abaqus/Standard User Subroutines
Sun Dec 17 20:08:48 2017
Compiling std_user.f
Current directory: /tmp/konrad_std_user_15200
File to compile: /tmp/konrad_std_user_15200/std_user.f
>>> gfortran -c -fPIC -I/home/konrad/verify -I. -I/home/konrad/Simulia/solver/linux_a64/code/bin/SMAExternal/pmpi-9.1.2/include std_user.f
End Compiling Abaqus/Standard User Subroutines
Begin Linking Abaqus/Standard User Subroutines
Abaqus Error: The Abaqus user subroutine library could not be found.
This may indicate a problem with the Abaqus installation.
Please contact your system Administrator for further assistance.
Exception: (<class 'driverExceptions.UserSubroutineLibraryError'>, UserSubroutineLibraryError(), <traceback object at 0x1b88cf8>)
Traceback (most recent call last):
File "SMAPyaModules/SMAPyaDriverPy.m/src/driverAnalysis.py", line 201, in run
File "SMAPyaModules/SMAPyaDriverPy.m/src/driverStandard.py", line 80, in analyze
File "SMAPyaModules/SMAPyaDriverPy.m/src/driverSharedLibrary.py", line 344, in run
File "SMAPyaModules/SMAPyaDriverPy.m/src/driverSharedLibrary.py", line 571, in link
UserSubroutineLibraryError
Abaqus/Analysis exited with errors
Running: /home/konrad/Simulia/solver/linux_a64/code/bin/eliT_CheckLicense
Arguments: ['-standard', '-location']
License for standard is available.
答案
丢失了两件事:
- CAA包(从2016版开始,安装程序被分成几个文件)
CAA developer software for Abaqus APIs: output database (ODB) C++ API,
user subroutines API,Abaqus Scripting Interface API, and SIMULIA Co-Simulation
Engine C++ API. This software includes libraries and .h header files.
The CAA (Component Application Architecture) API software is needed for
using user subroutines and compiling and building ODB, SIM, or results file
postprocessing applications.
It is recommended that you always install the CAA (API) software, even if
you are not sure that you will need it; otherwise, you may find that some
components need to be installed later before you can upgrade to a fix
pack (hot fix).
- 在lnx86_64.env文件中我改变了行:
fortCmd = "gfortran" # <-- Fortran compiler
cppCmd = "gcc" # <-- C++ compiler
至
fortCmd = "gfortran" # <-- Fortran compiler
cppCmd = "gfortran" # <-- C++ compiler
因此,对于将来运行的任何参考,将link_sl
和compile_fortran
更改为:
compile_fortran = (fortCmd + " -c -fPIC -I%I")
link_sl = (fortCmd +
" -gcc-version=%i -fPIC -shared " +
"%E -Wl,-soname,%U -o %U %F %A %L %B -Wl,-Bdynamic " +
` " -lifport -lifcoremt")
fortCmd = "gfortran" # <-- Fortran compiler
cppCmd = "gfortran" # <-- C++ compiler
以上是关于不能在Ubuntu上使用gfortran和Abaqus 2016的主要内容,如果未能解决你的问题,请参考以下文章
在 Windows 上使用 GFortran 在 Matlab 中创建 Mex 文件