Merge pull request #238721 from K900/fix-tbe-build

tbe: fix build, clean up dependencies
This commit is contained in:
Francesco Gazzetta 2023-06-20 11:34:52 +02:00 committed by GitHub
commit b7b4da1663
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,4 @@
{ lib, mkDerivation, fetchFromGitHub, qt5, box2d, which, cmake, gettext }:
{ lib, mkDerivation, fetchFromGitHub, cmake, qttools, wrapQtAppsHook, qtbase, qtsvg }:
mkDerivation rec {
pname = "tbe";
@ -11,13 +11,16 @@ mkDerivation rec {
sha256 = "1ag2cp346f9bz9qy6za6q54id44d2ypvkyhvnjha14qzzapwaysj";
};
postPatch = "sed '1i#include <vector>' -i src/model/World.h";
postPatch = ''
sed '1i#include <vector>' -i src/model/World.h
nativeBuildInputs = [ cmake ];
buildInputs = [
qt5.qtbase qt5.qtsvg qt5.qttranslations box2d which
gettext
];
# fix translations not building: https://gitlab.kitware.com/cmake/cmake/-/issues/21931
substituteInPlace i18n/CMakeLists.txt --replace qt5_create_translation qt_add_translation
'';
nativeBuildInputs = [ cmake qttools wrapQtAppsHook ];
buildInputs = [ qtbase qtsvg ];
strictDeps = true;
installPhase = ''
make DESTDIR=.. install