2020-04-24 23:36:52 +00:00
|
|
|
{ lib, fetchurl, boost, cmake, extra-cmake-modules, kparts, kpmcore
|
|
|
|
, kservice, libatasmart, libxcb, libyamlcpp, parted, polkit-qt, python, qtbase
|
2021-03-09 03:18:52 +00:00
|
|
|
, qtquickcontrols, qtsvg, qttools, qtwebengine, util-linux, tzdata
|
2020-04-24 23:36:52 +00:00
|
|
|
, ckbcomp, xkeyboard_config, mkDerivation
|
|
|
|
}:
|
|
|
|
|
|
|
|
mkDerivation rec {
|
|
|
|
pname = "calamares";
|
2021-09-18 10:52:07 +00:00
|
|
|
version = "3.2.42";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
# release including submodule
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/${pname}/${pname}/releases/download/v${version}/${pname}-${version}.tar.gz";
|
2021-09-18 10:52:07 +00:00
|
|
|
sha256 = "sha256-NbtgtbhauEo7EGvNUNltUQRBpLlzBjAR0GLL9CadgsQ=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-12-29 15:07:52 +00:00
|
|
|
nativeBuildInputs = [ cmake extra-cmake-modules ];
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [
|
2020-12-29 15:07:52 +00:00
|
|
|
boost kparts.dev kpmcore.out kservice.dev
|
2020-04-24 23:36:52 +00:00
|
|
|
libatasmart libxcb libyamlcpp parted polkit-qt python qtbase
|
2020-11-24 20:58:05 +00:00
|
|
|
qtquickcontrols qtsvg qttools qtwebengine.dev util-linux
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
cmakeFlags = [
|
|
|
|
"-DPYTHON_LIBRARY=${python}/lib/lib${python.libPrefix}.so"
|
|
|
|
"-DPYTHON_INCLUDE_DIR=${python}/include/${python.libPrefix}"
|
|
|
|
"-DCMAKE_VERBOSE_MAKEFILE=True"
|
|
|
|
"-DCMAKE_BUILD_TYPE=Release"
|
|
|
|
"-DWITH_PYTHONQT:BOOL=ON"
|
|
|
|
];
|
|
|
|
|
|
|
|
POLKITQT-1_POLICY_FILES_INSTALL_DIR = "$(out)/share/polkit-1/actions";
|
|
|
|
|
2020-12-29 15:07:52 +00:00
|
|
|
postPatch = ''
|
2020-04-24 23:36:52 +00:00
|
|
|
sed -e "s,/usr/bin/calamares,$out/bin/calamares," \
|
|
|
|
-i calamares.desktop \
|
|
|
|
-i com.github.calamares.calamares.policy
|
|
|
|
|
|
|
|
sed -e 's,/usr/share/zoneinfo,${tzdata}/share/zoneinfo,' \
|
|
|
|
-i src/modules/locale/SetTimezoneJob.cpp
|
|
|
|
|
|
|
|
sed -e 's,/usr/share/X11/xkb/rules/base.lst,${xkeyboard_config}/share/X11/xkb/rules/base.lst,' \
|
|
|
|
-i src/modules/keyboard/keyboardwidget/keyboardglobal.h
|
|
|
|
|
|
|
|
sed -e 's,"ckbcomp","${ckbcomp}/bin/ckbcomp",' \
|
|
|
|
-i src/modules/keyboard/keyboardwidget/keyboardpreview.cpp
|
|
|
|
|
|
|
|
sed "s,\''${POLKITQT-1_POLICY_FILES_INSTALL_DIR},''${out}/share/polkit-1/actions," \
|
|
|
|
-i CMakeLists.txt
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Distribution-independent installer framework";
|
2020-12-29 15:07:52 +00:00
|
|
|
license = with licenses; [ gpl3Plus bsd2 ];
|
|
|
|
maintainers = with maintainers; [ manveru ];
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|