[metview] 90/97: Qt4 -> Qt5 changes

Alastair McKinstry mckinstry at moszumanska.debian.org
Tue Sep 1 09:18:58 UTC 2015


This is an automated email from the git hooks/post-receive script.

mckinstry pushed a commit to branch master
in repository metview.

commit 9c4f93307444ea6b30b1e97c9979a2c5eb076e98
Author: Alastair McKinstry <mckinstry at debian.org>
Date:   Thu Jul 30 00:08:27 2015 +0100

    Qt4 -> Qt5 changes
---
 debian/control           |    4 +-
 debian/patches/qt5.patch | 1398 ++++++++++++++++++++++++++++++----------------
 debian/patches/series    |    1 +
 debian/rules             |    1 +
 4 files changed, 921 insertions(+), 483 deletions(-)

diff --git a/debian/control b/debian/control
index f93fc82..b9222af 100644
--- a/debian/control
+++ b/debian/control
@@ -4,7 +4,7 @@ Priority: optional
 Maintainer: Alastair McKinstry <mckinstry at debian.org>
 Build-Depends: debhelper (>= 9), 
   flex, bison, libhdf5-dev, libpango1.0-dev, chrpath,
-  qt4-dev-tools, libqt4-dev, libqtwebkit-dev,
+  libqt5webkit5-dev,qt5-default, qtbase5-dev,
   libgrib-api-dev, libgrib-api-tools,
   libemos-dev, libboost1.55-dev,
   libmagics++-metview-dev, libmagics++-dev (>= 2.24.7-3),
@@ -12,7 +12,7 @@ Build-Depends: debhelper (>= 9),
   libcairo2-dev, pkg-config, swig, libexpat1-dev,
   libterralib-dev, ksh, libproj-dev,
   libgd-dev, imagemagick, libnetcdf-dev, libnetcdf-cxx-legacy-dev,
-   libopenjpeg-dev, cmake, flextra
+  libopenjpeg-dev, cmake, flextra
 Build-Conflicts: lesstif2-dev
 Standards-Version: 3.9.6
 Homepage: https://software.ecmwf.int/wiki/display/METV/Metview
