Code::Blocks Forums

User forums => Help => Topic started by: gregn on February 15, 2006, 01:00:35 pm

Title: cannot find -lwxmsw
Post by: gregn on February 15, 2006, 01:00:35 pm
I know that there's a topic with the same subject, but I've tried everything that I found there, and nothing helped.

I would like to use wxWidgets as a static library. I compiled it with a batch file containing this:

cd C:\wxWidgets-2.6.2 \build\msw
mingw32-make -f makefile.gcc BUILD=release SHARED=1 MONOLITHIC=1 USE_XRC=1 UNICODE=0 VENDOR=cb
cd ..\..\contrib\build\stc
mingw32-make -f makefile.gcc BUILD=release SHARED=1 MONOLITHIC=1 USE_XRC=1 UNICODE=0 VENDOR=cb

Everything went fine (except for some warnings, but that's normal as far as I know), and compilation goes well, but when it gets to linking, I always end up with the error message in the subject...

Could anyone please help me?
Title: Re: cannot find -lwxmsw
Post by: thomas on February 15, 2006, 01:09:57 pm
SHARED=1 != static
Title: Re: cannot find -lwxmsw
Post by: gregn on February 15, 2006, 03:41:06 pm
Thanks a lot! It helpled!  :D
Title: Re: cannot find -lwxmsw
Post by: mayowa on February 16, 2006, 12:53:02 pm
funny enough i had the same problem this morning but i solved it by
mingw32-make -f makefile.gcc BUILD=release SHARED=1 MONOLITHIC=1 UNICODE=0

My question is , what exactly does SHARED=1 != static do?
Title: Re: cannot find -lwxmsw
Post by: Michael on February 16, 2006, 01:14:45 pm
If you would like to build wxWidgets as static library (.lib or .a) then you should use SHARED=0.

SHARED=1 if you would like to build wxWidgets as dynamic library (.dll, or .so i.e., shared object(s), in Linux).

Best wishes,
Michael
Title: Re: cannot find -lwxmsw
Post by: thomas on February 16, 2006, 01:24:42 pm
Quote
My question is , what exactly does SHARED=1 != static do?
SHARED=1 "is not equal" shared.

http://wxforum.shadonet.com/ is a forum specialised in questions referring to wxWidgets. You will find your answers there.
Title: Re: cannot find -lwxmsw
Post by: mayowa on February 16, 2006, 01:30:21 pm
Micheal, my mistake copied the wrong cmd
this is what i used: mingw32-make -f makefile.gcc BUILD=release MONOLITHIC=1 UNICODE=0
it complied as a static i guess that means SHARED=0 is the default.