Smile linking with GCC windows

The engine.
Post Reply
pilar
Posts: 2
Joined: Thu Jul 03, 2008 12:24 pm
Location: Belgium

Smile linking with GCC windows

Post by pilar »

Hi all,
I'm new with C++ and I am using CodeBlocks for the moment. I've tried to compile VC version of Smile and also gycwin_gcc but none of them link correctly...
It seems I'm missing something, some linkage errors I'm not being able to solve with forums...

Here the first errors I get, but all of them are the same:

C:\work\Smile_vc8\main.cpp|20|undefined reference to `DSL_network::DSL_network()'|
C:\work\Smile_vc8\main.cpp|23|undefined reference to `DSL_network::AddNode(int, char const*)'|
C:\work\Smile_vc8\main.cpp|26|undefined reference to `DSL_idArray::DSL_idArray(bool)'|
C:\work\Smile_vc8\main.cpp|27|undefined reference to `DSL_idArray::Add(char const*)'|
C:\work\Smile_vc8\main.cpp|28|undefined reference to `DSL_idArray::Add(char const*)'|

....



Main.cpp is the example one in the SmileWiki, it includes "smile.h".

If someone could help me, please, I'm not able to solve it on my own and I'm getting mad.

Thanks very much,
Pilar
shooltz[BayesFusion]
Site Admin
Posts: 1417
Joined: Mon Nov 26, 2007 5:51 pm

Re: Smile linking with GCC windows

Post by shooltz[BayesFusion] »

You'll need to tell the linker to use smile.lib (automatic linking is only supported in Visual C++). I've never used CodeBlocks, so I can't give you more assistance, other than pointing to section 1.11.8 in the CodeBlocks online documentation.
pilar
Posts: 2
Joined: Thu Jul 03, 2008 12:24 pm
Location: Belgium

Post by pilar »

Thanks very much but I had already tried to link manually and it does not work.
Finally, I've changed to VC... :(
cs
Posts: 2
Joined: Thu Jul 10, 2008 9:33 pm

Linux

Post by cs »

I have the same problem using the linux version of smile. Although i have linked smile with -lsmile, I get the same error message like mentioned above.

Does someone know a solution for this problem for a linux machine?
shooltz[BayesFusion]
Site Admin
Posts: 1417
Joined: Mon Nov 26, 2007 5:51 pm

Re: Linux

Post by shooltz[BayesFusion] »

Can you post your gcc command line here?
Post Reply