Linking the Intel Math Kernel Library (MKL) with ABAQUS 2019 user-subroutines - subroutine

I'm currently struggeling with linking / activating the MKL for ABAQUS 2019 user-subroutines. In detail I want to make use of the LAPACK functions dgetrf, dgetrs and xerbla in one of my UMAT subroutines.
While compiling, I get the following error message (hope the German version does not bother you):
LemaitreDamageModel.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol "xerbla" in Funktion "solve_for_inverse".
LemaitreDamageModel.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol "dgetrf" in Funktion "solve_for_inverse".
LemaitreDamageModel.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol "dgetrs" in Funktion "solve_for_inverse".
I then had a look at my Abaqus batch file, which looks like this:
#echo off
IF NOT DEFINED abaqus_intel_compiler (
call "C:\Program Files (x86)\Intel\ifort\compilers_and_libraries\windows\bin\ifortvars.bat" intel64
set abaqus_intel_compiler=1
)
"C:\SIMULIA\CAE\2019\win_b64\code\bin\ABQLauncher.exe" %*
The called batch file ifortvars.bat holds the following line, which looks like the MKL is already poperly incoorporated in the process:
if exist "%BIN_ROOT%..\mkl\bin\mklvars.bat" #call "%BIN_ROOT%..\mkl\bin\mklvars.bat" %C_TARGET_ARCH% %TARGET_VS% %LP64_ILP64%
The file mklvar.bat is definetly there. I also tried to do the call via a direct path to the file, but that also didn't helped.
However, what can I do to get rid of the above error message? Obviously, there is still something wrong with the MKL linking.

Related

How to create an executable ESP-IDF Project on a local server

im trying to relocate my latest ESP-IDF project from my harddrive into my local server, so I can work on it on multiple devices.
Sadly i was facing some issues building the project. So I tried to create the example project "Hello World" on my local server and build it. Exactly the same console ouput pops out:
Executing task: cmake -G Ninja -DPYTHON_DEPS_CHECKED=1 -DESP_PLATFORM=1 .. <
-- Found Git: C:/Users/user/.espressif/tools/idf-git/2.30.1/cmd/git.exe (found version "2.30.1.windows.1")
-- The C compiler identification is GNU 8.4.0
-- The CXX compiler identification is GNU 8.4.0
-- The ASM compiler identification is GNU
-- Found assembler: C:/Users/user/.espressif/tools/xtensa-esp32-elf/esp-2021r1-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc.exe
-- Check for working C compiler: C:/Users/user/.espressif/tools/xtensa-esp32-elf/esp-2021r1-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc.exe
-- Check for working C compiler: C:/Users/user/.espressif/tools/xtensa-esp32-elf/esp-2021r1-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc.exe -- broken
CMake Error at C:/Users/user/.espressif/tools/cmake/3.16.4/share/cmake-3.16/Modules/CMakeTestCCompiler.cmake:60 (message):
The C compiler
"C:/Users/user/.espressif/tools/xtensa-esp32-elf/esp-2021r1-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc.exe"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: //192.168.0.10/projects/my_project/build/CMakeFiles/CMakeTmp
Run Build Command(s):C:/Users/user/.espressif/tools/ninja/1.10.2/ninja.exe cmTC_294a8 && [1/2] Building C object CMakeFiles/cmTC_294a8.dir/testCCompiler.c.obj
[2/2] Linking C executable cmTC_294a8
FAILED: cmTC_294a8
cmd.exe /C "cd . && C:\Users\user\.espressif\tools\xtensa-esp32-elf\esp-2021r1-8.4.0\xtensa-esp32-elf\bin\xtensa-esp32-elf-gcc.exe -mlongcalls -Wno-frame-address CMakeFiles/cmTC_294a8.dir/testCCompiler.c.obj -o cmTC_294a8 && cd ."
"\\192.168.0.10/projects/my_project\build\CMakeFiles\CMakeTmp"
CMD.EXE wurde mit dem oben angegebenen Pfad als aktuellem Verzeichnis gestartet.
UNC-Pfade werden nicht unterstützt.
Stattdessen wird das Windows-Verzeichnis als aktuelles Verzeichnis gesetzt.
xtensa-esp32-elf-gcc.exe: error: CMakeFiles/cmTC_294a8.dir/testCCompiler.c.obj: No such file or directory
xtensa-esp32-elf-gcc.exe: fatal error: no input files
compilation terminated.
ninja: build stopped: subcommand failed.
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
C:/Users/user/esp/esp-idf/tools/cmake/project.cmake:311 (__project)
CMakeLists.txt:6 (project)
-- Configuring incomplete, errors occurred!
See also "//192.168.0.10/projects/my_project/build/CMakeFiles/CMakeOutput.log".
See also "//192.168.0.10/projects/my_project/build/CMakeFiles/CMakeError.log".
The terminal process "C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe -Command cmake -G Ninja -DPYTHON_DEPS_CHECKED=1 -DESP_PLATFORM=1 .." terminated with exit code: 1.
Searching for my problem lead me to similar threads, but sadly none of them were helping me.
Anyone experienced similar problems with a local server?
thanks in advance
Edit:
this might clearify my question even more. Here is my CMakeError.log:
Determining if the C compiler works failed with the following output:
Change Dir: //192.168.0.10/projects/my_project/build/CMakeFiles/CMakeTmp
Run Build Command(s):C:/Users/user/.espressif/tools/ninja/1.10.2/ninja.exe cmTC_294a8 && [1/2] Building C object CMakeFiles/cmTC_294a8.dir/testCCompiler.c.obj
[2/2] Linking C executable cmTC_294a8
FAILED: cmTC_294a8
cmd.exe /C "cd . && C:\Users\user\.espressif\tools\xtensa-esp32-elf\esp-2021r1-8.4.0\xtensa-esp32-elf\bin\xtensa-esp32-elf-gcc.exe -mlongcalls -Wno-frame-address CMakeFiles/cmTC_294a8.dir/testCCompiler.c.obj -o cmTC_294a8 && cd ."
"\\192.168.0.10\d\projects\my_project\build\CMakeFiles\CMakeTmp"
CMD.EXE wurde mit dem oben angegebenen Pfad als aktuellem Verzeichnis gestartet.
#CMD.Exe was started from current directory with above stated Path
UNC-Pfade werden nicht unterstützt.
# UNC Path is not supported
Stattdessen wird das Windows-Verzeichnis als aktuelles Verzeichnis gesetzt.
#instead windows-directory will be used as directory
xtensa-esp32-elf-gcc.exe: error: CMakeFiles/cmTC_294a8.dir/testCCompiler.c.obj: No such file or directory
xtensa-esp32-elf-gcc.exe: fatal error: no input files
compilation terminated.
ninja: build stopped: subcommand failed.
for my english-speaking fellas... the German part is roughly translated 1 line below.
You're trying to compile a project directly off a Windows network share? That's a marginal use case. I don't think there are many tools which support this, for the simple reason that nobody does such a thing. At the very least, mount the remote share as a drive in your computer.
I'd recommend creating a git repo, uploading your code there. That's a standard solution for sharing code.

