flashprog: add new package - #30228
Conversation
BKPepe
left a comment
There was a problem hiding this comment.
The split into four variants makes sense if it provides a meaningful reduction in package size and/or dependencies, but the PR currently doesn't show that. Could you provide the package/installed sizes of the four variants (ideally including their dependencies) and briefly explain the intended use case for each variant?
Also, since flashprog is already provided as the full variant and the other variants all have the same description, it would be useful to clarify when a user should choose flashprog-spi, flashprog-pci, or flashprog-external instead of the default full package.
openwrt-ai
left a comment
There was a problem hiding this comment.
Fresh review of the single commit c84a34c. The commit message matches what the diff does (four variants, the programmer split, and the deliberate per-variant binary names), and the packaging basics look right: PKG_MAINTAINER is set, the define indentation follows the metadata/recipe convention, BuildPackage is called with literal package names, and test.sh avoids grep -q.
Two inline comments, both about the variant layout rather than about correctness — neither blocks a merge as far as I can tell.
Generated by Claude Code
c84a34c to
d1c85cd
Compare
|
Hi Josef, thanks for taking a look. I was skeptical of needing variants
Dependencies counted: flashprog-pci libpci; flashprog-external libftdi1, Every variant carries flashprog-pci adds the internal and PCI device programmers, which reach a flashprog-external adds the programmers that attach over USB, a serial port flashprog carries all of them. I have given each variant its own description saying which programmers it p.s. sorry for not including initially. I was desperately trying not to -dc |
d1c85cd to
e145aea
Compare
flashprog carries the four-variant package now on openwrt/packages#30228, with the per-variant descriptions the review asked for; ci-flashprog carries the apk-only check that verifies each variant's programmer set.
e145aea to
2379c6b
Compare
|
You ought to stick that table into the commit message, so non-github users can see it, too. |
2379c6b to
f176d9f
Compare
|
thanks @efahl, done, I edited commit message for terseness too (and put closes tag in the right place!). |
openwrt-ai
left a comment
There was a problem hiding this comment.
Re-review of the force-pushed f176d9f (replaces c84a34c). The branch was also rebased onto current master, so the only change to this PR's own files is in utils/flashprog/Makefile.
DEFAULT_VARIANT:=1 is gone, which resolves my earlier comment — with four distinct package names and no shared PROVIDES, it had no effect. The four per-variant descriptions are the standard $(call Package/<pkg>/Default/description) idiom used by ~100 other Makefiles in the feed, and the library lists match each variant's DEPENDS exactly. The commit message now carries the size table, its programmer counts are self-consistent (4 base + 17 pci + 16 external = 37 full) and match the numbers you posted in the thread, and the subject scope matches the files touched. All 14 checks are green on this head.
Two nits inline, neither blocking.
One earlier thread is still open and unanswered: the per-variant binary renaming on lines 124/129/134 means the command a user types depends on which variant they installed, so upstream docs and any script calling flashprog only work with the full variant. Your comment explains what each variant is for, which is useful, but doesn't say whether installing two of them side by side is an actual use case — that's the part that would justify renaming over CONFLICTS/ALTERNATIVES. Worth a line either way so the thread can be closed.
Generated by Claude Code
Detects, reads, writes, verifies and erases flash chips over SPI, LPC, FWH and parallel buses. Four variants split the programmers by the libraries they need; each installs the same binary under its own name, so any combination can be installed together. Installed size with dependency closure, x86/64, in bytes (libc, libpthread and librt excluded): | package | programmers | installed +deps | |--------------------|-------------|-----------------| | flashprog-spi | 4 | 684,818 | | flashprog-pci | 21 | 935,964 | | flashprog-external | 20 | 1,027,401 | | flashprog | 37 | 1,274,442 | Signed-off-by: David Connolly <david@connol.ly>
76dd009 to
0d71900
Compare
📦 Package Details
Maintainer: @connollydavid
Description:
Adds flashprog 1.5 in four variants, splitting the programmers by the libraries
they need.
🧪 Run Testing Details
Closes #29591
✅ Formalities
If your PR contains a patch:
This PR contains no patches.