summaryrefslogtreecommitdiffstats
path: root/Source/QtDialog
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-11-22 13:41:16 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2013-11-22 13:41:16 (GMT)
commitd121a8cb66c7f610c57aa6447f7671a5dd4a8730 (patch)
treeabaab1711c8bc029162ee37c176e27b3f34bf115 /Source/QtDialog
parenta6080587aa9a581021ae6d463b17cda295bc1966 (diff)
parent8ad8a9b1a6ecd9ae57597803afcac3bd839bd0fe (diff)
downloadCMake-d121a8cb66c7f610c57aa6447f7671a5dd4a8730.zip
CMake-d121a8cb66c7f610c57aa6447f7671a5dd4a8730.tar.gz
CMake-d121a8cb66c7f610c57aa6447f7671a5dd4a8730.tar.bz2
Merge topic 'cmake-credits'
8ad8a9b cmake-gui: Reference LGPLv2.1 when redistributing Qt
Diffstat (limited to 'Source/QtDialog')
-rw-r--r--Source/QtDialog/CMakeLists.txt7
-rw-r--r--Source/QtDialog/CMakeSetupDialog.cxx11
2 files changed, 18 insertions, 0 deletions
diff --git a/Source/QtDialog/CMakeLists.txt b/Source/QtDialog/CMakeLists.txt
index f1f4649..4308a4d 100644
--- a/Source/QtDialog/CMakeLists.txt
+++ b/Source/QtDialog/CMakeLists.txt
@@ -102,6 +102,13 @@ if(APPLE)
MACOSX_PACKAGE_LOCATION Resources)
endif()
+if(CMake_GUI_DISTRIBUTE_WITH_Qt_LGPL)
+ install(FILES ${CMake_SOURCE_DIR}/Licenses/LGPLv2.1.txt
+ DESTINATION ${CMAKE_DATA_DIR}/Licenses)
+ set_property(SOURCE CMakeSetupDialog.cxx
+ PROPERTY COMPILE_DEFINITIONS CMake_GUI_DISTRIBUTE_WITH_Qt_LGPL)
+endif()
+
set(CMAKE_INCLUDE_CURRENT_DIR ON)
add_executable(cmake-gui WIN32 MACOSX_BUNDLE ${SRCS})
diff --git a/Source/QtDialog/CMakeSetupDialog.cxx b/Source/QtDialog/CMakeSetupDialog.cxx
index 8565cad..1903c02 100644
--- a/Source/QtDialog/CMakeSetupDialog.cxx
+++ b/Source/QtDialog/CMakeSetupDialog.cxx
@@ -34,6 +34,7 @@
#include "QCMakeCacheView.h"
#include "AddCacheEntry.h"
#include "FirstConfigure.h"
+#include "cmSystemTools.h"
#include "cmVersion.h"
QCMakeThread::QCMakeThread(QObject* p)
@@ -814,9 +815,19 @@ void CMakeSetupDialog::doAbout()
"\n"
"CMake GUI maintained by csimsoft,\n"
"built using Qt %2 (qt-project.org).\n"
+#ifdef CMake_GUI_DISTRIBUTE_WITH_Qt_LGPL
+ "\n"
+ "The Qt Toolkit is Copyright (C) Digia Plc and/or its subsidiary(-ies).\n"
+ "Qt is licensed under terms of the GNU LGPLv2.1, available at:\n"
+ " \"%3\""
+#endif
);
msg = msg.arg(cmVersion::GetCMakeVersion());
msg = msg.arg(qVersion());
+#ifdef CMake_GUI_DISTRIBUTE_WITH_Qt_LGPL
+ std::string lgpl = cmSystemTools::GetCMakeRoot()+"/Licenses/LGPLv2.1.txt";
+ msg = msg.arg(lgpl.c_str());
+#endif
QDialog dialog;
dialog.setWindowTitle(tr("About"));