Abaqus UMAT subroutine - error after execution (warning LNK4210?)

I am trying to run my first UMAT subroutine with an ABAQUS job.
Fortran compiler seems to be linked to ABAQUS, since Abaqus command
abaqus verify -user_std
results to pass the check
Abaqus/Standard with user subroutines
...PASS
Continuing...
But trying to run the subroutine, an error occurs. The message file of the job reports:
Abaqus/Standard Analysis exited with an error - Please see the message file for possible error messages if the file exists.*
No message file (.msg) is produced by the software for the job.
The .log file reports the following:
Analysis initiated from SIMULIA established products
Abaqus JOB JOB NAME
Abaqus 2020
Abaqus License Manager checked out the following licenses:
Abaqus/Standard checked out 5 tokens from Flexnet server COMPUTER NAME
<1019 out of 1024 licenses remain available>.
Begin Compiling Abaqus/Standard User Subroutines
21/09/2021 12:15:52
Intel(R) Fortran Intel(R) 64 Compiler Classic for applications running on Intel(R) 64, Version 2021.3.0 Build ***************
Copyright (C) 1985-2021 Intel Corporation. All rights reserved.
End Compiling Abaqus/Standard User Subroutines
Begin Linking Abaqus/Standard User Subroutines
Creazione della libreria standardU.lib e dell'oggetto standardU.exp
libirc.lib(fast_mem_ops.obj) : warning LNK4210: .CRT section exists; there may be unhandled static initializers or terminators
End Linking Abaqus/Standard User Subroutines
21/09/2021 12:16:00
Begin Analysis Input File Processor
21/09/2021 12:16:00
Run pre.exe
21/09/2021 12:16:05
End Analysis Input File Processor
Begin Abaqus/Standard Analysis
21/09/2021 12:16:05
Run standard.exe
21/09/2021 12:16:06
Abaqus Error: Abaqus/Standard Analysis exited with an error - Please see the
message file for possible error messages if the file exists.
Begin SIM Wrap-up
21/09/2021 12:16:06
Run SMASimUtility.exe
21/09/2021 12:16:06
End SIM Wrap-up
Abaqus/Analysis exited with errors
I have checked some previous questions on the web, but it's hard to get further for me.
Any contribution is welcome.
Try adding the following to your environment file:
link_sl='LINK /NODEFAULTLIB:LIBCMT.LIB /dll /def:%E /out:%U %F %A %L %B'
Source

