Clinton Stimpson wrote:
> 
> I personally would prefer a Qt version check

This compiles:

 diff --git a/Source/QtDialog/CMakeSetup.cxx 
b/Source/QtDialog/CMakeSetup.cxx
 index 995929e..d1fbe9f 100644
 --- a/Source/QtDialog/CMakeSetup.cxx
 +++ b/Source/QtDialog/CMakeSetup.cxx
 @@ -79,12 +79,14 @@ int main(int argc, char** argv)

   QApplication app(argc, argv);

 -#if defined(KWSYS_CP_UTF8)
 +// #if defined(KWSYS_CP_UTF8)
   QTextCodec* utf8_codec = QTextCodec::codecForName("UTF-8");
 -  QTextCodec::setCodecForCStrings(utf8_codec);
   QTextCodec::setCodecForLocale(utf8_codec);
 +#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0)
 +  QTextCodec::setCodecForCStrings(utf8_codec);
   QTextCodec::setCodecForTr(utf8_codec);
 #endif
 +// #endif

   // clean out standard Qt paths for plugins, which we don't use anyway
   // when creating Mac bundles, it potentially causes problems


but I don't think it's better, I didn't runtime-test it, and I don't know 
what would trigger the KWSYS_CP_UTF8 to be defined anyway as it is not on my 
system. I just wanted to compile-out the new code.

If you can runtime-test the behavior of the new lines with Qt 5, I'd say go 
ahead and commit that.

Thanks,

Steve.


-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to