Error LNK2019 while compiling with Dymola

403 views
Skip to first unread message

Christoph

unread,
Feb 14, 2013, 10:52:48 AM2/14/13
to bc...@googlegroups.com
Hello, I just wanted to start working with Dymola (2013 FD01) and BCVTB (1.2.0)

When I try running the example file TwoRooms the following errors occur:

Bibliothek "dymosim.lib" und Objekt "dymosim.exp" werden erstellt. [Libary "dymosim.lib" and object "dymosim.exp" are created]

dsmodel.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol [unresolved external symbol]  "_closeModelicaClient" in Funktion [referenced in function] "_Buildings_Utilities_IO_BCVTB_BaseClasses_closeClientSocket_M".

dsmodel.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol [unresolved external symbol]  "_establishModelicaClient" in Funktion [referenced in function] "_Buildings_Utilities_IO_BCVTB_BaseClasses_establishClientSocket_M".

dsmodel.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol [unresolved external symbol]  "_exchangeModelicaClient" in Funktion [referenced in function] "_Buildings_Utilities_IO_BCVTB_BaseClasses_exchangeReals_M".

dymosim.exe : fatal error LNK1120: 3 nicht aufgelöste externe Verweise.


This is also happening when I'm trying to built my own small testing model.

The error will occur when I launch Dymola via BCVTB ("simulateAndExit") as well as trying to compile directly within Dymola. 
 

Thierry Nouidui

unread,
Feb 14, 2013, 1:13:39 PM2/14/13
to bc...@googlegroups.com

I will suggest to delete any .obj, .lib, .exp, and .exe that you might have in the Two Rooms example folder and then try to run the example from the BCVTB again.

Note that the example  requires the BCVTB to run thus it won’t work if you compile it directly from Dymola.

 

Thanks!

 

Thierry

--
You received this message because you are subscribed to the Google Groups "bcvtb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bcvtb+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Christoph

unread,
Feb 15, 2013, 9:20:54 AM2/15/13
to bc...@googlegroups.com
Thank you for your fast reply!

I tried to deleted the mentioned files but the errors still occur. 

Christoph

unread,
Feb 17, 2013, 4:21:34 AM2/17/13
to bc...@googlegroups.com
When I try to run my really simple self built example (just an output from dymola, no inputs into it) I will get the same errors. 

But when I deactivate the BCVTB client in Dymola (activateInterface:false) the simulation does start.

Thierry Nouidui

unread,
Feb 19, 2013, 11:31:02 AM2/19/13
to bc...@googlegroups.com

The fact that you can’t even run the examples that come along with the BCVTB is uncommon since other users can.

Which version of the BCVTB are you using? 32 or 64 bit? Which version of Dymola are you using? 32 or 64 bit? Are you on a 32 or 64 bit Windows machine?

You might want to re-install the BCVTB to see whether this fixes the problem. Maybe something went wrong during the installation.

 

Best,

 

Thierry

--

Christoph

unread,
Feb 23, 2013, 6:16:14 AM2/23/13
to bc...@googlegroups.com
I now tried to clean my system (Windows 7, x64) totally. I uninstalled and reinstalled everything (Visual Studio 2008, Microsoft SDK, .Net, Dymola and BCVTB) and took a carefull look for getting the x64 versions.

then I tried to run the BCVTB Example "Dymola two Rooms"

When I run the example with a blank folder (only files are: build.xml, system.xml, tworoomstotal.mo and simulateandexit.mos) I will receive the same errors as described above.

After cleaning the folder again and directly launching the simulateAndExit.mos file will create the error with the missing bcvtb.h file. After deactivating the bcvt block within the simulation the model is directly simulate-able within dymola and working fine. After doing this I set the bcvtb module back to active state and run BCVTB. This time the simualtion seems to work out fine.  Dymola tells me taht the Integration started and gives me the statistics. But after calling terminal section ..."dsfinal.txt" creating (final states) dymola will stop responding and BCVTB will fail with a socket time out error. I treid to increase the time up to 10 minutes without any respons. Even Dymola will not open that I can see it on my screen.
Then I tried deleting the previously mentioned .obj, .lib, .exp, and .exe files (by the way, there is no .obj file within that directory). This will cause the same error es before, but this time Dymola at least shows up on my screen, but doesn't exit by its own.
In the simulation commands I noticed the error 

"Warning: Undeclared variable or command: Hidden.CompileWith64

 = false"

After commenting this line within the simualteAndExit.mos I will get back to my first errors (that with the 3 unresolved external symbols).
Then I can go back to the beginning and delete everything not initially needed and deactivate the BCVTB and try to run and can back to the cascade of errors and not launching programs...

I'm running 
BCVTB win 64 1.2.0
Dymola 2013 FD01
on a:
Intel Core i7 2670QM with 16 GB of RAM with windows 7 home premium.



Thierry Nouidui

unread,
Feb 23, 2013, 10:55:37 AM2/23/13
to bc...@googlegroups.com
I think that the problem is you are using the 64 bit version of the BCVTB with Dymola. This set-up requires Microsoft Visual Studio Professional (which is not free) as you can read from the installation manual (see releases note).

If you don't want to buy Visual Studio Professional, I will suggest you to use the 32 bit version of the BCVTB rather than the 64 bit version along with the 32 bit version of Dymola. 

Hope that fixes your problems.

Thanks!

Thierry

--
You received this message because you are subscribed to the Google Groups "bcvtb" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bcvtb+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
--------------------------------------
Thierry Stephane Nouidui, PhD

Simulation Research Group
Lawrence Berkeley National Laboratory
1 Cyclotron Road, MS 90R3147
Berkeley, CA 94720
(510) 495-2337 voice
email: TSNo...@lbl.gov
http://simulationresearch.lbl.gov
----------------------------------------

Christoph

unread,
Feb 24, 2013, 4:29:18 AM2/24/13
to bc...@googlegroups.com
Hello Thierry, thanks for your great help. 

This now finally works. By the way: I have the Visual Studio Professional so I was wondering why nothing was working.
But now, after installing BCVTB 32bit and using Dymola in 32bit mode everything is working as expected.

Sending you the best wishes from the Egyptian Red Sea Coast!

Christoph


Reply all
Reply to author
Forward
0 new messages