Message ID | 20191123151140.1116717-1-fabian@blaese.de |
---|---|
State | Rejected |
Headers | show |
diff --git a/buildscript b/buildscript index 4c54aec..4a49ca7 100755 --- a/buildscript +++ b/buildscript @@ -297,7 +297,8 @@ cp_firmware() { for image in ${images[@]}; do filename_build=${image//openwrt/fff-${version}} filename_build=${filename_build//squashfs-/} - filename_build=${filename_build//${chipset}-${subtarget}-/} + filename_build=${filename_build//${chipset}-/} + filename_build=${filename_build//${subtarget}-/} cp "$builddir/bin/targets/${chipset}/${subtarget}/$image" "./bin/$filename_build" for region in "" "-eu" "-us"; do
Muss man dann sicherstellen, dass nur der erste Match von subtarget gelöscht wird, sonst entfernt das ggf. tiny oder generic aus dem Device-Namen. Das ist aber ja glaube ich Standard (zumindest bei sed). Ich würde hier allerdings überlegen, ob man mit dem Support für den C2600 warten will, bis die Firmware auf 19.07 ist, dann kann man sich den ganzen Kram nämlich sparen (ipq40xx und ipq806x haben ab da einen generic subtarget, um den Sonderfall zu vermeiden). Sofern wie oben vermutet nur einmal gematcht wird, gilt das als Reviewed-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> > -----Original Message----- > From: franken-dev [mailto:franken-dev-bounces@freifunk.net] On Behalf > Of Fabian Bläse > Sent: Samstag, 23. November 2019 16:12 > To: franken-dev@freifunk.net > Subject: [PATCH] buildscript: seperate removal of target/subtarget > > In OpenWRT 18.06 there are targets, that don't have their subtarget in the > filename as they only have one subtarget. > > If target and subtarget are removed in one regex, this regex doesn't match > the target in these filenames. > > By splitting the removal into two regex, the removal works for both filename > with only target and filenames with target/subtarget. > > Signed-off-by: Fabian Bläse <fabian@blaese.de> > --- > Has to be applied before merging ipq806x devices (Archer C2600) > --- > buildscript | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/buildscript b/buildscript > index 4c54aec..4a49ca7 100755 > --- a/buildscript > +++ b/buildscript > @@ -297,7 +297,8 @@ cp_firmware() { > for image in ${images[@]}; do > filename_build=${image//openwrt/fff-${version}} > filename_build=${filename_build//squashfs-/} > - filename_build=${filename_build//${chipset}-${subtarget}-/} > + filename_build=${filename_build//${chipset}-/} > + filename_build=${filename_build//${subtarget}-/} > cp "$builddir/bin/targets/${chipset}/${subtarget}/$image" > "./bin/$filename_build" > > for region in "" "-eu" "-us"; do > -- > 2.24.0
On 23.11.19 17:48, mail@adrianschmutzler.de wrote:
> Muss man dann sicherstellen, dass nur der erste Match von subtarget gelöscht wird, sonst entfernt das ggf. tiny oder generic aus dem Device-Namen. Das ist aber ja glaube ich Standard (zumindest bei sed).
Dem ist so, ja.
Mit OpenWrt 19.07 hat sich das jetzt aber (erstmal) erledigt.
Ggf. können wir das später irgendwann nochmal ausgraben.
Fabian
In OpenWRT 18.06 there are targets, that don't have their subtarget in the filename as they only have one subtarget. If target and subtarget are removed in one regex, this regex doesn't match the target in these filenames. By splitting the removal into two regex, the removal works for both filename with only target and filenames with target/subtarget. Signed-off-by: Fabian Bläse <fabian@blaese.de> --- Has to be applied before merging ipq806x devices (Archer C2600) --- buildscript | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)