wxSQLite3 and wxWidgets

Talk here about issues with one of the components hosted at wxCode, or suggest features for it.
Uskok
In need of some credit
In need of some credit
Posts: 2
Joined: Mon Sep 28, 2015 6:33 am

wxSQLite3 and wxWidgets

Postby Uskok » Mon Sep 28, 2015 7:25 am

Dear All,

I'm compiling wxSQLite3 3.2.1 and wxWidgets 3.0.2 with TDM64-GCC 4.9.2 under Windows.

My lib\ gcc_dll\mswu\wx\Setup.h is modified and the debug part is not commented anymore.

Code: Select all

#ifdef NDEBUG
   #define wxDEBUG_LEVEL 0
#else
   #define wxDEBUG_LEVEL 2
#endif


This makes the problem to link release version of wxSQLite3 (missing wxAssert, wxTrace, etc.) because there is small error in makefile.gcc

ifeq ($(WX_DEBUG),1)
__WXDEBUG_DEFINE_p = -D__WXDEBUG__
else <- else statement is missing
__WXDEBUG_DEFINE_p = -DNDEBUG
endif

I would also suggest to modified CXXFLAGS and CPPFLAGS flags.

CXXFLAGS ?= -fno-keep-inline-dllexport -std=gnu++11
CPPFLAGS ?= -fno-keep-inline-dllexport -std=gnu++11

Best Regards,

Uskok

utelle
Moderator
Moderator
Posts: 767
Joined: Tue Jul 05, 2005 10:00 pm
Location: Cologne, Germany
Contact:

Re: wxSQLite3 and wxWidgets

Postby utelle » Tue Sep 29, 2015 8:03 pm

Uskok wrote:My lib\ gcc_dll\mswu\wx\Setup.h is modified and the debug part is not commented anymore.

Code: Select all

#ifdef NDEBUG
   #define wxDEBUG_LEVEL 0
#else
   #define wxDEBUG_LEVEL 2
#endif


This makes the problem to link release version of wxSQLite3 (missing wxAssert, wxTrace, etc.) because there is small error in makefile.gcc

ifeq ($(WX_DEBUG),1)
__WXDEBUG_DEFINE_p = -D__WXDEBUG__
else <- else statement is missing
__WXDEBUG_DEFINE_p = -DNDEBUG
endif

Up to now all build files were generated using the tool bakefile 0.2.9. Unfortunately bakefile is heavily outdated ... and the new version is still work in progress and not adopted by wxWidgets itself. Maybe there is a way to tweak bakefile to generate the missing lines, but I'm far from being a bakefile expert.

In fact, I'm considering to move to another build system due to the deficiencies of bakefile. However, almost all tools have their drawbacks. So nothing is decided yet ...

Uskok wrote:I would also suggest to modified CXXFLAGS and CPPFLAGS flags.

CXXFLAGS ?= -fno-keep-inline-dllexport -std=gnu++11
CPPFLAGS ?= -fno-keep-inline-dllexport -std=gnu++11

CXXFLAGS and CPPFLAGS are configurable flags. So you are free to add the definitions you prefer. You can even modify the makefile to your likings (as you did with the setup.h file).

Believe it or not, out there are still people using pre C++11, and even wxWidgets itself does not define these flags.

Since wxSQLite3 consists of just 1 source file and a few header files, just adding the files to your project instead of compiling them as a separate library would also be an option.

Sorry to have no better answer for you.

Regards,

Ulrich

Uskok
In need of some credit
In need of some credit
Posts: 2
Joined: Mon Sep 28, 2015 6:33 am

Re: wxSQLite3 and wxWidgets

Postby Uskok » Wed Sep 30, 2015 11:33 am

Hi Ulrich,

First, I would like to thank you for the very nice job what you done with the wxSQLite3 library.
Your suggestion to add wxSQLite3 source to my project could be one of the options for me.
It is possible to add the description of the Debug/Release problem in “Readme.txt”? I am sure, the other people hit the same problem.
Just one question. Why did you remove "dbadmin" application from make sequence? It is nice and useful.

Best Regards,

Uskok


Return to “wxCode”

Who is online

Users browsing this forum: No registered users and 2 guests