Makefile command line arguments confused with MinGW directory paths

I'm trying to run a make all command but I get a very confusing error, it seems as if the arguments from 'cl' are mistaken as directory paths in MinGW. The output I'm getting:
cl /EHsc /MD /nologo /D_SILENCE_STDEXT_HASH_DEPRECATION_WARNINGS -nologo /O2 -DN
DEBUG -DUSE_CBC -DUSE_CLP /D__WIN32__ /Iinclude\\src\\windows /DGFLAGS_DLL_DECL=
/DGFLAGS_DLL_DECLARE_FLAG= /DGFLAGS_DLL_DEFINE_FLAG= /Iinclude /I. -DUSE_GLOP -
DUSE_BOP -c examples\\cpp\\costas_array.cc /Foobjs\\costas_array.obj
That's the cl command, not the warnings and errors (note that cl /EHsc actually gets mistaken for 'C:/MinGW/MSYS/1.0/EHsc', etc...):
cl : Command line warning D9024 : unrecognized source file type 'C:/MinGW/MSYS/1
.0/EHsc', object file assumed
cl : Command line warning D9027 : source file 'C:/MinGW/MSYS/1.0/EHsc' ignored
cl : Command line warning D9024 : unrecognized source file type 'C:/MinGW/MSYS/1
.0/MD', object file assumed
cl : Command line warning D9027 : source file 'C:/MinGW/MSYS/1.0/MD' ignored
cl : Command line warning D9024 : unrecognized source file type 'C:/MinGW/MSYS/1
.0/nologo', object file assumed
cl : Command line warning D9027 : source file 'C:/MinGW/MSYS/1.0/nologo' ignored
... etc ... Until there's the fatal error at the end
cl : Command line warning D9024 : unrecognized source file type 'C:/MinGW/MSYS/1
.0/I.', object file assumed
cl : Command line warning D9027 : source file 'C:/MinGW/MSYS/1.0/I.' ignored
cl : Command line warning D9027 : source file 'C:/MinGW/MSYS/1.0/Foobjs/costas_a
rray.obj' ignored
costas_array.cc
examples\cpp\costas_array.cc(27): fatal error C1083: Cannot open include file: '
ortools/base/callback.h': No such file or directory
make: *** [objs\\costas_array.obj] Error 2
Any help about why is this happening would be highly appreciated, I am not very experienced in this matter.
It's the MSYS shell doing these translations for you in an attempt of being helpful.
With the tools typically used in this shell, it's no problem because arguments/options start with a - or -- (the Unix and/or GNU convention). It starts getting into your way as soon as you need command-line tools following the Microsoft convention for options and flags, using /.
Unfortunately, for the original MSYS, I'm not aware of a way to disable this translation. But there is one for MSYS2, see the question I asked about it: You just need to set an environment variable, e.g.
export MSYS2_ARG_CONV_EXCL=\*
So, my suggestion would be you upgrade your tools to MSYS2 and use this.

Matlab error using accelerator mode

