wrapQtAppsHook: Remove ad hoc Qt wrappers

This commit is contained in:
Thomas Tuegel
2019-07-05 10:42:08 -05:00
parent f79fd2e826
commit 51d78034a1
43 changed files with 179 additions and 288 deletions
@@ -1,5 +1,5 @@
{ stdenv, fetchFromGitHub, gdal, cmake, ninja, proj, clipper, zlib, qtbase, qttools
, qtlocation, qtsensors, doxygen, cups, makeWrapper, qtimageformats
, qtlocation, qtsensors, doxygen, cups, wrapQtAppsHook, qtimageformats
}:
stdenv.mkDerivation rec {
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
buildInputs = [ gdal qtbase qttools qtlocation qtimageformats
qtsensors clipper zlib proj doxygen cups];
nativeBuildInputs = [ cmake makeWrapper ninja ];
nativeBuildInputs = [ cmake wrapQtAppsHook ninja ];
src = fetchFromGitHub {
owner = "OpenOrienteering";
@@ -48,9 +48,7 @@ stdenv.mkDerivation rec {
stdenv.lib.optionalString stdenv.isDarwin ''
# Fixes "This application failed to start because it could not find or load the Qt
# platform plugin "cocoa"."
wrapProgram $out/Mapper.app/Contents/MacOS/Mapper \
--set QT_QPA_PLATFORM_PLUGIN_PATH ${qtbase.bin}/lib/qt-*/plugins/platforms \
--set QT_PLUGIN_PATH ${qtbase.bin}/${qtbase.qtPluginPrefix}:${qtimageformats}/${qtbase.qtPluginPrefix}
wrapQtApp $out/Mapper.app/Contents/MacOS/Mapper
mkdir -p $out/bin
ln -s $out/Mapper.app/Contents/MacOS/Mapper $out/bin/mapper
'';