[Buildroot] [git commit branch/2021.02.x] package/gawk: create awk symlink for host-gawk
From: Peter Korsgaard <peter@korsgaard.com>
Date: 2021-07-10 17:21:47
Subsystem:
the rest · Maintainer:
Linus Torvalds
From: Peter Korsgaard <peter@korsgaard.com>
Date: 2021-07-10 17:21:47
Subsystem:
the rest · Maintainer:
Linus Torvalds
commit: https://git.buildroot.net/buildroot/commit/?id=e16bb3a0da4317814d0926f41b6e5f8b4016f44d branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2021.02.x This is to make sure that host packages that depend on `host-gawk` and that use `awk` end up using `gawk`, instead of the `awk` symlink installed on the host system. On recent Debian-based distributions, `awk` is still symlinked to `mawk` [1]. [1] https://bugs.launchpad.net/ubuntu/+source/mawk/+bug/1841654 Signed-off-by: Hubert Lacote <redacted> Co-authored-by: Hubert Lacote [off-list ref] Co-authored-by: Vicente Olivert Riera [off-list ref] [yann.morin.1998 at free.fr: move after the target symlink hook] Signed-off-by: Yann E. MORIN <redacted> (cherry picked from commit 150038166fafae5c596e1e8ca7572bf8b6793a6d) Signed-off-by: Peter Korsgaard <peter@korsgaard.com> --- package/gawk/gawk.mk | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/package/gawk/gawk.mk b/package/gawk/gawk.mk
index 16906f6f93..ae2bbe5422 100644
--- a/package/gawk/gawk.mk
+++ b/package/gawk/gawk.mk@@ -39,5 +39,11 @@ endef GAWK_POST_INSTALL_TARGET_HOOKS += GAWK_CREATE_SYMLINK +define HOST_GAWK_CREATE_SYMLINK + ln -sf gawk $(HOST_DIR)/usr/bin/awk +endef + +HOST_GAWK_POST_INSTALL_HOOKS += HOST_GAWK_CREATE_SYMLINK + $(eval $(autotools-package)) $(eval $(host-autotools-package))