Skip to content

Commit

Permalink
Specify make targets explicitly in nix package
Browse files Browse the repository at this point in the history
Instead of patching the makefile's `all` target, we can specify the
targets we want to build or install explicitly via make flags.
  • Loading branch information
MattSturgeon committed Jan 31, 2025
1 parent afc8d5d commit f2b6f21
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 31 deletions.
24 changes: 0 additions & 24 deletions packaging/nix/0-Makefile-no-vendor.patch

This file was deleted.

29 changes: 22 additions & 7 deletions packaging/nix/unwrapped.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,28 @@ umu-launcher-unwrapped.overridePythonAttrs (prev: {
# https://github.com/Open-Wine-Components/umu-launcher/pull/289
# - The other is backporting:
# https://github.com/Open-Wine-Components/umu-launcher/pull/343
patches = [
# Remove `umu-vendored` from the `all` target
# This causes an error when building vendored dependencies:
# python3 -m pip install urllib3 -t builddir
# => No module named pip
./0-Makefile-no-vendor.patch
];
patches = [];

# The `all` target contains `umu-vendored` which causes an error:
# cd: subprojects/urllib3: No such file or directory
#
# Avoid this by specifying build targets explicitly
buildFlags =
(prev.buildFlags or [])
++ [
"umu-dist"
"umu-launcher"
];

# Same issue for install targets
installTargets =
(prev.installTargets or [])
++ [
"umu-dist"
"umu-docs"
"umu-launcher"
"umu-delta"
];

nativeBuildInputs =
(prev.nativeBuildInputs or [])
Expand Down

0 comments on commit f2b6f21

Please sign in to comment.