Linking Error

For developers writing C++, Fortran, Java, code who have questions or comments to make.

Moderators: silvia, selimgunay, Moderators

Post Reply
rgrayeli
Posts: 20
Joined: Fri Mar 14, 2008 8:18 am
Location: UC Berkeley
Contact:

Linking Error

Post by rgrayeli »

Again same error message:

element.lib(TclElementCommands.obj) : error LNK2019: unresolved external symbol "int __cdecl TclModelBuilder_addSingleFPBearing(void *,struct Tcl_Interp *,int,char const * *,class Domain *,class TclModelBuilder *,int)" (?TclModelBuilder_addSingleFPBearing@@YAHPAXPAUTcl_Interp@@HPAPBDPAVDomain@@PAVTclModelBuilder@@H@Z) referenced in function "int __cdecl TclModelBuilderElementCommand(void *,struct Tcl_Interp *,int,char const * *,class Domain *,class TclModelBuilder *)" (?TclModelBuilderElementCommand@@YAHPAXPAUTcl_Interp@@HPAPBDPAVDomain@@PAVTclModelBuilder@@@Z)
1>.\..\..\bin/openSees.exe : fatal error LNK1120: 1 unresolved externals
Roozbeh
PhD student
GeoEngineering
UC, Berkeley
aizen
Posts: 38
Joined: Sun Nov 29, 2009 2:15 pm

link error new CVS OPENSEES FILES

Post by aizen »

Dear all


I have the same problem with the new OPENSEES source files (from CVS).

element.lib(TclElementCommands.obj) : error LNK2019 "int __cdecl TclModelBuilder_addSingleFPBearing(void *,struct Tcl_Interp *,int,char const * *,class Domain *,class TclModelBuilder *,int)" (?TclModelBuilder_addSingleFPBearing@@YAHPAXPAUTcl_Interp@@HPAPBDPAVDomain@@PAVTclModelBuilder@@H@Z) "int __cdecl TclModelBuilderElementCommand(void *,struct Tcl_Interp *,int,char const * *,class Domain *,class TclModelBuilder *)" (?TclModelBuilderElementCommand@@YAHPAXPAUTcl_Interp@@HPAPBDPAVDomain@@PAVTclModelBuilder@@@Z)

material.lib(TclModelBuilderUniaxialMaterialCommand.obj) : error LNK2019: "void * __cdecl OPS_NewSAWSMaterial(void)"
\bin/openSeesTk.exe : fatal error LNK1120





I don't have this problem with the CVS OPENSEES source files that I downloaded this summer.

Please, can somebody help me?

Cordially

AIZEN
rgrayeli
Posts: 20
Joined: Fri Mar 14, 2008 8:18 am
Location: UC Berkeley
Contact:

Re: link error new CVS OPENSEES FILES

Post by rgrayeli »

Hi Aizen;

I temporarily fixed that problem by simply disabling the lines that calling "TclModelBuilder_addSingleFPBearing" function from outside. you can go to "TclElementCommands.cpp" file and disable these lines as follow:


/*
else if (strcmp(argv[1],"singleFPBearing") == 0) {
int eleArgStart = 1;
int result = TclModelBuilder_addSingleFPBearing(clientData, interp, argc, argv,
theTclDomain, theTclBuilder, eleArgStart);
return result;
}
*/
Roozbeh
PhD student
GeoEngineering
UC, Berkeley
aizen
Posts: 38
Joined: Sun Nov 29, 2009 2:15 pm

Post by aizen »

Dear rgrayeli

thanks for your help.

I hope that someone can fix this problem in CVS source files.

yours sincerly

Aizen
aizen
Posts: 38
Joined: Sun Nov 29, 2009 2:15 pm

Post by aizen »

Hi rgrayeli

I have tried your Solution but still problem persists.

2>material.lib(TclModelBuilderUniaxialMaterialCommand.obj) : error LNK2019: riferimento al simbolo esterno "void * __cdecl OPS_NewSAWSMaterial(void)" (?OPS_NewSAWSMaterial@@YAPAXXZ) non risolto nella funzione "int __cdecl TclModelBuilderUniaxialMaterialCommand(void *,struct Tcl_Interp *,int,char const * *,class TclModelBuilder *,class Domain *)" (?TclModelBuilderUniaxialMaterialCommand@@YAHPAXPAUTcl_Interp@@HPAPBDPAVTclModelBuilder@@PAVDomain@@@Z)
1>material.lib(TclModelBuilderUniaxialMaterialCommand.obj) : error LNK2019: riferimento al simbolo esterno "void * __cdecl OPS_NewSAWSMaterial(void)" (?OPS_NewSAWSMaterial@@YAPAXXZ) non risolto nella funzione "int __cdecl TclModelBuilderUniaxialMaterialCommand(void *,struct Tcl_Interp *,int,char const * *,class TclModelBuilder *,class Domain *)" (?TclModelBuilderUniaxialMaterialCommand@@YAHPAXPAUTcl_Interp@@HPAPBDPAVTclModelBuilder@@PAVDomain@@@Z)
2>.\..\..\bin/openSeesTk.exe : fatal error LNK1120: 1 esterni non risolti
1>.\..\..\bin/openSees.exe : fatal error LNK1120: 1 esterni non risolti
2>Il log di compilazione è stato salvato in 'file://c:\OpenSees\Win32\obj\openSeesTk\release\BuildLog.htm'
2>OpenSeesTk - 2 errore/i, 0 avviso/i
1>Il log di compilazione è stato salvato in 'file://c:\OpenSees\Win32\obj\openSees\release\BuildLog.htm'
1>OpenSees - 2 errore/i, 0 avviso/i


I have changed only the file
TclElementCommands.cpp
and disable these lines as follow:


/*
else if (strcmp(argv[1],"singleFPBearing") == 0) {
int eleArgStart = 1;
int result = TclModelBuilder_addSingleFPBearing(clientData, interp, argc, argv,
theTclDomain, theTclBuilder, eleArgStart);
return result;
}
*/

Should I change other lines of this file
or other files?

Please can you help me?

Thanks

Best Regards

AIZEN
rgrayeli
Posts: 20
Joined: Fri Mar 14, 2008 8:18 am
Location: UC Berkeley
Contact:

Post by rgrayeli »

aizen;

it seems you are missing more than one external library. you just simply can search for current missing function throughout the opensees file and disable this specific function but the think is you may can not use this element for your model so I prefer you wait until these errors get fixed by Frank.
Roozbeh
PhD student
GeoEngineering
UC, Berkeley
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Post by fmk »

i have updated the windows projects.
Post Reply