WilliamXIII / oscats

Automatically exported from code.google.com/p/oscats
Other
0 stars 0 forks source link

C example does not work on Windows #1

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Build the example given in the C code using the OSCAT binary module.
2. Running it through command line generates the following error

(Test.exe:40840): OSCATS-CRITICAL **: oscats_cont_model_set_param_by_index: asse
rtion `OSCATS_IS_CONT_MODEL(model) && index < model->Np' failed

What is the expected output? What do you see instead?
The test example should work!

What version of the product are you using? On what operating system?
Oscats-0.5 on Windows XP Professional. I'm using the pre-built liboscats-0.dll.

Please provide any additional information below.
Based on my very limited understanding of the source code, it seems that 
oscats_cont_model_set_param_by_index() fails because I could not find an 
implementation for oscats_cont_model_get_type(). There are other functions 
oscats_XXX_get_type() for which I could not find an implementation. I wonder if 
the Windows dll was mistakenly built without these implementations?

Thanks for your help,
AStudentForLife

Original issue reported on code.google.com by apteashu...@gmail.com on 25 Aug 2011 at 1:20

GoogleCodeExporter commented 8 years ago
MSVC requires an import library to link against a DLL.  I was able to get 
MSVC++ Express 10 to successfully link and run the example program on Windows 
XP professional using the attached MSVC-created import library.  Future 
distributions of Windows binaries will include import libraries for convenience.

Original comment by michael....@gmail.com on 31 Aug 2011 at 2:29

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks for sharing the import library. I used this to build the test example 
and the behavior has not changed much. Attached are the output files and the 
standard output. I've reduced the number of examinees from 1000 to 100 to limit 
the put of data it generate on the standard output. Are these assertions normal?

Original comment by apteashu...@gmail.com on 1 Sep 2011 at 9:50

Attachments:

GoogleCodeExporter commented 8 years ago
Also attached is the output from HandleEx showing the modules loaded by the 
test program. Note that it is using "liboscats-0.dll" (dated 8/23/2010 9:26 PM) 
that was shipped with the source.

Would it be possible for you to share your version of this dll and I'll give it 
a try to see if it makes any difference.

Original comment by apteashu...@gmail.com on 1 Sep 2011 at 10:22

Attachments:

GoogleCodeExporter commented 8 years ago
The attached image indicates that the dynamic linker picked up an old (2.12) 
version of libgobject-2.0.0.dll from GraphViz (at the bottom of the list), but 
a more-recent (2.26) version of libglib-2.0.0.dll.  OSCATS requires at least 
glib-2.22, and I imagine that running with DLLs of different versions of glib 
and gobject is liable to cause instabilities.  Try removing GraphViz from the 
%PATH% (or reordering the directories) to have the dynamic linker pick up the 
correct version of the gobject DLL.

Original comment by michael....@gmail.com on 1 Sep 2011 at 11:36

GoogleCodeExporter commented 8 years ago
I downloaded the latest version of Graphviz (2.28) and the sample program is 
working now. Thanks for your help.

Original comment by apteashu...@gmail.com on 9 Sep 2011 at 12:17

GoogleCodeExporter commented 8 years ago

Original comment by michael....@gmail.com on 9 Sep 2011 at 12:47

GoogleCodeExporter commented 8 years ago

Original comment by michael....@gmail.com on 4 Nov 2011 at 4:48