wxUSE_ANY must be defined Error Topic is solved

Do you have a question about makefiles, a compiler or IDE you are using and need to know how to set it up for wxWidgets or why it doesn't compile but other IDE's do ? Post your questions here.
Post Reply
philm
Experienced Solver
Experienced Solver
Posts: 88
Joined: Fri Dec 18, 2015 4:46 am

wxUSE_ANY must be defined Error

Post by philm »

Hello all,

I have a new installation of ubuntu 16.04 on my laptop. I downloaded and installed wxwidgets from the following site:

http://codelite.org/LiteEditor/WxWidgets31Binaries#toc2

I ensured that I have the correct commands in the compile and linker settings.

However, I am still receiving a wxUSE_ANY Error in the chkconf.h file. In this file, it states that I am not using the most up-to-date setup.h. Which is odd because on my other installations I ma using 3.1.0. Yes, I am using git as source control.

From the chkconf.h file, it states that I need to update mt local setup.h settings? Could someone explain how I do that?

I find it odd that this is the case since this is a new installation and I haven't written any code with this platform yet!
DavidHart
Site Admin
Site Admin
Posts: 4252
Joined: Thu Jan 12, 2006 6:23 pm
Location: IoW, UK

Re: wxUSE_ANY must be defined Error

Post by DavidHart »

Hi,
I ensured that I have the correct commands in the compile and linker settings.
What does that mean? Presumably you're using an IDE. Which one?

What did you put into those settings? What you should have put is that IDE's way of invoking the wx-config script; e.g. for CodeLite:

Code: Select all

$(shell wx-config --cxxflags)
$(shell wx-config --libs )
If you ran the wx-config script in a terminal and copied the results into the IDE, rather than invoking the script each time, make very sure that both entries correspond to the correct wx install. That's even more important if you copied over the entries from a previous ubuntu.

If that doesn't fix the issue, please post the relevant output from doing, in a terminal:

Code: Select all

wx-config --cxxflags
wx-config --libs all
and try building one of the wx samples from /usr/share/doc/wx-3.1-examples/examples/ (read the README and the script's --help output).

Regards,

David
philm
Experienced Solver
Experienced Solver
Posts: 88
Joined: Fri Dec 18, 2015 4:46 am

Re: wxUSE_ANY must be defined Error

Post by philm »

DavidHart wrote:Hi,
I ensured that I have the correct commands in the compile and linker settings.
What does that mean? Presumably you're using an IDE. Which one?

What did you put into those settings? What you should have put is that IDE's way of invoking the wx-config script; e.g. for CodeLite:

Code: Select all

$(shell wx-config --cxxflags)
$(shell wx-config --libs )
If you ran the wx-config script in a terminal and copied the results into the IDE, rather than invoking the script each time, make very sure that both entries correspond to the correct wx install. That's even more important if you copied over the entries from a previous ubuntu.

If that doesn't fix the issue, please post the relevant output from doing, in a terminal:

Code: Select all

wx-config --cxxflags
wx-config --libs all
and try building one of the wx samples from /usr/share/doc/wx-3.1-examples/examples/ (read the README and the script's --help output).

Regards,

David
Yes, that is what I was talking about! Rats, I knew that I had forgotten something! I missed the wx-conig --libs line!
Post Reply