17 src = fetchFromGitLab {
21 hash = "sha256-ufr2guaPdCvI5JOicL/lTrT3t6UlaY1hEB2xbwzhw6A=";
24 portmod-rust = rustPlatform.buildRustPackage rec {
26 pname = "portmod-rust";
28 cargoHash = "sha256-sAjgGVVjgXaWbmN/eGEvatYjkHeFTZNX1GXFcJqs3GI=";
31 python3Packages.python
40 python3Packages.virtualenv
48 python3Packages.buildPythonApplication rec {
54 # build the rust library independantly
56 substituteInPlace setup.py \
57 --replace "from setuptools_rust import Binding, RustExtension, Strip" "" \
58 --replace "RustExtension(\"portmodlib.portmod\", binding=Binding.PyO3, strip=Strip.Debug)" ""
60 substituteInPlace pyproject.toml \
61 --replace '"setuptools-rust"' ""
64 nativeBuildInputs = with python3Packages; [
69 propagatedBuildInputs = with python3Packages; [
87 nativeCheckInputs = with python3Packages; [
92 cp ${portmod-rust}/lib/libportmod.so portmodlib/portmod.so
93 export HOME=$(mktemp -d)
96 # some test require network access
100 "test_execute_network_permissions"
101 "test_execute_permissions_bleed"
106 "test_init_prefix_interactive"
111 # for some reason, installPhase doesn't copy the compiled binary
113 cp ${portmod-rust}/lib/libportmod.so $out/${python3Packages.python.sitePackages}/portmodlib/portmod.so
115 makeWrapperArgs+=("--prefix" "GIT_SSL_CAINFO" ":" "${cacert}/etc/ssl/certs/ca-bundle.crt" \
116 "--prefix" "PATH" ":" "${lib.makeBinPath bin-programs }")
120 description = "mod manager for openMW based on portage";
121 homepage = "https://gitlab.com/portmod/portmod";
122 license = licenses.gpl3Only;
123 maintainers = with maintainers; [ marius851000 ];