Skip to content

chore(deps): Downgrade 7zip to v16.02 in nix packaging #1167

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .envrc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
source_env_if_exists .envrc.user

if ${UNBLOB_USE_DEVENV:-true}; then
watch_file flake.nix flake.lock devenv.nix
watch_file *.nix flake.lock
use nix \
--option extra-substituters "https://unblob.cachix.org" \
--option extra-trusted-public-keys "unblob.cachix.org-1:5kWA6DwOg176rSqU8TOTBXWxsDB4LoCMfGfTgL5qCAE="
Expand Down
11 changes: 11 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,17 @@ repos:
- nix-command flakes
- --accept-flake-config
- fmt
- id: statix
name: Lint Nix (statix)
types: [nix]
pass_filenames: false
language: system
entry: bash -c 'command -v nix && statix fix "$@" || echo "skipping statix"'
- id: deadnix
name: Lint Nix (deadnix)
types: [nix]
language: system
entry: bash -c 'command -v nix && deadnix --edit "$@" || echo "skipping deadnix"'
- id: taplo-format
name: Format TOML (taplo)
language: system
Expand Down
3 changes: 3 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,9 @@
python3Packages.patchVenvShellHook
python3Packages.autoPatchelfVenvShellHook

deadnix
statix

cargo
rustc

Expand Down
21 changes: 21 additions & 0 deletions overlay.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,26 @@ final: prev:
nativeCheckInputs = (super.nativeCheckInputs or [ ]) ++ [ final.which ];
});

p7zip16 = prev.p7zip.overrideAttrs (super: rec {
pname = "p7zip16";
version = "16.02";
srcs = [
(final.fetchurl {
url = "mirror://sourceforge/p7zip/p7zip_${version}_src_all.tar.bz2";
sha256 = "5eb20ac0e2944f6cb9c2d51dd6c4518941c185347d4089ea89087ffdd6e2341f";
})
(final.fetchurl {
url = "http://deb.debian.org/debian/pool/main/p/p7zip/p7zip_${version}+dfsg-8.debian.tar.xz";
sha256 = "sha256-ASF9yhZnrw3kiTWlHcRqrUQubryseZ1xQQG37fllHrU=";
})
];
sourceRoot = "p7zip_${version}";
nativeBuildInputs = (super.nativeBuildInputs or [ ]) ++ [ final.quilt ];
prePatch = ''
export QUILT_PATCHES=../debian/patches
quilt push -a
'';
});

unblob = final.callPackage ./package.nix { };
}
11 changes: 5 additions & 6 deletions package.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
{
lib,
python3,
fetchFromGitHub,
makeWrapper,
e2fsprogs-nofortify,
erofs-utils,
jefferson,
lz4,
lziprecover,
lzop,
p7zip,
p7zip16,
nix-filter,
sasquatch,
sasquatch-v4be,
Expand All @@ -29,7 +28,7 @@ let
jefferson
lziprecover
lzop
p7zip
p7zip16
sasquatch
sasquatch-v4be
ubi_reader
Expand All @@ -38,10 +37,10 @@ let
zstd
lz4
];
pyproject_toml = (builtins.fromTOML (builtins.readFile ./pyproject.toml));
version = pyproject_toml.project.version;
pyproject_toml = builtins.fromTOML (builtins.readFile ./pyproject.toml);
inherit (pyproject_toml.project) version;
in
python3.pkgs.buildPythonApplication rec {
python3.pkgs.buildPythonApplication {
pname = "unblob";
pyproject = true;
disabled = python3.pkgs.pythonOlder "3.9";
Expand Down
Loading