From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andreas Enge Subject: Re: [PATCH 06/31] gnu: kwindowsystem: Update to 5.24.0. Date: Mon, 1 Aug 2016 23:10:34 +0200 Message-ID: <20160801211034.GG6728@solar> References: <20160801181342.16203-1-david@craven.ch> <20160801181342.16203-7-david@craven.ch> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43752) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bUKTz-0001BT-Hl for guix-devel@gnu.org; Mon, 01 Aug 2016 17:10:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bUKTv-0002Lp-27 for guix-devel@gnu.org; Mon, 01 Aug 2016 17:10:42 -0400 Received: from mailrelay1.public.one.com ([91.198.169.124]:50374) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bUKTu-0002Lb-H7 for guix-devel@gnu.org; Mon, 01 Aug 2016 17:10:38 -0400 Content-Disposition: inline In-Reply-To: <20160801181342.16203-7-david@craven.ch> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: David Craven Cc: guix-devel@gnu.org On Mon, Aug 01, 2016 at 08:13:17PM +0200, David Craven wrote: > * gnu/packages/kde-frameworks.scm: Update to 5.24.0. Here also, mention all changes: > - (uri (string-append "http://download.kde.org/stable/frameworks/" > + (uri (string-append "mirror://kde/stable/frameworks/" This. > (native-inputs > - `(("pkg-config" ,pkg-config) > + `(("extra-cmake-modules" ,extra-cmake-modules) > + ("pkg-config" ,pkg-config) > ("xorg-server" ,xorg-server))) ; for the tests > (inputs > - `(("extra-cmake-modules" ,extra-cmake-modules) The move of extra-cmake-modules. > - ("qt" ,qt) > + ("qtbase" ,qtbase) > + ("qtx11extras" ,qtx11extras) And the switch from the monolithic to the modular Qt. For qtx11extras that is not found, here is the error message: CMake Error at /gnu/store/6d3qjij1k7z2sjlsq9c0b8ql53xgn34v-qtbase-5.6.1-1/lib/cmake/Qt5/Qt5Config.cmake:26 (find_package): Could not find a package configuration file provided by "Qt5X11Extras" with any of the following names: Qt5X11ExtrasConfig.cmake qt5x11extras-config.cmake Add the installation prefix of "Qt5X11Extras" to CMAKE_PREFIX_PATH or set "Qt5X11Extras_DIR" to a directory containing one of the above files. If "Qt5X11Extras" provides a separate development package or SDK, be sure it has been installed. Call Stack (most recent call first): CMakeLists.txt:54 (find_package) -- Configuring incomplete, errors occurred! See also "/tmp/guix-build-kwindowsystem-5.24.0.drv-0/build/CMakeFiles/CMakeOutput.log". phase `configure' failed after 4.4 seconds One can go into /tmp/guix-build-kwindowsystem-5.24.0.drv-0 and look at the file environment-variables. It does contain export CMAKE_PREFIX_PATH="...:/gnu/store/3a5v3gh59hif13w7jqk8lhp5kvwbwk2i-qtx11extras-5.6.1-1/:..." This is the installation prefix, and it is added to CMAKE_PREFIX_PATH as required. Strange! Inside, in the directory lib/cmake/Qt5X11Extras/, there are Qt5X11ExtrasConfig.cmake and Qt5X11ExtrasConfigVersion.cmake. It should be possible to define the environment variable Qt5X11Extras_DIR, but it would be good to understand the problem... According to the cmake documentation: https://cmake.org/cmake/help/v3.0/command/find_package.html the Qt5X11ExtrasConfig.cmake file is searched for in the following directories (the "(U)" stands for "Unix"): /(lib/|lib|share)/cmake/*/ (U) /(lib/|lib|share)/*/ (U) /(lib/|lib|share)/*/(cmake|CMake)/ (U) In our case, the file is actually in /lib/cmake//, which should be fine. The exact failing line 54 of CMakeLists.txt is: find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED X11Extras) This actually does not correspond to the regular expression for find_package in the cmake documentation... I think it actually looks for Qt5Config.cmake, which it finds in qtbase, see the line in the above error message: CMake Error at /gnu/store/6d3qjij1k7z2sjlsq9c0b8ql53xgn34v-qtbase-5.6.1-1/lib/cmake/Qt5/Qt5Config.cmake:26 (find_package): Could not find a package configuration file provided by "Qt5X11Extras" with Lines 25 following of Qt5Config.cmake look like this: foreach(module ${Qt5_FIND_COMPONENTS}) find_package(Qt5${module} ${_Qt5_FIND_PARTS_QUIET} ${_Qt5_FIND_PARTS_REQUIRED} PATHS "${_qt5_install_prefix}" NO_DEFAULT_PATH ) So it looks like "find_package" is called with the argument "Qt5X11Extras", but also with the suspicious additional parameters PATHS "${_qt5_install_prefix}" NO_DEFAULT_PATH Since we install qt5x11extras to a different directory from qt5base, the thing following the PATHS keyword is probably wrong. See the cmake documentation: "The set of installation prefixes is constructed using the following steps. If NO_DEFAULT_PATH is specified all NO_* options are enabled. Search paths specified in cmake-specific cache variables. These are intended to be used on the command line with a -DVAR=value. This can be skipped if NO_CMAKE_PATH is passed: CMAKE_PREFIX_PATH CMAKE_FRAMEWORK_PATH CMAKE_APPBUNDLE_PATH" So I would say the error message is totally misleading; the NO_DEFAULT_PATH keyword explicitly disables the CMAKE_PREFIX_PATH. Unfortunately the store is read-only (in former times, I sometimes modified store items by hand; now I do not dare overwrite the special file system flags any more...), otherwise I would have tried to modify the file by hand... Sorry for the long message, which follows my own path in trying to debug this mess. To quickly summarise it: I think we need to modify the qtbase package to drop the NO_DEFAULT_PATH from Qt5Config.cmake. Ceterum censeo that cmake should not be used, but this is not our choice; autotools based projects usually do not create these problems... Andreas