Skip to content

Conversation

ChrisX101010
Copy link

Fixes #8654

Description

SKIP_UTILS does not skip part of hashsum

Problem

The make install SKIP_UTILS="sha3-224sum sha3-256sum ..." command was not properly skipping hashsum utilities during installation, which was a barrier to packaging uutils as a drop-in replacement for coreutils.

Root Cause

The install logic only filtered from the INSTALLEES list, but hashsum utilities are provided by the multicall binary and needed to be filtered from the full utility list obtained via coreutils --list.

Solution

Replaced the old foreach loop with new logic that:

  1. Gets all available utilities from coreutils --list
  2. Properly filters against SKIP_UTILS using grep -qw
  3. Provides informative messages during installation
  4. Maintains backward compatibility

Testing

Verified the fix works correctly with:

  • ✅ sha3-224sum and sha3-256sum are correctly skipped
  • ✅ Other hashsum utilities (sha3-384sum, sha3-512sum, sha3sum) are correctly installed
  • ✅ Regular utilities continue to work normally
  • ✅ Multiple skip patterns work correctly
  • ✅ Edge cases handled properly

Changes Made

  • Modified GNUmakefile install target for multicall binaries
  • Removed old foreach loop logic
  • Added new filtering logic that uses coreutils --list
  • Added informative installation messages

Closes #8654

Completely replace the old install logic with new logic that:
1. Gets all available utilities from coreutils --list
2. Properly filters against SKIP_UTILS using grep -qw
3. Provides informative messages during installation
4. Handles both hashsum and regular utilities correctly

Fixes issue uutils#8654 where hashsum utilities were not being skipped
during installation despite being specified in SKIP_UTILS.

Testing verified:
- sha3-224sum and sha3-256sum are correctly skipped
- Other hashsum utilities are correctly installed
- Regular utilities continue to work normally
- Multiple skip patterns work correctly
- Edge cases (empty skip, non-existent utilities) handled properly
@oech3
Copy link
Contributor

oech3 commented Sep 21, 2025

I think filterling symlink is not a solution if binary size is kept.

@ChrisX101010
Copy link
Author

I think filterling symlink is not a solution if binary size is kept.

What do you propose as a different solution and I will make changes? Thank you for the feedback. Appreciate it.

@oech3
Copy link
Contributor

oech3 commented Sep 21, 2025

Maybe, this is more complex issue and should be solved at same time with solving #4414

@ChrisX101010
Copy link
Author

Maybe, this is more complex issue and should be solved at same time with solving #4414

Thank you, brother. I will research deeply into this issue then and the one you referenced me throughout the week. 🙂

Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/misc/tee (fails in this run but passes in the 'main' branch)
Skipping an intermittent issue tests/timeout/timeout (passes in this run but fails in the 'main' branch)

@oech3
Copy link
Contributor

oech3 commented Sep 22, 2025

I don't know how many people needs small indivisual (non-multicall) binaries. But I think hasusums are treated as same as other commands.

@ChrisX101010
Copy link
Author

I don't know how many people needs small indivisual (non-multicall) binaries. But I think hasusums are treated as same as other commands.

I saw someone mentioned an issue to remove multicall as a whole, so should I focus on this issue first then move on to this one? 🙂

@oech3
Copy link
Contributor

oech3 commented Sep 22, 2025

Maybe, yes. It should also fix some bugs automatically.
@sylvestre Do you think that multicall hashsum binary still needed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SKIP_UTILS does not skip part of hashsum
2 participants