diff --git a/debian/patches/qt5.patch b/debian/patches/qt5.patch
index b4e32b9..07b55af 100644
--- a/debian/patches/qt5.patch
+++ b/debian/patches/qt5.patch
@@ -1,53 +1,325 @@
-Author: Alastair McKinstry <mckinstry at debian.org>
-Description: Changes for Qt4 -> Qt5
-Last-Updated: 2015-05-17
-Forwarded: no
-
-Index: magics++-2.24.7/src/drivers/QtDriver.cc
-===================================================================
---- magics++-2.24.7.orig/src/drivers/QtDriver.cc
-+++ magics++-2.24.7/src/drivers/QtDriver.cc
-@@ -1238,12 +1238,12 @@ MAGICS_NO_EXPORT void QtDriver::renderTe
- 			tr.scale(1.,-1.);
- 			tr.translate(-x,-y);
- 			item->setTransform(tr);
--
- 			if(an !=0 &&  an != 360)
- 			{
--				item->translate(x,y);
--				item->rotate(an);
--				item->translate(-x,-y);	
-+				// item->translate(x,y);
-+				// item->rotate(an);
-+				// item->translate(-x,-y);	
-+                item->setTransform(QTransform().translate(x, y).rotate(an).translate(-x, -y));
- 			}
- 
- 			item->setPos(x0,y0);
-@@ -1329,7 +1329,7 @@ MAGICS_NO_EXPORT void QtDriver::renderTe
- 				item->setPos(x0,y0);
- 				
- 				if(an !=0 &&  an != 360)	
--					item->rotate(an);
-+					 item->setRotation(item->rotation() + an);
- 				
- 				QTransform tr;
- 				tr.scale(1.,-1.);
-Index: magics++-2.24.7/cmake/Qt5Macros.cmake
+Index: metview-4.5.6/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/CMakeLists.txt
++++ metview-4.5.6/CMakeLists.txt
+@@ -516,13 +516,15 @@ endif()
+ 
+ if( ENABLE_UI )
+ 
+-    find_package(Qt4 4.6.2 REQUIRED QtCore QtNetwork QtGui QtXml QtXmlPatterns) #  QtWebKit QtHelp
+-    if( QT_FOUND )
+-        include( ${QT_USE_FILE} )
+-        set( METVIEW_QT 1)
+-    else()
+-        message(FATAL_ERROR "Qt not found - this is required for the user interface")
+-    endif()
++    include( Qt5Extras )
++    find_package(Qt5Core REQUIRED)
++    find_package(Qt5Network REQUIRED)
++    find_package(Qt5Gui REQUIRED)
++    find_package(Qt5Xml REQUIRED)
++    find_package(Qt5XmlPatterns REQUIRED)
++    find_package(Qt5Widgets REQUIRED)
++    find_package(Qt5PrintSupport REQUIRED)
++    set( METVIEW_QT 1)
+ 
+ 
+     if( ENABLE_MOTIF )
+Index: metview-4.5.6/src/AppMod/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/AppMod/CMakeLists.txt
++++ metview-4.5.6/src/AppMod/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(savepool_MOC savepool.h)
++QT5_WRAP_CPP(savepool_MOC savepool.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       savepool 
+Index: metview-4.5.6/src/BufrExaminer/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/BufrExaminer/CMakeLists.txt
++++ metview-4.5.6/src/BufrExaminer/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(Bufr_MOC BufrExaminer.h)
++QT5_WRAP_CPP(Bufr_MOC BufrExaminer.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       BufrExaminer
+Index: metview-4.5.6/src/DebugTools/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/DebugTools/CMakeLists.txt
++++ metview-4.5.6/src/DebugTools/CMakeLists.txt
+@@ -2,8 +2,8 @@
+ ### TODO: bin/mvmon  bin/MvMonitor
+ 
+ 
+-QT4_WRAP_CPP(XServ_MOC XServ.h)
+-QT4_ADD_RESOURCES(XServ_RES XServ.qrc)
++QT5_WRAP_CPP(XServ_MOC XServ.h)
++QT5_ADD_RESOURCES(XServ_RES XServ.qrc)
+ 
+ 
+ set(xserv_srcs
+@@ -37,8 +37,8 @@ ecbuild_add_executable( TARGET       mvm
+ endif()
+ ################################
+ 
+-QT4_WRAP_CPP(MvMonitor_MOC ProcMonitor.h)
+-QT4_ADD_RESOURCES(MvMonitor_RES debug.qrc)
++QT5_WRAP_CPP(MvMonitor_MOC ProcMonitor.h)
++QT5_ADD_RESOURCES(MvMonitor_RES debug.qrc)
+ 
+ #message(STATUS "WRAP_CPP: ${MvMonitor_MOC}")
+ #message(STATUS "ADD_RES: ${MvMonitor_RES}")
+Index: metview-4.5.6/src/Desktop/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/CMakeLists.txt
++++ metview-4.5.6/src/Desktop/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(Desktop_MOC 
++QT5_WRAP_CPP(Desktop_MOC 
+                          MvQAdvancedSearch.h
+                          MvQBookmarks.h
+                          MvQEditor.h
+@@ -57,7 +57,7 @@ QT4_WRAP_CPP(Desktop_MOC
+                          Input.h
+ )
+ 
+-QT4_ADD_RESOURCES(Desktop_RES desktop.qrc)
++QT5_ADD_RESOURCES(Desktop_RES desktop.qrc)
+ 
+ set(desktop_srcs    MvMainQtBrowser.cc
+                     MvQ.cc
+Index: metview-4.5.6/src/FlextraExaminer/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/FlextraExaminer/CMakeLists.txt
++++ metview-4.5.6/src/FlextraExaminer/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(FlextraExaminer_MOC FlextraExaminer.h)
++QT5_WRAP_CPP(FlextraExaminer_MOC FlextraExaminer.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       FlextraExaminer
+Index: metview-4.5.6/src/GeopExaminer/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/GeopExaminer/CMakeLists.txt
++++ metview-4.5.6/src/GeopExaminer/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(Geop_MOC GeopExaminer.h)
++QT5_WRAP_CPP(Geop_MOC GeopExaminer.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       GeopExaminer
+Index: metview-4.5.6/src/GribExaminer/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/GribExaminer/CMakeLists.txt
++++ metview-4.5.6/src/GribExaminer/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(Grib_MOC GribExaminer.h)
++QT5_WRAP_CPP(Grib_MOC GribExaminer.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       GribExaminer
+Index: metview-4.5.6/src/MacroEditor/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/CMakeLists.txt
++++ metview-4.5.6/src/MacroEditor/CMakeLists.txt
+@@ -1,8 +1,8 @@
+ 
+-QT4_WRAP_CPP      (MacroEd_MOC MvMain.h FindTextDialog.h Highlighter.h MacroEdit.h FunctionListDialog.h mvplaintextedit.h
++QT5_WRAP_CPP      (MacroEd_MOC MvMain.h FindTextDialog.h Highlighter.h MacroEdit.h FunctionListDialog.h mvplaintextedit.h
+                    CodeTemplateDialog.h GotoLineDialog.h RunDialog.h TabsDialog.h VerbFunctionHelpDialog.h MacroEdit.h)
+-QT4_ADD_RESOURCES (MacroEd_RES MacroEdit.qrc)
+-QT4_WRAP_UI       (MacroEd_FORMS_HEADERS CodeTemplateDialog.ui FunctionListDialog.ui VerbFunctionHelpDialog.ui
++QT5_ADD_RESOURCES (MacroEd_RES MacroEdit.qrc)
++QT5_WRAP_UI       (MacroEd_FORMS_HEADERS CodeTemplateDialog.ui FunctionListDialog.ui VerbFunctionHelpDialog.ui
+                    FindTextDialog.ui MacroEdit.ui GotoLineDialog.ui RunDialog.ui TabsDialog.ui)
+ 
+ set(macroeditor_srcs MvMain.cc
+Index: metview-4.5.6/src/MarsCatalog/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/MarsCatalog/CMakeLists.txt
++++ metview-4.5.6/src/MarsCatalog/CMakeLists.txt
+@@ -1,6 +1,6 @@
+ 
+-QT4_WRAP_CPP(MarsCat_MOC MvQMarsBrowser.h MvQMarsCatalog.h)
+-QT4_ADD_RESOURCES(MarsCat_RES mars.qrc)
++QT5_WRAP_CPP(MarsCat_MOC MvQMarsBrowser.h MvQMarsCatalog.h)
++QT5_ADD_RESOURCES(MarsCat_RES mars.qrc)
+ 
+ set(mars_cat_srcs
+     MvMain.cc
+Index: metview-4.5.6/src/NcExaminer/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/NcExaminer/CMakeLists.txt
++++ metview-4.5.6/src/NcExaminer/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(NcExam_MOC NcExaminer.h)
++QT5_WRAP_CPP(NcExam_MOC NcExaminer.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       NcExaminer
+Index: metview-4.5.6/src/OdbExaminer/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/OdbExaminer/CMakeLists.txt
++++ metview-4.5.6/src/OdbExaminer/CMakeLists.txt
+@@ -1,5 +1,5 @@
+ 
+-QT4_WRAP_CPP(ODBExaminer_MOC OdbExaminer.h MvQOdbTableView.h)
++QT5_WRAP_CPP(ODBExaminer_MOC OdbExaminer.h MvQOdbTableView.h)
+ 
+ set(odbexam_srcs
+     MvMain.cc
+Index: metview-4.5.6/src/OgcClient/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/OgcClient/CMakeLists.txt
++++ metview-4.5.6/src/OgcClient/CMakeLists.txt
+@@ -1,7 +1,7 @@
+ 
+ #--------COMMON SOURCES--------------------------------------------------
+ 
+-QT4_ADD_RESOURCES(OGC_common_RES MvQOgcClient.qrc)
++QT5_ADD_RESOURCES(OGC_common_RES MvQOgcClient.qrc)
+ 
+ set(OGC_common_srcs
+     MvQHighlighter.cc
+@@ -14,7 +14,7 @@ set(OGC_common_srcs
+ 
+ #-------- WmsClient ------------------------------------------------------------------
+ 
+-QT4_WRAP_CPP(WMS_MOC MvQWmsClient.h MvQWmsClientEditor.h)
++QT5_WRAP_CPP(WMS_MOC MvQWmsClient.h MvQWmsClientEditor.h)
+ 
+ 
+ ecbuild_add_executable( TARGET       WmsClient
+@@ -43,7 +43,7 @@ metview_module_files(ETC_FILES ObjectSpe
+ 
+ if(ENABLE_EXPERIMENTAL)
+ 
+-    QT4_WRAP_CPP(WCS_MOC MvQWcsClient.h MvQWcsClientEditor.h)
++    QT5_WRAP_CPP(WCS_MOC MvQWcsClient.h MvQWcsClientEditor.h)
+ 
+     ecbuild_add_executable( TARGET       WcsClient
+                             SOURCES      MvMainWcsClient.cc
+Index: metview-4.5.6/src/ScmEditor/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/ScmEditor/CMakeLists.txt
++++ metview-4.5.6/src/ScmEditor/CMakeLists.txt
+@@ -1,6 +1,6 @@
+ 
+-QT4_WRAP_CPP(SCM_MOC ScmDataEditor.h)
+-QT4_ADD_RESOURCES(SCM_RES scmEditor.qrc)
++QT5_WRAP_CPP(SCM_MOC ScmDataEditor.h)
++QT5_ADD_RESOURCES(SCM_RES scmEditor.qrc)
+ 
+ 
+ ecbuild_add_executable( TARGET       ScmDataEditor
+Index: metview-4.5.6/src/libMvQtGui/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/CMakeLists.txt
++++ metview-4.5.6/src/libMvQtGui/CMakeLists.txt
+@@ -86,15 +86,15 @@ if (METVIEW_ODB)
+     #######lib_libMvQtGui_a_CPPFLAGS += $(ODB_CPPFLAGS)
+ endif()
+ 
+-QT4_WRAP_CPP(libMvQtGui_MOC ${moc_files})
+-QT4_ADD_RESOURCES(libMvQtGui_RES edit.qrc examiner.qrc find.qrc keyDialog.qrc mail.qrc window.qrc)
++QT5_WRAP_CPP(libMvQtGui_MOC ${moc_files})
++QT5_ADD_RESOURCES(libMvQtGui_RES edit.qrc examiner.qrc find.qrc keyDialog.qrc mail.qrc window.qrc)
+ 
+ 
+ 
+-###QT4_WRAP_CPP(libMvQtGui_HEADERS_MOC ${moc_files})
++###QT5_WRAP_CPP(libMvQtGui_HEADERS_MOC ${moc_files})
+ 
+ #foreach( f ${moc_files} )
+-#    QT4_WRAP_CPP(${f}.moc.cpp ${f})
++#    QT5_WRAP_CPP(${f}.moc.cpp ${f})
+ #    set_source_files_properties( ${f}.moc.cpp GENERATED )
+ #    list(APPEND generated_srcs ${f}.moc.cpp)
+ #endforeach()
+@@ -148,3 +148,7 @@ ecbuild_add_library( TARGET      MvQtGui
+                      INCLUDES    ${METVIEW_QT_INCLUDE_DIRS} ${X11_INCLUDE_DIR} ../uPlot  ${METVIEW_STANDARD_INCLUDES}
+                      DEFINITIONS ${METVIEW_EXTRA_DEFINITIONS}
+ )
++
++target_link_libraries(MvQtGui Qt5::Gui)
++target_link_libraries(MvQtGui Qt5::Widgets)
++target_link_libraries(MvQtGui Qt5::PrintSupport)
+Index: metview-4.5.6/src/libMvQtUtil/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtUtil/CMakeLists.txt
++++ metview-4.5.6/src/libMvQtUtil/CMakeLists.txt
+@@ -2,7 +2,7 @@
+ set(header_files_for_moc MvQNetworkAccessManager.h MvQNetworkAccessManager.h )
+ 
+ 
+-QT4_WRAP_CPP(MvQtUtil_MOC ${header_files_for_moc})
++QT5_WRAP_CPP(MvQtUtil_MOC ${header_files_for_moc})
+ 
+ 
+ set(libMvQtUtil_srcs
+@@ -33,3 +33,4 @@ ecbuild_add_library( TARGET      MvQtUti
+                      INCLUDES    ${libmvqtutil_includes}
+                      DEFINITIONS ${METVIEW_EXTRA_DEFINITIONS}
+ )
++target_link_libraries(MvQtUtil Qt5::Core Qt5::Network Qt5::Xml Qt5::XmlPatterns)
+Index: metview-4.5.6/src/uPlot/CMakeLists.txt
+===================================================================
+--- metview-4.5.6.orig/src/uPlot/CMakeLists.txt
++++ metview-4.5.6/src/uPlot/CMakeLists.txt
+@@ -98,8 +98,8 @@ if(ENABLE_WEATHER_ROOM)
+     set(WEATHER_ROOM_MOC_FLAGS -DMETVIEW_WEATHER_ROOM)
+ endif()
+ 
+-QT4_WRAP_CPP(common_MOC ${common_moc_files} OPTIONS ${WEATHER_ROOM_MOC_FLAGS})
+-QT4_ADD_RESOURCES(common_RES uPlot.qrc)
++QT5_WRAP_CPP(common_MOC ${common_moc_files} OPTIONS ${WEATHER_ROOM_MOC_FLAGS})
++QT5_ADD_RESOURCES(common_RES uPlot.qrc)
+ 
+ 
+ 
+@@ -118,7 +118,7 @@ set(uPlot_srcs
+ 
+ 
+ if(ENABLE_WEATHER_ROOM)
+-    QT4_WRAP_CPP(wr_MOC MvQWeatherRoomDialog.h)
++    QT5_WRAP_CPP(wr_MOC MvQWeatherRoomDialog.h)
+     list(APPEND uPlot_srcs  MvQWeatherRoomDialog.cc ${wr_MOC})
+     set(WEATHER_ROOM_FLAGS METVIEW_WEATHER_ROOM)
+ endif()
+@@ -196,8 +196,8 @@ ecbuild_add_executable( TARGET       uPl
+ 
+ if(ENABLE_UI)
+ 
+-QT4_WRAP_CPP(geotool_MOC GeoTool.h)
+-QT4_ADD_RESOURCES(geotool_RES geoSelect.qrc)
++QT5_WRAP_CPP(geotool_MOC GeoTool.h)
++QT5_ADD_RESOURCES(geotool_RES geoSelect.qrc)
+ 
+ 
+ set(uPlotGeoTool_srcs
+Index: metview-4.5.6/cmake/Qt5Extras.cmake
 ===================================================================
 --- /dev/null
-+++ magics++-2.24.7/cmake/Qt5Macros.cmake
-@@ -0,0 +1,509 @@
++++ metview-4.5.6/cmake/Qt5Extras.cmake
+@@ -0,0 +1,79 @@
 +#.rst:
-+# Qt4Macros
++# Qt5Macros
 +# ---------
-+#
-+#
-+#
-+# This file is included by FindQt4.cmake, don't include it directly.
++#  Edited from Qt4Macros supplied by system
++#  These are Qt5 variants of Qt4 macros, but not supplied by Qt5
++#  Code using these probably needs to be adapted.
 +
 +#=============================================================================
-+# Copyright 2005-2009 Kitware, Inc.
++# Copyright 2015 Alastair McKinstry <mckinstry at debian.org>
 +#
 +# Distributed under the OSI-approved BSD License (the "License");
 +# see accompanying file Copyright.txt for details.
@@ -56,20 +328,10 @@ Index: magics++-2.24.7/cmake/Qt5Macros.cmake
 +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 +# See the License for more information.
 +#=============================================================================
-+# (To distribute this file outside of CMake, substitute the full
-+#  License text for the above reference.)
-+
 +
-+######################################
-+#
-+#       Macros for building Qt files
-+#
-+######################################
-+
-+
-+macro (QT5_EXTRACT_OPTIONS _qt4_files _qt4_options _qt4_target)
-+  set(${_qt4_files})
-+  set(${_qt4_options})
++macro (QT5_EXTRACT_OPTIONS _qt5_files _qt5_options _qt5_target)
++  set(${_qt5_files})
++  set(${_qt5_options})
 +  set(_QT5_DOING_OPTIONS FALSE)
 +  set(_QT5_DOING_TARGET FALSE)
 +  foreach(_currentArg ${ARGN})
@@ -79,150 +341,17 @@ Index: magics++-2.24.7/cmake/Qt5Macros.cmake
 +      set(_QT5_DOING_TARGET TRUE)
 +    else ()
 +      if(_QT5_DOING_TARGET)
-+        set(${_qt4_target} "${_currentArg}")
++        set(${_qt5_target} "${_currentArg}")
 +      elseif(_QT5_DOING_OPTIONS)
-+        list(APPEND ${_qt4_options} "${_currentArg}")
++        list(APPEND ${_qt5_options} "${_currentArg}")
 +      else()
-+        list(APPEND ${_qt4_files} "${_currentArg}")
++        list(APPEND ${_qt5_files} "${_currentArg}")
 +      endif()
 +    endif ()
 +  endforeach()
 +endmacro ()
 +
 +
-+# macro used to create the names of output files preserving relative dirs
-+macro (QT5_MAKE_OUTPUT_FILE infile prefix ext outfile )
-+  string(LENGTH ${CMAKE_CURRENT_BINARY_DIR} _binlength)
-+  string(LENGTH ${infile} _infileLength)
-+  set(_checkinfile ${CMAKE_CURRENT_SOURCE_DIR})
-+  if(_infileLength GREATER _binlength)
-+    string(SUBSTRING "${infile}" 0 ${_binlength} _checkinfile)
-+    if(_checkinfile STREQUAL "${CMAKE_CURRENT_BINARY_DIR}")
-+      file(RELATIVE_PATH rel ${CMAKE_CURRENT_BINARY_DIR} ${infile})
-+    else()
-+      file(RELATIVE_PATH rel ${CMAKE_CURRENT_SOURCE_DIR} ${infile})
-+    endif()
-+  else()
-+    file(RELATIVE_PATH rel ${CMAKE_CURRENT_SOURCE_DIR} ${infile})
-+  endif()
-+  if(WIN32 AND rel MATCHES "^([a-zA-Z]):(.*)$") # absolute path
-+    set(rel "${CMAKE_MATCH_1}_${CMAKE_MATCH_2}")
-+  endif()
-+  set(_outfile "${CMAKE_CURRENT_BINARY_DIR}/${rel}")
-+  string(REPLACE ".." "__" _outfile ${_outfile})
-+  get_filename_component(outpath ${_outfile} PATH)
-+  get_filename_component(_outfile ${_outfile} NAME_WE)
-+  file(MAKE_DIRECTORY ${outpath})
-+  set(${outfile} ${outpath}/${prefix}${_outfile}.${ext})
-+endmacro ()
-+
-+
-+macro (QT5_GET_MOC_FLAGS _moc_flags)
-+  set(${_moc_flags})
-+  get_directory_property(_inc_DIRS INCLUDE_DIRECTORIES)
-+
-+  foreach(_current ${_inc_DIRS})
-+    if("${_current}" MATCHES "\\.framework/?$")
-+      string(REGEX REPLACE "/[^/]+\\.framework" "" framework_path "${_current}")
-+      set(${_moc_flags} ${${_moc_flags}} "-F${framework_path}")
-+    else()
-+      set(${_moc_flags} ${${_moc_flags}} "-I${_current}")
-+    endif()
-+  endforeach()
-+
-+  get_directory_property(_defines COMPILE_DEFINITIONS)
-+  foreach(_current ${_defines})
-+    set(${_moc_flags} ${${_moc_flags}} "-D${_current}")
-+  endforeach()
-+
-+  if(Q_WS_WIN)
-+    set(${_moc_flags} ${${_moc_flags}} -DWIN32)
-+  endif()
-+
-+endmacro()
-+
-+
-+# helper macro to set up a moc rule
-+function (QT5_CREATE_MOC_COMMAND infile outfile moc_flags moc_options moc_target)
-+  # For Windows, create a parameters file to work around command line length limit
-+  # Pass the parameters in a file.  Set the working directory to
-+  # be that containing the parameters file and reference it by
-+  # just the file name.  This is necessary because the moc tool on
-+  # MinGW builds does not seem to handle spaces in the path to the
-+  # file given with the @ syntax.
-+  get_filename_component(_moc_outfile_name "${outfile}" NAME)
-+  get_filename_component(_moc_outfile_dir "${outfile}" PATH)
-+  if(_moc_outfile_dir)
-+    set(_moc_working_dir WORKING_DIRECTORY ${_moc_outfile_dir})
-+  endif()
-+  set (_moc_parameters_file ${outfile}_parameters)
-+  set (_moc_parameters ${moc_flags} ${moc_options} -o "${outfile}" "${infile}")
-+  string (REPLACE ";" "\n" _moc_parameters "${_moc_parameters}")
-+
-+  if(moc_target)
-+    set (_moc_parameters_file ${_moc_parameters_file}$<$<BOOL:$<CONFIGURATION>>:_$<CONFIGURATION>>)
-+    set(targetincludes "$<TARGET_PROPERTY:${moc_target},INCLUDE_DIRECTORIES>")
-+    set(targetdefines "$<TARGET_PROPERTY:${moc_target},COMPILE_DEFINITIONS>")
-+
-+    set(targetincludes "$<$<BOOL:${targetincludes}>:-I$<JOIN:${targetincludes},\n-I>\n>")
-+    set(targetdefines "$<$<BOOL:${targetdefines}>:-D$<JOIN:${targetdefines},\n-D>\n>")
-+
-+    file (GENERATE
-+      OUTPUT ${_moc_parameters_file}
-+      CONTENT "${targetdefines}${targetincludes}${_moc_parameters}\n"
-+    )
-+
-+    set(targetincludes)
-+    set(targetdefines)
-+  else()
-+    set(CMAKE_CONFIGURABLE_FILE_CONTENT "${_moc_parameters}")
-+    configure_file("${CMAKE_ROOT}/Modules/CMakeConfigurableFile.in"
-+                   "${_moc_parameters_file}" @ONLY)
-+  endif()
-+
-+  set(_moc_extra_parameters_file @${_moc_parameters_file})
-+  add_custom_command(OUTPUT ${outfile}
-+                      COMMAND Qt4::moc ${_moc_extra_parameters_file}
-+                      DEPENDS ${infile} ${_moc_parameters_file}
-+                      ${_moc_working_dir}
-+                      VERBATIM)
-+endfunction ()
-+
-+
-+macro (QT5_GENERATE_MOC infile outfile )
-+# get include dirs and flags
-+   QT5_GET_MOC_FLAGS(moc_flags)
-+   get_filename_component(abs_infile ${infile} ABSOLUTE)
-+   set(_outfile "${outfile}")
-+   if(NOT IS_ABSOLUTE "${outfile}")
-+     set(_outfile "${CMAKE_CURRENT_BINARY_DIR}/${outfile}")
-+   endif()
-+
-+   if ("x${ARGV2}" STREQUAL "xTARGET")
-+      set(moc_target ${ARGV3})
-+   endif()
-+   QT5_CREATE_MOC_COMMAND(${abs_infile} ${_outfile} "${moc_flags}" "" "${moc_target}")
-+   set_source_files_properties(${outfile} PROPERTIES SKIP_AUTOMOC TRUE)  # dont run automoc on this file
-+endmacro ()
-+
-+
-+# QT5_WRAP_CPP(outfiles inputfile ... )
-+
-+macro (QT5_WRAP_CPP outfiles )
-+  # get include dirs
-+  QT5_GET_MOC_FLAGS(moc_flags)
-+  QT5_EXTRACT_OPTIONS(moc_files moc_options moc_target ${ARGN})
-+
-+  foreach (it ${moc_files})
-+    get_filename_component(it ${it} ABSOLUTE)
-+    QT5_MAKE_OUTPUT_FILE(${it} moc_ cxx outfile)
-+    QT5_CREATE_MOC_COMMAND(${it} ${outfile} "${moc_flags}" "${moc_options}" "${moc_target}")
-+    set(${outfiles} ${${outfiles}} ${outfile})
-+  endforeach()
-+
-+endmacro ()
-+
-+
 +# QT5_WRAP_UI(outfiles inputfile ... )
 +
 +macro (QT5_WRAP_UI outfiles )
@@ -233,7 +362,7 @@ Index: magics++-2.24.7/cmake/Qt5Macros.cmake
 +    get_filename_component(infile ${it} ABSOLUTE)
 +    set(outfile ${CMAKE_CURRENT_BINARY_DIR}/ui_${outfile}.h)
 +    add_custom_command(OUTPUT ${outfile}
-+      COMMAND Qt4::uic
++      COMMAND Qt5::uic
 +      ARGS ${ui_options} -o ${outfile} ${infile}
 +      MAIN_DEPENDENCY ${infile} VERBATIM)
 +    set(${outfiles} ${${outfiles}} ${outfile})
@@ -241,260 +370,6 @@ Index: magics++-2.24.7/cmake/Qt5Macros.cmake
 +
 +endmacro ()
 +
-+
-+# QT5_ADD_RESOURCES(outfiles inputfile ... )
-+
-+macro (QT5_ADD_RESOURCES outfiles )
-+  QT5_EXTRACT_OPTIONS(rcc_files rcc_options rcc_target ${ARGN})
-+
-+  foreach (it ${rcc_files})
-+    get_filename_component(outfilename ${it} NAME_WE)
-+    get_filename_component(infile ${it} ABSOLUTE)
-+    get_filename_component(rc_path ${infile} PATH)
-+    set(outfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${outfilename}.cxx)
-+
-+    set(_RC_DEPENDS)
-+    if(EXISTS "${infile}")
-+      #  parse file for dependencies
-+      #  all files are absolute paths or relative to the location of the qrc file
-+      file(READ "${infile}" _RC_FILE_CONTENTS)
-+      string(REGEX MATCHALL "<file[^<]+" _RC_FILES "${_RC_FILE_CONTENTS}")
-+      foreach(_RC_FILE ${_RC_FILES})
-+        string(REGEX REPLACE "^<file[^>]*>" "" _RC_FILE "${_RC_FILE}")
-+        if(NOT IS_ABSOLUTE "${_RC_FILE}")
-+          set(_RC_FILE "${rc_path}/${_RC_FILE}")
-+        endif()
-+        set(_RC_DEPENDS ${_RC_DEPENDS} "${_RC_FILE}")
-+      endforeach()
-+      unset(_RC_FILES)
-+      unset(_RC_FILE_CONTENTS)
-+      # Since this cmake macro is doing the dependency scanning for these files,
-+      # let's make a configured file and add it as a dependency so cmake is run
-+      # again when dependencies need to be recomputed.
-+      QT5_MAKE_OUTPUT_FILE("${infile}" "" "qrc.depends" out_depends)
-+      configure_file("${infile}" "${out_depends}" COPYONLY)
-+    else()
-+      # The .qrc file does not exist (yet). Let's add a dependency and hope
-+      # that it will be generated later
-+      set(out_depends)
-+    endif()
-+
-+    add_custom_command(OUTPUT ${outfile}
-+      COMMAND Qt4::rcc
-+      ARGS ${rcc_options} -name ${outfilename} -o ${outfile} ${infile}
-+      MAIN_DEPENDENCY ${infile}
-+      DEPENDS ${_RC_DEPENDS} "${out_depends}" VERBATIM)
-+    set(${outfiles} ${${outfiles}} ${outfile})
-+  endforeach ()
-+
-+endmacro ()
-+
-+
-+macro(QT5_ADD_DBUS_INTERFACE _sources _interface _basename)
-+  get_filename_component(_infile ${_interface} ABSOLUTE)
-+  set(_header "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.h")
-+  set(_impl   "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.cpp")
-+  set(_moc    "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.moc")
-+
-+  get_source_file_property(_nonamespace ${_interface} NO_NAMESPACE)
-+  if(_nonamespace)
-+    set(_params -N -m)
-+  else()
-+    set(_params -m)
-+  endif()
-+
-+  get_source_file_property(_classname ${_interface} CLASSNAME)
-+  if(_classname)
-+    set(_params ${_params} -c ${_classname})
-+  endif()
-+
-+  get_source_file_property(_include ${_interface} INCLUDE)
-+  if(_include)
-+    set(_params ${_params} -i ${_include})
-+  endif()
-+
-+  add_custom_command(OUTPUT "${_impl}" "${_header}"
-+      COMMAND Qt4::qdbusxml2cpp ${_params} -p ${_basename} ${_infile}
-+      DEPENDS ${_infile} VERBATIM)
-+
-+  set_source_files_properties("${_impl}" PROPERTIES SKIP_AUTOMOC TRUE)
-+
-+  QT5_GENERATE_MOC("${_header}" "${_moc}")
-+
-+  list(APPEND ${_sources} "${_impl}" "${_header}" "${_moc}")
-+  MACRO_ADD_FILE_DEPENDENCIES("${_impl}" "${_moc}")
-+
-+endmacro()
-+
-+
-+macro(QT5_ADD_DBUS_INTERFACES _sources)
-+  foreach (_current_FILE ${ARGN})
-+    get_filename_component(_infile ${_current_FILE} ABSOLUTE)
-+    get_filename_component(_basename ${_current_FILE} NAME)
-+    # get the part before the ".xml" suffix
-+    string(TOLOWER ${_basename} _basename)
-+    string(REGEX REPLACE "(.*\\.)?([^\\.]+)\\.xml" "\\2" _basename ${_basename})
-+    QT5_ADD_DBUS_INTERFACE(${_sources} ${_infile} ${_basename}interface)
-+  endforeach ()
-+endmacro()
-+
-+
-+macro(QT5_GENERATE_DBUS_INTERFACE _header) # _customName OPTIONS -some -options )
-+  QT5_EXTRACT_OPTIONS(_customName _qt4_dbus_options _qt4_dbus_target ${ARGN})
-+
-+  get_filename_component(_in_file ${_header} ABSOLUTE)
-+  get_filename_component(_basename ${_header} NAME_WE)
-+
-+  if (_customName)
-+    if (IS_ABSOLUTE ${_customName})
-+      get_filename_component(_containingDir ${_customName} PATH)
-+      if (NOT EXISTS ${_containingDir})
-+        file(MAKE_DIRECTORY "${_containingDir}")
-+      endif()
-+      set(_target ${_customName})
-+    else()
-+      set(_target ${CMAKE_CURRENT_BINARY_DIR}/${_customName})
-+    endif()
-+  else ()
-+    set(_target ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.xml)
-+  endif ()
-+
-+  add_custom_command(OUTPUT ${_target}
-+      COMMAND Qt4::qdbuscpp2xml ${_qt4_dbus_options} ${_in_file} -o ${_target}
-+      DEPENDS ${_in_file} VERBATIM
-+  )
-+endmacro()
-+
-+
-+macro(QT5_ADD_DBUS_ADAPTOR _sources _xml_file _include _parentClass) # _optionalBasename _optionalClassName)
-+  get_filename_component(_infile ${_xml_file} ABSOLUTE)
-+
-+  set(_optionalBasename "${ARGV4}")
-+  if (_optionalBasename)
-+    set(_basename ${_optionalBasename} )
-+  else ()
-+    string(REGEX REPLACE "(.*[/\\.])?([^\\.]+)\\.xml" "\\2adaptor" _basename ${_infile})
-+    string(TOLOWER ${_basename} _basename)
-+  endif ()
-+
-+  set(_optionalClassName "${ARGV5}")
-+  set(_header "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.h")
-+  set(_impl   "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.cpp")
-+  set(_moc    "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.moc")
-+
-+  if(_optionalClassName)
-+    add_custom_command(OUTPUT "${_impl}" "${_header}"
-+       COMMAND Qt4::qdbusxml2cpp -m -a ${_basename} -c ${_optionalClassName} -i ${_include} -l ${_parentClass} ${_infile}
-+       DEPENDS ${_infile} VERBATIM
-+    )
-+  else()
-+    add_custom_command(OUTPUT "${_impl}" "${_header}"
-+       COMMAND Qt4::qdbusxml2cpp -m -a ${_basename} -i ${_include} -l ${_parentClass} ${_infile}
-+       DEPENDS ${_infile} VERBATIM
-+     )
-+  endif()
-+
-+  QT5_GENERATE_MOC("${_header}" "${_moc}")
-+  set_source_files_properties("${_impl}" PROPERTIES SKIP_AUTOMOC TRUE)
-+  MACRO_ADD_FILE_DEPENDENCIES("${_impl}" "${_moc}")
-+
-+  list(APPEND ${_sources} "${_impl}" "${_header}" "${_moc}")
-+endmacro()
-+
-+
-+macro(QT5_AUTOMOC)
-+  if(NOT CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.11)
-+    message(DEPRECATION "The qt4_automoc macro is obsolete. Use the CMAKE_AUTOMOC feature instead.")
-+  endif()
-+  QT5_GET_MOC_FLAGS(_moc_INCS)
-+
-+  set(_matching_FILES )
-+  foreach (_current_FILE ${ARGN})
-+
-+    get_filename_component(_abs_FILE ${_current_FILE} ABSOLUTE)
-+    # if "SKIP_AUTOMOC" is set to true, we will not handle this file here.
-+    # This is required to make uic work correctly:
-+    # we need to add generated .cpp files to the sources (to compile them),
-+    # but we cannot let automoc handle them, as the .cpp files don't exist yet when
-+    # cmake is run for the very first time on them -> however the .cpp files might
-+    # exist at a later run. at that time we need to skip them, so that we don't add two
-+    # different rules for the same moc file
-+    get_source_file_property(_skip ${_abs_FILE} SKIP_AUTOMOC)
-+
-+    if ( NOT _skip AND EXISTS ${_abs_FILE} )
-+
-+      file(READ ${_abs_FILE} _contents)
-+
-+      get_filename_component(_abs_PATH ${_abs_FILE} PATH)
-+
-+      string(REGEX MATCHALL "# *include +[^ ]+\\.moc[\">]" _match "${_contents}")
-+      if(_match)
-+        foreach (_current_MOC_INC ${_match})
-+          string(REGEX MATCH "[^ <\"]+\\.moc" _current_MOC "${_current_MOC_INC}")
-+
-+          get_filename_component(_basename ${_current_MOC} NAME_WE)
-+          if(EXISTS ${_abs_PATH}/${_basename}.hpp)
-+            set(_header ${_abs_PATH}/${_basename}.hpp)
-+          else()
-+            set(_header ${_abs_PATH}/${_basename}.h)
-+          endif()
-+          set(_moc    ${CMAKE_CURRENT_BINARY_DIR}/${_current_MOC})
-+          QT5_CREATE_MOC_COMMAND(${_header} ${_moc} "${_moc_INCS}" "" "")
-+          MACRO_ADD_FILE_DEPENDENCIES(${_abs_FILE} ${_moc})
-+        endforeach ()
-+      endif()
-+    endif ()
-+  endforeach ()
-+endmacro()
-+
-+
-+macro(QT5_CREATE_TRANSLATION _qm_files)
-+   QT5_EXTRACT_OPTIONS(_lupdate_files _lupdate_options _lupdate_target ${ARGN})
-+   set(_my_sources)
-+   set(_my_dirs)
-+   set(_my_tsfiles)
-+   set(_ts_pro)
-+   foreach (_file ${_lupdate_files})
-+     get_filename_component(_ext ${_file} EXT)
-+     get_filename_component(_abs_FILE ${_file} ABSOLUTE)
-+     if(_ext MATCHES "ts")
-+       list(APPEND _my_tsfiles ${_abs_FILE})
-+     else()
-+       if(NOT _ext)
-+         list(APPEND _my_dirs ${_abs_FILE})
-+       else()
-+         list(APPEND _my_sources ${_abs_FILE})
-+       endif()
-+     endif()
-+   endforeach()
-+   foreach(_ts_file ${_my_tsfiles})
-+     if(_my_sources)
-+       # make a .pro file to call lupdate on, so we don't make our commands too
-+       # long for some systems
-+       get_filename_component(_ts_name ${_ts_file} NAME_WE)
-+       set(_ts_pro ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/${_ts_name}_lupdate.pro)
-+       set(_pro_srcs)
-+       foreach(_pro_src ${_my_sources})
-+         set(_pro_srcs "${_pro_srcs} \\\n  \"${_pro_src}\"")
-+       endforeach()
-+       set(_pro_includes)
-+       get_directory_property(_inc_DIRS INCLUDE_DIRECTORIES)
-+       list(REMOVE_DUPLICATES _inc_DIRS)
-+       foreach(_pro_include ${_inc_DIRS})
-+         get_filename_component(_abs_include "${_pro_include}" ABSOLUTE)
-+         set(_pro_includes "${_pro_includes} \\\n  \"${_abs_include}\"")
-+       endforeach()
-+       file(WRITE ${_ts_pro} "SOURCES =${_pro_srcs}\nINCLUDEPATH =${_pro_includes}\n")
-+     endif()
-+     add_custom_command(OUTPUT ${_ts_file}
-+        COMMAND Qt4::lupdate
-+        ARGS ${_lupdate_options} ${_ts_pro} ${_my_dirs} -ts ${_ts_file}
-+        DEPENDS ${_my_sources} ${_ts_pro} VERBATIM)
-+   endforeach()
-+   QT5_ADD_TRANSLATION(${_qm_files} ${_my_tsfiles})
-+endmacro()
-+
-+
 +macro(QT5_ADD_TRANSLATION _qm_files)
 +  foreach (_current_FILE ${ARGN})
 +    get_filename_component(_abs_FILE ${_current_FILE} ABSOLUTE)
@@ -508,42 +383,603 @@ Index: magics++-2.24.7/cmake/Qt5Macros.cmake
 +    endif()
 +
 +    add_custom_command(OUTPUT ${qm}
-+       COMMAND Qt4::lrelease
++       COMMAND Qt5::lrelease
 +       ARGS ${_abs_FILE} -qm ${qm}
 +       DEPENDS ${_abs_FILE} VERBATIM
 +    )
 +    set(${_qm_files} ${${_qm_files}} ${qm})
 +  endforeach ()
 +endmacro()
-+
-+function(qt4_use_modules _target _link_type)
-+  if(NOT CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.11)
-+    message(DEPRECATION "The qt4_use_modules function is obsolete. Use target_link_libraries with IMPORTED targets instead.")
-+  endif()
-+  if ("${_link_type}" STREQUAL "LINK_PUBLIC" OR "${_link_type}" STREQUAL "LINK_PRIVATE")
-+    set(modules ${ARGN})
-+    set(link_type ${_link_type})
-+  else()
-+    set(modules ${_link_type} ${ARGN})
-+  endif()
-+  foreach(_module ${modules})
-+    string(TOUPPER ${_module} _ucmodule)
-+    set(_targetPrefix QT_QT${_ucmodule})
-+    if (_ucmodule STREQUAL QAXCONTAINER OR _ucmodule STREQUAL QAXSERVER)
-+      if (NOT QT_Q${_ucmodule}_FOUND)
-+        message(FATAL_ERROR "Can not use \"${_module}\" module which has not yet been found.")
-+      endif()
-+      set(_targetPrefix QT_Q${_ucmodule})
-+    else()
-+      if (NOT QT_QT${_ucmodule}_FOUND)
-+        message(FATAL_ERROR "Can not use \"${_module}\" module which has not yet been found.")
-+      endif()
-+      if ("${_ucmodule}" STREQUAL "MAIN")
-+        message(FATAL_ERROR "Can not use \"${_module}\" module with qt4_use_modules.")
-+      endif()
-+    endif()
-+    target_link_libraries(${_target} ${link_type} ${${_targetPrefix}_LIBRARIES})
-+    set_property(TARGET ${_target} APPEND PROPERTY INCLUDE_DIRECTORIES ${${_targetPrefix}_INCLUDE_DIR} ${QT_HEADERS_DIR} ${QT_MKSPECS_DIR}/default)
-+    set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS ${${_targetPrefix}_COMPILE_DEFINITIONS})
-+  endforeach()
-+endfunction()
+Index: metview-4.5.6/src/libMvQtUtil/MvQNetworkProxyFactory.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtUtil/MvQNetworkProxyFactory.cc
++++ metview-4.5.6/src/libMvQtUtil/MvQNetworkProxyFactory.cc
+@@ -42,13 +42,13 @@ void MvQNetworkProxyFactory::updateSetti
+ 
+ 		const char* proxyPort = myPref( "PROXY_PORT" );
+ 		if(proxyPort)
+-			proxy_.setPort(QString::fromAscii(proxyPort).toInt());
++			proxy_.setPort(QString::fromUtf8(proxyPort).toInt());
+ 
+ 		const char* noProxy = myPref( "NO_PROXY_FOR" );
+ 	
+ 		if(noProxy)
+ 		{
+-			QStringList lst=QString::fromAscii(noProxy).split(",");
++			QStringList lst=QString::fromUtf8(noProxy).split(",");
+ 			foreach(QString s,lst)
+ 			{	
+ 				noProxyLst_ << s.simplified();
+Index: metview-4.5.6/src/libMvQtGui/MvQX11Application.h
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQX11Application.h
++++ metview-4.5.6/src/libMvQtGui/MvQX11Application.h
+@@ -10,7 +10,7 @@
+ #ifndef MvQX11Application_H
+ #define MvQX11Application_H
+ 
+-#include <QtGui/QApplication>
++#include <QtWidgets/QApplication>
+ #include <QWidget>
+ 
+ #include <MvRequest.h>
+Index: metview-4.5.6/src/libMvQtGui/MvQApplication.h
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQApplication.h
++++ metview-4.5.6/src/libMvQtGui/MvQApplication.h
+@@ -10,7 +10,7 @@
+ #ifndef MvQApplication_H
+ #define MvQApplication_H
+ 
+-#include <QtGui/QApplication>
++#include <QtWidgets/QApplication>
+ #include <QWidget>
+ 
+ #include <MvRequest.h>
+Index: metview-4.5.6/src/libMvQtGui/MvQFileDialog.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQFileDialog.cc
++++ metview-4.5.6/src/libMvQtGui/MvQFileDialog.cc
+@@ -137,8 +137,8 @@ MvQFileDialog::MvQFileDialog(QString sta
+ 	
+ 	urlLst << QUrl("file:");
+ 	
+-	urlLst << QUrl::fromLocalFile(QDesktopServices::storageLocation(QDesktopServices::HomeLocation));
+-	//urlLst << QUrl::fromLocalFile(QDesktopServices::storageLocation(QDesktopServices::DocumentsLocation));
++	urlLst << QUrl::fromLocalFile(QStandardPaths::writableLocation(QStandardPaths::HomeLocation));
++	//urlLst << QUrl::fromLocalFile(QStandardPaths::writableLocation(QStandardPaths::DocumentsLocation));
+ 	
+ 	if(char *mvDir=getenv("METVIEW_USER_DIRECTORY"))		
+   	{ 	
+Index: metview-4.5.6/src/libMvQtGui/MvQKeyProfileTree.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQKeyProfileTree.cc
++++ metview-4.5.6/src/libMvQtGui/MvQKeyProfileTree.cc
+@@ -72,13 +72,13 @@ void MvQKeyProfileTree::setEditable(bool
+ 	{	
+ 		setAcceptDrops(true);
+ 		setDragDropMode(QAbstractItemView::DropOnly);
+-		header()->setMovable(true);
++		header()->setSectionsMovable(true);
+ 	}	
+ 	else
+ 	{
+ 		setAcceptDrops(false);
+ 		setDragDropMode(QAbstractItemView::NoDragDrop);
+-		header()->setMovable(false);	
++		header()->setSectionsMovable(false);	
+ 	}
+ }
+ 
+Index: metview-4.5.6/src/libMvQtUtil/MvQKeyManager.h
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtUtil/MvQKeyManager.h
++++ metview-4.5.6/src/libMvQtUtil/MvQKeyManager.h
+@@ -17,7 +17,7 @@
+ 
+ #include <QMap>
+ #include <QString>
+-#include <QXmlQuery>
++#include <QtXmlPatterns/QXmlQuery>
+ 
+ using namespace std;
+ 
+Index: metview-4.5.6/src/libMvQtGui/MvQDragDrop.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQDragDrop.cc
++++ metview-4.5.6/src/libMvQtGui/MvQDragDrop.cc
+@@ -7,7 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-//#include <QtGui>
++#include <QtGui>
+ //#include <QX11Info>
+ //#include <X11/X.h>
+ //#include <X11/Xlib.h>
+@@ -104,4 +104,4 @@ QString MvQDrop::iconClass(int i) const
+ {
+   	return (i >=0 && i < iconPath_.count())?iconClass_.at(i):QString();
+ }
+-	
+\ No newline at end of file
++	
+Index: metview-4.5.6/src/libMvQtGui/MvQKeyFilterModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQKeyFilterModel.cc
++++ metview-4.5.6/src/libMvQtGui/MvQKeyFilterModel.cc
+@@ -163,7 +163,9 @@ void MvQKeyFilterModel::setKeyProfile(Mv
+ 	setupKeyFilter();
+ 
+ 	//Reset the model (views will be notified)
+-	reset();
++	// reset();
++	beginResetModel();
++	endResetModel();
+ }
+ 
+ void MvQKeyFilterModel::setupKeyFilter()
+@@ -361,7 +363,7 @@ QModelIndex MvQKeyFilterModel::index( in
+ 		return QModelIndex();
+ 	}
+ 
+-	return createIndex(row,column,0);
++	return createIndex(row,column,(void*) 0);
+ }
+ 
+ 
+Index: metview-4.5.6/src/libMvQtGui/MvQKeyModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQKeyModel.cc
++++ metview-4.5.6/src/libMvQtGui/MvQKeyModel.cc
+@@ -259,7 +259,7 @@ QString MvQKeyModel::label(MvKey* key,co
+ 
+ QModelIndex MvQKeyModel::index( int row, int column, const QModelIndex & /*parent*/ ) const
+ {
+-   return createIndex(row,column,0);
++   return createIndex(row,column, (void*) 0);
+ }
+ 
+ 
+Index: metview-4.5.6/src/libMvQtGui/MvQKeyProfileModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQKeyProfileModel.cc
++++ metview-4.5.6/src/libMvQtGui/MvQKeyProfileModel.cc
+@@ -259,7 +259,7 @@ QModelIndex MvQKeyProfileModel::index( i
+ 		return QModelIndex();
+ 	}
+ 
+-	return createIndex(row,column,0);
++	return createIndex(row,column, (void*) 0);
+ }
+ 
+ 
+Index: metview-4.5.6/src/libMvQtGui/MvQProfileView.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQProfileView.cc
++++ metview-4.5.6/src/libMvQtGui/MvQProfileView.cc
+@@ -30,7 +30,7 @@ MvQNodeItem::MvQNodeItem(MvQProfileItem
+   yPos_(yPos)
+ {	
+   	setFlag(ItemSendsGeometryChanges);
+-	setAcceptsHoverEvents(true);
++	setAcceptHoverEvents(true);
+  	setZValue(-1);
+ 	
+ 	if(editable_)   
+Index: metview-4.5.6/src/libMvQtGui/MvQScmModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQScmModel.cc
++++ metview-4.5.6/src/libMvQtGui/MvQScmModel.cc
+@@ -86,7 +86,7 @@ QModelIndex MvQScmDataModel::index( int
+ 		return QModelIndex();
+ 	}
+ 	
+-	return createIndex(row, column, 0);
++	return createIndex(row, column, (void*) 0);
+ }
+ 
+ QModelIndex MvQScmDataModel::indexForChange(const MvScmProfileChange& item) const
+@@ -101,7 +101,9 @@ QModelIndex MvQScmDataModel::parent( con
+ 
+ void MvQScmDataModel::reload()
+ {
+-  	reset();
++  	// reset();
++	beginResetModel();
++	endResetModel();
+ }	
+ 
+ 
+@@ -248,7 +250,7 @@ QModelIndex MvQScmSurfaceModel::indexFor
+ 		{
+ 			if(data_.at(i) == var)
+ 			{
+-				return createIndex(i,0,0); 
++				return createIndex(i,0, (void*) 0); 
+ 			}	
+ 		}	  			
+ 	}
+@@ -426,7 +428,7 @@ QModelIndex MvQScmProfileModel::indexFor
+ 		{
+ 			if(data_.at(i) == var)
+ 			{
+-				return createIndex(level,i, 0); 
++				return createIndex(level,i, (void*) 0); 
+ 			}	
+ 		}	  			
+ 	}
+@@ -460,7 +462,9 @@ MvQScmProfileFilterModel::MvQScmProfileF
+ void MvQScmProfileFilterModel::setShowEditableOnly(bool b)
+ {
+   	showEditableOnly_=b;
+-	reset();
++	// reset();
++     	beginResetModel();
++	endResetModel();
+ }
+ 
+ bool MvQScmProfileFilterModel::filterAcceptsColumn(int sourceColumn,
+Index: metview-4.5.6/src/libMvQtGui/MvQStationsWidget.cc
+===================================================================
+--- metview-4.5.6.orig/src/libMvQtGui/MvQStationsWidget.cc
++++ metview-4.5.6/src/libMvQtGui/MvQStationsWidget.cc
+@@ -150,7 +150,7 @@ QModelIndex MvQStationsModel::index( int
+ 		return QModelIndex();
+ 	}
+ 	
+-	return createIndex(row, column, 0);
++	return createIndex(row, column, (void*) 0);
+ }
+ 
+ QModelIndex MvQStationsModel::parent( const QModelIndex & /*index */) const
+@@ -358,4 +358,4 @@ void  MvQStationsWidget::slotSelected(co
+ 	  	break;
+ 	}
+ }  
+-  
+\ No newline at end of file
++  
+Index: metview-4.5.6/src/DebugTools/XServ.h
+===================================================================
+--- metview-4.5.6.orig/src/DebugTools/XServ.h
++++ metview-4.5.6/src/DebugTools/XServ.h
+@@ -12,7 +12,8 @@
+ 
+ #include "mars.h"
+ #undef D  /// MARS
+-#include <QtGui>
++#include <QtWidgets>
++#include <QWidget>
+ 
+ class XServBar : public QWidget
+ {
+Index: metview-4.5.6/src/GeopExaminer/MvGeoPointsModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/GeopExaminer/MvGeoPointsModel.cc
++++ metview-4.5.6/src/GeopExaminer/MvGeoPointsModel.cc
+@@ -94,7 +94,7 @@ QModelIndex MvQGeoPointsDataModel::index
+ 	if(data_ == 0 || data_->count() <= 0 || column < 0)
+ 		return QModelIndex();
+ 	
+-	return createIndex(row, column, 0); 
++	return createIndex(row, column, (void*) 0); 
+ }
+ 
+ 
+Index: metview-4.5.6/src/GribExaminer/MvQGribDumpModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/GribExaminer/MvQGribDumpModel.cc
++++ metview-4.5.6/src/GribExaminer/MvQGribDumpModel.cc
+@@ -158,7 +158,7 @@ QString MvQGribMvDumpModel::label(GribIt
+ 
+ QModelIndex MvQGribMvDumpModel::index( int row, int column, const QModelIndex & /*parent*/ ) const
+ {
+-	return createIndex(row,column,0);
++	return createIndex(row,column,(void*) 0);
+ }
+ 
+ 
+@@ -922,7 +922,7 @@ QVariant MvQGribValueDumpModel::headerDa
+ 
+ QModelIndex MvQGribValueDumpModel::index( int row, int column, const QModelIndex & /*parent*/ ) const
+ {
+-	return createIndex(row,column,0);
++	return createIndex(row,column,(void*) 0);
+ }
+ 
+ 
+Index: metview-4.5.6/src/MacroEditor/CodeTemplateDialog.cc
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/CodeTemplateDialog.cc
++++ metview-4.5.6/src/MacroEditor/CodeTemplateDialog.cc
+@@ -7,7 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-#include <QtGui>
++#include <QtWidgets>
+ 
+ #include "CodeTemplateDialog.h"
+ 
+Index: metview-4.5.6/src/MacroEditor/FunctionListDialog.cc
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/FunctionListDialog.cc
++++ metview-4.5.6/src/MacroEditor/FunctionListDialog.cc
+@@ -7,7 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-#include <QtGui>
++#include <QtWidgets>
+ 
+ #include "FunctionListDialog.h"
+ 
+Index: metview-4.5.6/src/MacroEditor/GotoLineDialog.cc
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/GotoLineDialog.cc
++++ metview-4.5.6/src/MacroEditor/GotoLineDialog.cc
+@@ -7,7 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-#include <QtGui>
++#include <QtWidgets>
+ 
+ #include "GotoLineDialog.h"
+ 
+Index: metview-4.5.6/src/MacroEditor/MacroEdit.cc
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/MacroEdit.cc
++++ metview-4.5.6/src/MacroEditor/MacroEdit.cc
+@@ -7,7 +7,9 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-#include <QtGui>
++#include <QtWidgets>
++#include <QtPrintSupport/QPrinter>
++#include <QtPrintSupport/QPrintDialog>
+ 
+ #include "MacroEdit.h"
+ #include "FindTextDialog.h"
+Index: metview-4.5.6/src/MacroEditor/VerbFunctionHelp.cc
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/VerbFunctionHelp.cc
++++ metview-4.5.6/src/MacroEditor/VerbFunctionHelp.cc
+@@ -7,7 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-#include <QtGui>
++#include <QtWidgets>
+ 
+ #include "VerbFunctionHelp.h"
+ 
+Index: metview-4.5.6/src/MacroEditor/VerbFunctionHelpDialog.cc
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/VerbFunctionHelpDialog.cc
++++ metview-4.5.6/src/MacroEditor/VerbFunctionHelpDialog.cc
+@@ -7,7 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
+-#include <QtGui>
++#include <QtWidgets>
+ 
+ #include "VerbFunctionHelpDialog.h"
+ 
+Index: metview-4.5.6/src/MacroEditor/mvplaintextedit.h
+===================================================================
+--- metview-4.5.6.orig/src/MacroEditor/mvplaintextedit.h
++++ metview-4.5.6/src/MacroEditor/mvplaintextedit.h
+@@ -10,7 +10,7 @@
+ #ifndef MvPlainTextEdit_H
+ #define MvPlainTextEdit_H
+ 
+-#include <QtGui/QPlainTextEdit>
++#include <QtWidgets/QPlainTextEdit>
+ 
+ #include "TabsSettings.h"
+ 
+Index: metview-4.5.6/src/OgcClient/MvQWmsClientEditor.cc
+===================================================================
+--- metview-4.5.6.orig/src/OgcClient/MvQWmsClientEditor.cc
++++ metview-4.5.6/src/OgcClient/MvQWmsClientEditor.cc
+@@ -1008,7 +1008,7 @@ void MvQWmsClientEditor::initFormatCombo
+ 		formatCombo_->addItem(values[i]);
+ 		if(!client_->supportedMimeType().contains(values[i]))
+ 		{
+-			formatCombo_->setItemData(i,Qt::darkGray,Qt::ForegroundRole);
++			formatCombo_->setItemData(i,QColor(Qt::darkGray),Qt::ForegroundRole);
+ 			formatCombo_->setItemData(i,tr("Not supported by Metview"),Qt::ToolTipRole);
+ 		}
+ 	}
+@@ -1119,7 +1119,7 @@ void MvQWmsClientEditor::initCrsCombo()
+ 		crsCombo_->addItem(values[i]);
+ 		if(!client_->supportedCrs().contains(values[i]))
+ 		{
+-			crsCombo_->setItemData(i,Qt::darkGray,Qt::ForegroundRole);
++			crsCombo_->setItemData(i,QColor(Qt::darkGray),Qt::ForegroundRole);
+ 			crsCombo_->setItemData(i,tr("Not supported by Metview"),Qt::ToolTipRole);
+ 		}
+ 	}
+Index: metview-4.5.6/src/Desktop/MvQDetailedFolderView.cc
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/MvQDetailedFolderView.cc
++++ metview-4.5.6/src/Desktop/MvQDetailedFolderView.cc
+@@ -88,7 +88,7 @@ MvQDetailedFolderView::MvQDetailedFolder
+ 		this,SLOT(slotSelectItem(const QModelIndex)));
+ 			
+ 	//Set header ContextMenuPolicy	
+-	header()->setMovable(false);
++	header()->setSectionsMovable(false);
+ 	header()->setContextMenuPolicy(Qt::CustomContextMenu);
+ 
+ 	connect(header(),SIGNAL(customContextMenuRequested(const QPoint &)),
+Index: metview-4.5.6/src/Desktop/MvQFolderModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/MvQFolderModel.cc
++++ metview-4.5.6/src/Desktop/MvQFolderModel.cc
+@@ -421,7 +421,7 @@ QModelIndex MvQFolderModel::index( int r
+ 		return QModelIndex();
+ 	}
+ 
+-	return createIndex(row,column,0);
++	return createIndex(row,column, (void*) 0);
+ }
+ 
+ 
+@@ -466,7 +466,7 @@ QModelIndex MvQFolderModel::indexFromObj
+ 	  	return QModelIndex();
+   
+ 	int i=items_.indexOf(obj);
+-	return (i >=0)?createIndex(i,0,0):QModelIndex();
++	return (i >=0)?createIndex(i,0,(void*)0):QModelIndex();
+ }
+ 
+ //Should be called between beginResetModel() and endResetModel() !!
+@@ -809,7 +809,11 @@ void MvQFolderModel::updateSearchData(bo
+ 	if(!hasSearchData())
+ 	{
+ 	  	if(doReset)
+-		  	reset();
++		{ 
++		  	// reset();
++			beginResetModel();
++			endResetModel();
++		}
+ 		return;
+ 	}
+ 	
+@@ -829,7 +833,11 @@ void MvQFolderModel::updateSearchData(bo
+ 	searchData_->matchChanged();
+ 	
+ 	if(doReset)
+-		reset();	 
++	{
++		//	reset();	 
++		beginResetModel();
++		endResetModel();
++	}
+ }  
+ 
+ bool MvQFolderModel::hasSearchData() const
+@@ -970,4 +978,4 @@ bool MvQFolderFilterModel::setFilter(QSt
+ 	
+ 	return found;
+ }
+-*/
+\ No newline at end of file
++*/
+Index: metview-4.5.6/src/Desktop/MvQIconHolder.cc
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/MvQIconHolder.cc
++++ metview-4.5.6/src/Desktop/MvQIconHolder.cc
+@@ -135,7 +135,7 @@ QVariant MvQIconHolderModel::data( const
+ 
+ QModelIndex MvQIconHolderModel::index( int row, int column, const QModelIndex & /*parent */) const
+ {
+-	return createIndex(row,column,0);
++	return createIndex(row,column,(void*) 0);
+ }
+ 
+ 
+Index: metview-4.5.6/src/Desktop/MvQIconObjectModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/MvQIconObjectModel.cc
++++ metview-4.5.6/src/Desktop/MvQIconObjectModel.cc
+@@ -95,7 +95,7 @@ QVariant MvQIconObjectModel::data( const
+ 
+ QModelIndex MvQIconObjectModel::index( int row, int column, const QModelIndex & /*parent */) const
+ {
+-	return createIndex(row,column,0);
++	return createIndex(row,column, (void*) 0);
+ }
+ 
+ 
+Index: metview-4.5.6/src/Desktop/MvQListFolderViewBase.cc
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/MvQListFolderViewBase.cc
++++ metview-4.5.6/src/Desktop/MvQListFolderViewBase.cc
+@@ -7,6 +7,7 @@
+ 
+  ***************************** LICENSE END *************************************/
+ 
++#include <QDrag>
+ #include <QApplication>
+ #include <QDataStream>
+ #include <QDropEvent>
+@@ -501,4 +502,4 @@ void MvQListFolderViewBase::blink(const
+ {
+   	scrollTo(index);
+   	delegate_->blink(index);
+-}	
+\ No newline at end of file
++}	
+Index: metview-4.5.6/src/Desktop/MvQNewIconWidget.cc
+===================================================================
+--- metview-4.5.6.orig/src/Desktop/MvQNewIconWidget.cc
++++ metview-4.5.6/src/Desktop/MvQNewIconWidget.cc
+@@ -9,6 +9,7 @@
+ 
+ #include "MvQNewIconWidget.h"
+ 
++#include <QtGui>
+ #include <QApplication>
+ #include <QButtonGroup>
+ #include <QComboBox>
+Index: metview-4.5.6/src/uPlot/ExportDialog.h
+===================================================================
+--- metview-4.5.6.orig/src/uPlot/ExportDialog.h
++++ metview-4.5.6/src/uPlot/ExportDialog.h
+@@ -10,6 +10,7 @@
+ #ifndef ExportDialog_H
+ #define ExportDialog_H
+ 
++#include <QtWidgets>
+ #include <QComboBox>
+ #include <QFileDialog>
+ #include <QGridLayout>
+Index: metview-4.5.6/src/uPlot/MvQLayerModel.cc
+===================================================================
+--- metview-4.5.6.orig/src/uPlot/MvQLayerModel.cc
++++ metview-4.5.6/src/uPlot/MvQLayerModel.cc
+@@ -687,7 +687,9 @@ void MvQLayerModel::moveLayer(int source
+ 	
+ 	//layers_[0]->scene()->update();
+ 
+-	reset();	
++	//reset();	
++	beginResetModel();
++	endResetModel();
+ }
+ 
+ string MvQLayerModel::layerId(const QModelIndex& index) 
+Index: metview-4.5.6/src/uPlot/MvQZoomStackWidget.h
+===================================================================
+--- metview-4.5.6.orig/src/uPlot/MvQZoomStackWidget.h
++++ metview-4.5.6/src/uPlot/MvQZoomStackWidget.h
+@@ -13,7 +13,8 @@
+ #include <QImage>
+ #include <QMap>
+ #include <QMenu>
+-#include <QPlastiqueStyle>
++// #include <QFusionStyle>
++#include <QFusionStyle>
+ #include <QProxyStyle>
+ 
+ class QAction;
+@@ -29,10 +30,10 @@ class MvQZoomStackMenuStyle : public QPr
+         int pixelMetric(PixelMetric, const QStyleOption *option=0, const QWidget *w=0) const;
+ };
+     
+-class MvQZoomStackMenuPlastiqueStyle : public QPlastiqueStyle
++class MvQZoomStackMenuFusionStyle : public QFusionStyle
+ {
+     public:
+-        MvQZoomStackMenuPlastiqueStyle() : QPlastiqueStyle() {};   
++        MvQZoomStackMenuFusionStyle() : QFusionStyle() {};   
+         int pixelMetric(PixelMetric, const QStyleOption *option=0, const QWidget *w=0) const;
+ };
+ 
diff --git a/debian/patches/series b/debian/patches/series
index 75dcc5f..65653cc 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@ fix-paths.patch
 fix-scripts.patch
 cmake-fixes.patch
 mv_compress.patch
+qt5.patch
diff --git a/debian/rules b/debian/rules
index ee9a78d..b9df1b3 100755
--- a/debian/rules
+++ b/debian/rules
@@ -7,6 +7,7 @@ DEB_BUILD_MAINT_OPTIONS:= hardening=+all,-format
 DEB_CFLAGS_MAINT_APPEND:= -Wall -pedantic -fPIC
 export DEB_BUILD_MAINT_OPTIONS
 export DEB_CFLAGS_MAINT_APPEND
+export QT_SELECT=5
 
 # Needed for sbuild. metview creates temp directories during build
 export HOME:=/tmp

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/metview.git



More information about the debian-science-commits mailing list