Skip to content

Commit

Permalink
Back to build our LLVMClang package only (#1306).
Browse files Browse the repository at this point in the history
  • Loading branch information
agarny committed Jun 7, 2017
1 parent 5bf4581 commit eae8101
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 15 deletions.
28 changes: 19 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ OPTION(USE_PREBUILT_QWT_PACKAGE "Use the pre-built version of the Qwt package" O
OPTION(USE_PREBUILT_SUNDIALS_PACKAGE "Use the pre-built version of the SUNDIALS package" ON)
OPTION(USE_PREBUILT_ZINC_PACKAGE "Use the pre-built version of the Zinc package" ON)
OPTION(USE_PREBUILT_ZLIB_PACKAGE "Use the pre-built version of the zlib package" ON)
SET(USE_PREBUILT_LLVMCLANG_PACKAGE OFF)

# Make sure that we are using the compiler we support

Expand Down Expand Up @@ -122,7 +123,8 @@ INCLUDE(${CMAKE_SOURCE_DIR}/src/3rdparty/QtWebKit/CMakeLists.txt)
# WE CAN BUILD QtWebKit AS A PACKAGE?...

IF(WIN32)
SET(WEBKIT WebKit)
#---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
# SET(WEBKIT WebKit)
ENDIF()

IF(ENABLE_TESTS)
Expand Down Expand Up @@ -186,8 +188,9 @@ IF(APPLE)
QtSvg
${QT_TEST}
QtWebChannel
QtWebKit
QtWebKitWidgets
#---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
# QtWebKit
# QtWebKitWidgets
QtWidgets
QtXml
QtXmlPatterns
Expand Down Expand Up @@ -812,7 +815,9 @@ SET(PLUGINS
widget/WebViewerWidget
widget/ZincWidget
)
SET(PLUGINS)
SET(PLUGINS
thirdParty/LLVMClang
)

FOREACH(PLUGIN ${PLUGINS})
SET(PLUGIN_DIR src/plugins/${PLUGIN})
Expand Down Expand Up @@ -1121,13 +1126,16 @@ IF(WIN32)
SET(TEST)
ENDIF()

FOREACH(QT_LIBRARY CLucene Core Gui Help Multimedia MultimediaWidgets Network OpenGL Positioning PrintSupport Qml Quick Sensors Sql Svg ${TEST} WebChannel WebKit WebKitWidgets Widgets Xml XmlPatterns)
#---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
# FOREACH(QT_LIBRARY CLucene Core Gui Help Multimedia MultimediaWidgets Network OpenGL Positioning PrintSupport Qml Quick Sensors Sql Svg ${TEST} WebChannel WebKit WebKitWidgets Widgets Xml XmlPatterns)
FOREACH(QT_LIBRARY CLucene Core Gui Help Multimedia MultimediaWidgets Network OpenGL Positioning PrintSupport Qml Quick Sensors Sql Svg ${TEST} WebChannel Widgets Xml XmlPatterns)
WINDOWS_DEPLOY_QT_LIBRARY(Qt5${QT_LIBRARY})
ENDFOREACH()

FOREACH(QT_LIBRARY icudt icuin icuuc)
WINDOWS_DEPLOY_QT_LIBRARY(${QT_LIBRARY}57)
ENDFOREACH()
#---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
# FOREACH(QT_LIBRARY icudt icuin icuuc)
# WINDOWS_DEPLOY_QT_LIBRARY(${QT_LIBRARY}57)
# ENDFOREACH()

# Qt plugins required by OpenCOR

Expand Down Expand Up @@ -1259,7 +1267,9 @@ ELSE()
SET(TEST)
ENDIF()

FOREACH(QT_LIBRARY CLucene Core DBus Gui Help Multimedia MultimediaWidgets Network OpenGL Positioning PrintSupport Qml Quick Sensors Sql Svg ${TEST} WebChannel WebKit WebKitWidgets Widgets XcbQpa Xml XmlPatterns)
#---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
# FOREACH(QT_LIBRARY CLucene Core DBus Gui Help Multimedia MultimediaWidgets Network OpenGL Positioning PrintSupport Qml Quick Sensors Sql Svg ${TEST} WebChannel WebKit WebKitWidgets Widgets XcbQpa Xml XmlPatterns)
FOREACH(QT_LIBRARY CLucene Core DBus Gui Help Multimedia MultimediaWidgets Network OpenGL Positioning PrintSupport Qml Quick Sensors Sql Svg ${TEST} WebChannel Widgets XcbQpa Xml XmlPatterns)
IF( "${QT_LIBRARY}" STREQUAL "WebKit"
OR "${QT_LIBRARY}" STREQUAL "WebKitWidgets")
SET(REAL_QT_LIBRARY_DIR ${QT_WEBKIT_LIBRARIES_DIR})
Expand Down
14 changes: 8 additions & 6 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <QSettings>
#include <QVariant>

#ifdef Q_OS_WIN
#include <QWebSettings>
#endif
//---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
//#ifdef Q_OS_WIN
// #include <QWebSettings>
//#endif

//==============================================================================

Expand Down Expand Up @@ -304,9 +305,10 @@ int main(int pArgC, char *pArgV[])
// Note: the below must absolutely be done after calling guiApp->exec() and
// before deleting guiApp...

#ifdef Q_OS_WIN
QWebSettings::clearMemoryCaches();
#endif
//---ISSUE1306--- REENABLE THE BELOW ONCE WE CAN BUILD QtWebKit...
//#ifdef Q_OS_WIN
// QWebSettings::clearMemoryCaches();
//#endif

// Delete our application

Expand Down
8 changes: 8 additions & 0 deletions src/plugins/thirdParty/LLVMClang/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,12 @@ IF(USE_PREBUILT_LLVMCLANG_PACKAGE)
e09d9093001e748a0469923c9f076300a9768cda)
ENDIF()
ELSE()
# Ignore some warnings

IF(WIN32)
SET(PACKAGE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4251 /wd4275")
ENDIF()

# Build LLVM+Clang as an external project

SET(PACKAGE_BUILD ${PACKAGE_NAME}Build)
Expand All @@ -112,6 +118,8 @@ ELSE()
https://github.com/opencor/llvmclang
GIT_TAG
${GIT_TAG}
CMAKE_CACHE_ARGS
-DCMAKE_CXX_FLAGS:STRING=${PACKAGE_CXX_FLAGS}
CMAKE_GENERATOR
${CMAKE_GENERATOR}
CMAKE_ARGS
Expand Down

0 comments on commit eae8101

Please sign in to comment.