Hello,
I am an OpenSees user who is trying to create a new material for the first time. I am starting by working through the ElasticPPCPP example and I've run into a snag. I am using Visual Studio 2010 for the first time to create the dll. I find that the file compiles at step 20 which seemed odd to me. When I copy the resulting dll file to my folder containing the example1.tcl and my OpenSees executable (I'm running v.2.3.1) and run the example file, I get the message "WARNING could not create uniaxialMaterial ElasticPPcpp".
If I try to continue the instructions (up to step 24), Visual Studio fails to compile the files and I get the following messages:
error LNK2005:_DLMain@12 already defined in win32Functions.obj (the associated files is mfcs100ud.lib)
error LNK1169: one or more multiply defined symbols found (the associated files is ElasticPPCPP.dll)
Is my first problem an issue with the version of OpenSees that I'm trying to use to run the example file? I know that the instructions call for v.2.2.0? I'm kind of lost here and all I really want to do is edit the source code for an existing material and make a new material for me to play with in my analyses.
Any help would be greatly appreciated!
Problem with the ElasticPPCPP example
Moderators: silvia, selimgunay, Moderators
-
- Posts: 140
- Joined: Sun Oct 03, 2010 11:36 pm
- Location: Hong Kong
Re: Problem with the ElasticPPCPP example
Your version of Visual Studio?
Research Assistant Professor, The Hong Kong Polytechnic University
guanlin@polyu.edu.hk
guanlin@polyu.edu.hk
Re: Problem with the ElasticPPCPP example
I'm facing the same problem. Did you solve it out? (Win10 64bit, visual studio 2017, 2.5.0)
1>dllmain.cpp
1>win32Functions.obj : error LNK2005: _DllMain@12 already defined in win32Functions.obj
1> Creating library E:\OpenseesSecondary\source code\DEVELOPER\material\cpp\ElasticPPcpp\Release\ElasticPPcpp.lib and object E:\OpenseesSecondary\source code\DEVELOPER\material\cpp\ElasticPPcpp\Release\ElasticPPcpp.exp
1>E:\OpenseesSecondary\source code\DEVELOPER\material\cpp\ElasticPPcpp\Release\ElasticPPcpp.dll : fatal error LNK1169: one or more multiply defined symbols found
1>Done building project "ElasticPPcpp.vcxproj" -- FAILED.
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
1>dllmain.cpp
1>win32Functions.obj : error LNK2005: _DllMain@12 already defined in win32Functions.obj
1> Creating library E:\OpenseesSecondary\source code\DEVELOPER\material\cpp\ElasticPPcpp\Release\ElasticPPcpp.lib and object E:\OpenseesSecondary\source code\DEVELOPER\material\cpp\ElasticPPcpp\Release\ElasticPPcpp.exp
1>E:\OpenseesSecondary\source code\DEVELOPER\material\cpp\ElasticPPcpp\Release\ElasticPPcpp.dll : fatal error LNK1169: one or more multiply defined symbols found
1>Done building project "ElasticPPcpp.vcxproj" -- FAILED.
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========