I´m building a complex model in Simulink which took 50 minutes to run completely. I would like to use the accelerator mode but, after install the right version of virtual studio and SDK (http://www.mathworks.com/matlabcentral/answers/96050-how-can-i-set-up-microsoft-visual-studio-2008-express-edition-for-use-with-matlab-7-7-r2008b-on-32) I still have this error:
### Building the Accelerator target for model: deg_final_FAST
### Generating code into build directory: H:\ale peticchia_March2016\Simulink\model\deg_final_FAST_accel_rtw
Warning: Function H:\ale peticchia_March2016\Simulink\model\input.m has
the same name as a MATLAB builtin. We suggest you rename the function to
avoid a potential name conflict.
### Invoking Target Language Compiler on deg_final_FAST.rtw
tlc
-r
H:\ale peticchia_March2016\Simulink\model\deg_final_FAST_accel_rtw\deg_final_FAST.rtw
C:\Program Files\MATLAB\R2008b\rtw\c\accel\accel.tlc
-OH:\ale peticchia_March2016\Simulink\model\deg_final_FAST_accel_rtw
-IC:\Program Files\MATLAB\R2008b\rtw\c\accel
-IH:\ale peticchia_March2016\Simulink\model\deg_final_FAST_accel_rtw\tlc
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\mw
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\lib
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\blocks
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\fixpt
-IC:\Program Files\MATLAB\R2008b\stateflow\c\tlc
-aEnforceIntegerDowncast=1
-aFoldNonRolledExpr=1
-aInlineInvariantSignals=0
-aInlineParameters=0
-aLocalBlockOutputs=1
-aRollThreshold=5
-aForceBlockIOInitOptimize=0
-aGenerateReport=0
-aGenCodeOnly=0
-aRTWVerbose=1
-aIncludeHyperlinkInReport=0
-aLaunchReport=0
-aGenerateTraceInfo=0
-aForceParamTrailComments=0
-aGenerateComments=1
-aIgnoreCustomStorageClasses=1
-aIncHierarchyInIds=0
-aMaxRTWIdLen=31
-aShowEliminatedStatements=0
-aIncDataTypeInIds=0
-aInsertBlockDesc=0
-aIgnoreTestpoints=0
-aSimulinkBlockComments=1
-aInlinedPrmAccess="Literals"
-aTargetFcnLib="ansi_tfl_table_tmw.mat"
-aIsPILTarget=0
-aLogVarNameModifier="rt_"
-aGenerateFullHeader=1
-aGenerateTraceInfo=0
-aIgnoreTestpoints=0
-p10000
### Loading TLC function libraries
...
### Initial pass through model to cache user defined code
....
### Caching model source code
......................................................................
### Writing header file deg_final_FAST_acc_types.h
### Writing header file deg_final_FAST_acc.h
### Writing source file deg_final_FAST_acc.c
.
### Writing header file deg_final_FAST_acc_private.h
### Writing source file deg_final_FAST_acc_data.c
### Writing header file rt_nonfinite.h
### Writing source file rt_nonfinite.c
.
### Writing header file rtGetInf.h
### Writing source file rtGetInf.c
### Writing header file rtGetNaN.h
### Writing source file rtGetNaN.c
.
### TLC code generation complete.
Warning: Function H:\ale peticchia_March2016\Simulink\model\input.m has
the same name as a MATLAB builtin. We suggest you rename the function to
avoid a potential name conflict.
.
### Processing Template Makefile: C:\Program Files\MATLAB\R2008b\rtw\c\accel\accel_vcx64.tmf
### deg_final_FAST.mk which is generated from C:\Program Files\MATLAB\R2008b\rtw\c\accel\accel_vcx64.tmf is up to date
### Building deg_final_FAST: .\deg_final_FAST.bat
H:\ale peticchia_March2016\Simulink\model\deg_final_FAST_accel_rtw>call "C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\Tools\/../../VC/vcvarsall" AMD64
Setting environment for using Microsoft Visual Studio 2008 Beta2 x64 tools.
WindowsSdkDir not found
Microsoft (R) Program Maintenance Utility, Version 9.00.21022.08
Copyright (C) Microsoft Corporation. Alle Rechte vorbehalten.
C:\PROGRA~1\MATLAB\R2008b\rtw\c\tools\vctools.mak(8) : fatal error U1052: Datei "ntwin32.mak" nicht gefunden
Stop.
The make command returned an error of 2
'An_error_occurred_during_the_call_to_make' is not recognized as an internal or external command,
operable program or batch file.
### Real-Time Workshop build procedure for model: 'deg_final_FAST' aborted due to an error.
Warning: Function H:\ale peticchia_March2016\Simulink\model\input.m has
the same name as a MATLAB builtin. We suggest you rename the function to
avoid a potential name conflict.
Warning: Function H:\ale peticchia_March2016\Simulink\model\input.m has
the same name as a MATLAB builtin. We suggest you rename the function to
avoid a potential name conflict.
Warning: Function H:\ale peticchia_March2016\Simulink\model\input.m has
the same name as a MATLAB builtin. We suggest you rename the function to
avoid a potential name conflict.
??? Error using ==> Degradation_model_matlab_fast at 27
Problem creating Accelerator MEX file for model 'deg_final_FAST'. Error
returned is:
Error using ==> genMakefileAndBuild at 1079
Error(s) encountered while building model "deg_final_FAST".
Do you have suggestions?
Thanks for your help!
matlab R2008b
win7 64bit

MongoDB C++ Driver Compile Error

Try to work with MongoDb driver on VS 2010.
After include the fresh compiled MongoDB driver (nightly) using boost 1.4.9
have this error :
mongoclient.lib(1): error C2059: Syntaxfehler: '<'
mongoclient.lib(2): error C2018: Unbekanntes Zeichen '0x60'
mongoclient.lib(3): error C2059: Syntaxfehler: 'Ungültiges Suffix für Zahl'
mongoclient.lib(3): error C2018: Unbekanntes Zeichen '0x16'
............
fatal error C1003: Mehr als 100 Fehler gefunden; Kompilierung wird abgebrochen.
It is strongly recommended that you don't use the stand alone driver. Rather download and build the full mongodb source from git. This should get you the driver and header files (I don't have a windows box to test this with but this is true for OSX/Linux and the recommended solution for all platforms). Finally, link the library, don't include the .cpp file.
Best,
Charlie