Hello community, here is the log from the commit of package gammaray for openSUSE:Factory checked in at 2019-06-07 12:18:57 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/gammaray (Old) and /work/SRC/openSUSE:Factory/.gammaray.new.4811 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "gammaray" Fri Jun 7 12:18:57 2019 rev:10 rq:702829 version:2.10.0 Changes: -------- --- /work/SRC/openSUSE:Factory/gammaray/gammaray.changes 2019-05-02 19:16:24.873318467 +0200 +++ /work/SRC/openSUSE:Factory/.gammaray.new.4811/gammaray.changes 2019-06-07 12:18:58.600778816 +0200 @@ -1,0 +2,6 @@ +Tue May 14 11:52:44 UTC 2019 - Christophe Giboudeaux <christo...@krop.fr> + +- Add 0001-Make-sure-the-defined-variables-are-relative-before-.patch + to fix runtime issues. + +------------------------------------------------------------------- New: ---- 0001-Make-sure-the-defined-variables-are-relative-before-.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ gammaray.spec ++++++ --- /var/tmp/diff_new_pack.wfMDt0/_old 2019-06-07 12:18:59.120778650 +0200 +++ /var/tmp/diff_new_pack.wfMDt0/_new 2019-06-07 12:18:59.124778649 +0200 @@ -29,6 +29,8 @@ Patch0: Fix_icons_installation.patch # PATCH-FIX-UPSTREAM fix-build-with-qt-5.13.patch Patch1: fix-build-with-qt-5.13.patch +# PATCH-FIX-UPSTREAM 0001-Make-sure-the-defined-variables-are-relative-before-.patch +Patch2: 0001-Make-sure-the-defined-variables-are-relative-before-.patch BuildRequires: binutils-devel BuildRequires: cmake >= 3.1 BuildRequires: doxygen @@ -106,8 +108,7 @@ frameworks in Qt. Development files. %prep -%setup -q -%autopatch -p1 +%autosetup -p1 %build %cmake \ ++++++ 0001-Make-sure-the-defined-variables-are-relative-before-.patch ++++++ >From f36b102b16711efe03ea3d1908daa80c04693fd8 Mon Sep 17 00:00:00 2001 From: Christophe Giboudeaux <christo...@krop.fr> Date: Mon, 13 May 2019 19:22:35 +0200 Subject: [PATCH] Make sure the defined variables are relative before setting 'GAMMARAY_INVERSE_*' If absolute paths are used when running CMake, config-gammaray.h may contain bogus values for GAMMARAY_INVERSE_* variables. This can cause runtime errors and/or warnings when GammaRay tries to locate the gammaray-launcher binary or the documentation files. --- CMakeLists.txt | 8 ++++++-- cmake/GammaRayMacrosInternal.cmake | 7 +++++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 86d7db47..5a81156f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -669,19 +669,23 @@ else() include(GNUInstallDirs) set(BIN_INSTALL_DIR "${CMAKE_INSTALL_BINDIR}") # relative, usually "bin" + gammaray_convert_to_relative_path(BIN_INSTALL_DIR) if(GAMMARAY_INSTALL_QT_LAYOUT) set(LIB_INSTALL_DIR "lib") # Qt always uses "lib" else() - set(LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}") # "lib" or "lib64" + set(LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}") # "lib" or "lib64" + gammaray_convert_to_relative_path(LIB_INSTALL_DIR) endif() set(INCLUDE_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}/gammaray") set(CMAKECONFIG_INSTALL_DIR ${LIB_INSTALL_DIR}/cmake/GammaRay) set(DATAROOTDIR "${CMAKE_INSTALL_DATAROOTDIR}" CACHE PATH "Define install directory for read-only architecture-independent data") + gammaray_convert_to_relative_path(DATAROOTDIR) set(XDG_APPS_INSTALL_DIR "${DATAROOTDIR}/applications") set(APPDATA_INSTALL_DIR "${DATAROOTDIR}/appdata") set(ICON_INSTALL_DIR "${DATAROOTDIR}/icons") set(MAN_INSTALL_DIR "${DATAROOTDIR}/man/man1") - set(QCH_INSTALL_DIR "${CMAKE_INSTALL_DOCDIR}" CACHE STRING "Install location of Qt Assistant help files.") + set(QCH_INSTALL_DIR "${CMAKE_INSTALL_DOCDIR}" CACHE PATH "Install location of Qt Assistant help files.") + gammaray_convert_to_relative_path(QCH_INSTALL_DIR) if(WIN32) set(PLUGIN_INSTALL_DIR "plugins/gammaray") set(LIBEXEC_INSTALL_DIR "${BIN_INSTALL_DIR}") diff --git a/cmake/GammaRayMacrosInternal.cmake b/cmake/GammaRayMacrosInternal.cmake index 7ef4851a..9044e9b2 100644 --- a/cmake/GammaRayMacrosInternal.cmake +++ b/cmake/GammaRayMacrosInternal.cmake @@ -94,6 +94,13 @@ macro(gammaray_join_list _var _sep) endforeach() endmacro() +macro(gammaray_convert_to_relative_path _var) + # Make sure _var is a relative path + if(IS_ABSOLUTE "${${_var}}") + file(RELATIVE_PATH ${_var} "${CMAKE_INSTALL_PREFIX}" "${${_var}}") + endif() +endmacro() + macro(gammaray_inverse_dir _var _prefix) # strip out relative components, those break the following on OSX get_filename_component(_clean_prefix "${CMAKE_INSTALL_PREFIX}/${_prefix}" ABSOLUTE) -- 2.21.0