qt plugins and release builds

Christian Ehrlicher Ch.Ehrlicher at gmx.de
Wed Dec 12 06:30:04 CET 2007


Shane King schrieb:
> Shane King wrote:
> 
>> I still have the same issue I was having with my first attempted fix 
>> (not surprising since they both use the cache force method) of the 
>> variables getting set in CMakeCache.txt but flags.make not reflecting 
>> them, eg:
> 
> Found my problem, FindKDE4Internal.cmake overwrites what's being set in 
> FindQT4.cmake if the compiler is gcc, like so:
> 
> if (CMAKE_COMPILER_IS_GNUCXX)
>     set (KDE4_ENABLE_EXCEPTIONS -fexceptions)
>     # Select flags.
>     set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g")
>     set(CMAKE_CXX_FLAGS_RELEASE        "-O2")
>     set(CMAKE_CXX_FLAGS_DEBUG          "-g -O2 -fno-reorder-blocks 
> -fno-schedule-insns -fno-inline")
>     set(CMAKE_CXX_FLAGS_DEBUGFULL      "-g3 -fno-inline")
>     set(CMAKE_CXX_FLAGS_PROFILE        "-g3 -fno-inline -ftest-coverage 
> -fprofile-arcs")
>     set(CMAKE_C_FLAGS_RELWITHDEBINFO   "-O2 -g")
>     set(CMAKE_C_FLAGS_RELEASE          "-O2")
>     set(CMAKE_C_FLAGS_DEBUG            "-g -O2 -fno-reorder-blocks 
> -fno-schedule-insns -fno-inline")
>     set(CMAKE_C_FLAGS_DEBUGFULL        "-g3 -fno-inline")
>     set(CMAKE_C_FLAGS_PROFILE          "-g3 -fno-inline -ftest-coverage 
> -fprofile-arcs")
> 
> Since no matter what config we're in Qt is actually compiled with 
> QT_NO_DEBUG set under mingw, I've added:
> 
>     if (WIN32)
> 	  # qt is always compiled with QT_NO_DEBUG under mingw,
> 	  # so we need to compile stuff linked against it
> 	  # the same or otherwise QPluginLoader rejects plugins
>        add_definitions(-DQT_NO_DEBUG)
>     endif (WIN32)
> 
> Hopefully this should solve our issues.
> 
Please find another way to fix this!


Christian

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 250 bytes
Desc: OpenPGP digital signature
Url : http://mail.kde.org/pipermail/kde-windows/attachments/20071212/f5c5c561/attachment.pgp 


More information about the Kde-windows mailing list