diff mbox series

[OpenWrt-Devel] kernel.mk: fix kmod VERSION string

Message ID 20180706121322.31418-1-fe@dev.tdt.de
State Rejected
Delegated to: John Crispin
Headers show
Series [OpenWrt-Devel] kernel.mk: fix kmod VERSION string | expand

Commit Message

Florian Eckert July 6, 2018, 12:13 p.m. UTC
If a "+" is in the version string of a kernel package then the package could
not get installed by opkg with ftp. Because the file could not get found.
"kmod-wireguard_4.4.135%2b0.0.20180519-1_mips_24kc.ipk: No such file or directory"
The problem is that "+" is replaced with "%2b".

Change the "+" in version string to "-" will solve this issue.

Kmod version string:
old: $(LINUX_VERSIO)+$(PKG_VERSION)-$(PKG_RELEASE)
new: $(LINUX_VERSIO)-$(PKG_VERSION)-$(PKG_RELEASE)

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
---
 include/kernel.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

John Crispin July 12, 2018, 7:11 a.m. UTC | #1
On 06/07/18 14:13, Florian Eckert wrote:
> If a "+" is in the version string of a kernel package then the package could
> not get installed by opkg with ftp. Because the file could not get found.
> "kmod-wireguard_4.4.135%2b0.0.20180519-1_mips_24kc.ipk: No such file or directory"
> The problem is that "+" is replaced with "%2b".
>
> Change the "+" in version string to "-" will solve this issue.
>
> Kmod version string:
> old: $(LINUX_VERSIO)+$(PKG_VERSION)-$(PKG_RELEASE)
> new: $(LINUX_VERSIO)-$(PKG_VERSION)-$(PKG_RELEASE)
this needs to be fixed in opkg or wget. ftp urls should not be encoded.
     John

> Signed-off-by: Florian Eckert <fe@dev.tdt.de>
> ---
>   include/kernel.mk | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/kernel.mk b/include/kernel.mk
> index c169550f48..cd186e9d3b 100644
> --- a/include/kernel.mk
> +++ b/include/kernel.mk
> @@ -196,7 +196,7 @@ define KernelPackage
>       CATEGORY:=Kernel modules
>       DESCRIPTION:=$(DESCRIPTION)
>       EXTRA_DEPENDS:=kernel (=$(LINUX_VERSION)-$(LINUX_RELEASE)-$(LINUX_VERMAGIC))
> -    VERSION:=$(LINUX_VERSION)$(if $(PKG_VERSION),+$(PKG_VERSION))-$(if $(PKG_RELEASE),$(PKG_RELEASE),$(LINUX_RELEASE))
> +    VERSION:=$(LINUX_VERSION)$(if $(PKG_VERSION),-$(PKG_VERSION))-$(if $(PKG_RELEASE),$(PKG_RELEASE),$(LINUX_RELEASE))
>       PKGFLAGS:=$(PKGFLAGS)
>       $(call KernelPackage/$(1))
>       $(call KernelPackage/$(1)/$(BOARD))
diff mbox series

Patch

diff --git a/include/kernel.mk b/include/kernel.mk
index c169550f48..cd186e9d3b 100644
--- a/include/kernel.mk
+++ b/include/kernel.mk
@@ -196,7 +196,7 @@  define KernelPackage
     CATEGORY:=Kernel modules
     DESCRIPTION:=$(DESCRIPTION)
     EXTRA_DEPENDS:=kernel (=$(LINUX_VERSION)-$(LINUX_RELEASE)-$(LINUX_VERMAGIC))
-    VERSION:=$(LINUX_VERSION)$(if $(PKG_VERSION),+$(PKG_VERSION))-$(if $(PKG_RELEASE),$(PKG_RELEASE),$(LINUX_RELEASE))
+    VERSION:=$(LINUX_VERSION)$(if $(PKG_VERSION),-$(PKG_VERSION))-$(if $(PKG_RELEASE),$(PKG_RELEASE),$(LINUX_RELEASE))
     PKGFLAGS:=$(PKGFLAGS)
     $(call KernelPackage/$(1))
     $(call KernelPackage/$(1)/$(BOARD))