Page MenuHomeFreeBSD

sysutils/debootstrap: Fix several issues
ClosedPublic

Authored by zirias on Feb 24 2023, 8:36 AM.
Tags
None
Referenced Files
F100627642: D38754.diff
Thu, Oct 17, 2:09 PM
F100597342: D38754.diff
Thu, Oct 17, 5:34 AM
Unknown Object (File)
Wed, Oct 16, 11:22 AM
Unknown Object (File)
Tue, Oct 15, 2:28 PM
Unknown Object (File)
Mon, Oct 14, 10:49 PM
Unknown Object (File)
Mon, Oct 14, 3:54 AM
Unknown Object (File)
Sun, Oct 13, 4:45 PM
Unknown Object (File)
Sat, Oct 12, 7:47 PM

Details

Summary
  • PORTVERSION may not contain '-', use 'n' instead to include the nmu-number from debian. (Pointy-hat: zirias)
  • Don't use substitutions on Makefile, pass variables instead
  • Eliminate "static" substitutions, use a patch-file instead
  • Fix hardcoded /usr/local in debootstrap script

PR: 269584

Diff Detail

Repository
rP FreeBSD ports repository
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 49986
Build 46878: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Feb 24 2023, 8:43 AM

Also remove substitutions that are now no-ops.

This revision now requires review to proceed.Feb 24 2023, 8:48 AM

And also make portclippy happy, as it's almost for free here

Rebase after committing the PORTVERSION fix separately

This revision is now accepted and ready to land.Feb 24 2023, 9:43 AM

Fix more hardcoded /usr/local after comment in PR 269584

This revision now requires review to proceed.Feb 24 2023, 4:31 PM

Updates look good to me. I like '#!/usr/bin/env bash' better (see comments in bug 269584, but I understand the tendency of the project toward hard-coded shebangs in most cases.

sysutils/debootstrap/Makefile
33–34

Lots of extra REINPLACE_CMD calls here. Less efficient and it triggers warnings if DEVELOPER=yes.

See also Bug 269584, comment 18 & comment 22.

sysutils/debootstrap/Makefile
39

See also bug 255525 suggesting pcre[2]grep instead of gnu grep. If nothing else pcregrep is a BSD license and probably maintained a little better than gnu grep. One less gnu dependency is good. And it's probably somewhat more likely someone has devel/pcre{,2} installed than ggrep due to more dependencies on pcre than gnugrep.

Could also use 'ggrep' instead of full path with LOCALBASE/bin.

zirias added inline comments.
sysutils/debootstrap/Makefile
33–34

It's the same number of invocations as in your suggestion....

39

Here as well, I'm not a fan of fixing things that aren't broken. Plus, upstream is Debian, expecting GNU tools, so I'd consider using GNU grep here more robust regarding possible future changes.

sysutils/debootstrap/Makefile
39

Agreed - valid point.

I think it looks good, feel free to commit.

This revision is now accepted and ready to land.Mar 7 2023, 4:49 PM
This revision was automatically updated to reflect the committed changes.
zirias marked an inline comment as done.