mirror of
https://github.com/openwrt/openwrt.git
synced 2026-10-14 06:38:29 +04:00
Commit4071398b13replaced $(VERSION_DIST) in the netgear-dni and netgear-encrypted-factory recipes with $(shell cat $(VERSION_DIST) | sed ...) to turn whitespace into dashes. VERSION_DIST holds the distribution name such as "OpenWrt" and not a file name, so cat fails with "No such file or directory" and the expansion is always empty. The change was meant to let a distribution name with a space, such as "ColVisTec AG", pass through the argument parsing of netgear-encrypted-factory.py as "ColVisTec-AG". What it produced instead was an empty string for every distribution name, including the one it was written for. The build error went away only because an empty string contains no whitespace. Since then, the DNI header of the Netgear images carries "version:V.r12345" instead of "version:VOpenWrt.r12345", and the encrypted factory images get "V1.0.0.0..r12345" with an empty field between two dots instead of "V1.0.0.0.OpenWrt.r12345". The distribution name has been part of the Netgear version string since commit6d2fa1c896added the first WNDR3700 factory image in 2009, and the encrypted factory recipe used it from its introduction in commitefca76ffce. Use $(subst $(space),-,$(VERSION_DIST)) instead, which restores the distribution name and still replaces spaces with dashes as intended. Fixes:4071398b13("build: escape whitespaces in VERSION_DIST for Netgear images") Signed-off-by: Grische <github@grische.xyz> Assisted-by: Claude:claude-opus-5-5 Link: https://github.com/openwrt/openwrt/pull/25674 Signed-off-by: Robert Marko <robimarko@gmail.com>