- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
I am mixing Visual C++ 6 Visual Fortran 6.6 by calling Fortran subroutines with a C++ main program. I am getting this math error when building it. The error is as follows:
I have searched the help pages and have not found any help. The project settings for my project are below.
The Project Settings for Link are:
The Project Settings for Fortran are:
The Project Settings for C++ are:
Does anyone know what might be the problem?
dfor.lib(matherr.obj) : error LNK2005: __matherr already defined in LIBCD.lib(matherr.obj) Debug/ExampC4.exe : fatal error LNK1169: one or more multiply defined symbols found Error executing link.exe.
I have searched the help pages and have not found any help. The project settings for my project are below.
The Project Settings for Link are:
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /incremental:yes /pdb:"Debug/test.pdb" /debug /machine:I386 /out:"Debug/test.exe" /pdbtype:sept
The Project Settings for Fortran are:
/check:bounds /compile_only /dbglibs /debug:full /nologo /traceback /warn:argument_checking /warn:nofileopt /module:"Debug/" /object:"Debug/" /pdbfile:"Debug/DF60.PDB"
The Project Settings for C++ are:
/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"Debug/test.pch" /YX /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
Does anyone know what might be the problem?
Thank youvery much!
コピーされたリンク
7 返答(返信)
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
I suppose you are linking math libraries both from your C++ and your Fortran code.
If you were lucky, you might succeed by excluding libcd.lib from the link, hoping that
dfor.lib can take care of the references from C++.
While this forum is a good place to find experts on such problems, you may be aware
that HP took responsibility for CVF support away from Intel, so these compiler versions
appear headed for orphan status.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
We still welcome CVF questions here, however.
The usual solution to this problem is to explicitly add dfor.lib to the list of libraries in the Link tab.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
"We still welcome CVF questions here, however."
That's reassuring, Steve. IVF is coming along nicely but it hasn't been in the running as long as D(C)VF. I'm sure that there are IVF customers who have stabilized D(C)VF applications without ever intending to ever migrate them to IVF.
BTW, how does D(C)VF matherr.obj differ from MSCV's matherr.obj? BION, matherr is the singular omission from the MSCV CRT source.
Ciao,
Gerry T.
That's reassuring, Steve. IVF is coming along nicely but it hasn't been in the running as long as D(C)VF. I'm sure that there are IVF customers who have stabilized D(C)VF applications without ever intending to ever migrate them to IVF.
BTW, how does D(C)VF matherr.obj differ from MSCV's matherr.obj? BION, matherr is the singular omission from the MSCV CRT source.
Ciao,
Gerry T.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Thanks for your quick reply! But how can I add dfor.lib to the list of libraries?
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Project..Settings..Link. In the field of additional libraries/objects, put dfor.lib first in the list.
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Thank you, steve. I cannot find the item of dfor.libin the field of object/libraries. Is that the problem of my version?
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
You have to add the dfor.lib by yourself. Just type itat the beginning of the list.
Christian
