James Cloos <cl...@jhcloos.com> wrote: > >>>>> "PH" == Perry Hutchison <pl...@agora.rdrop.com> writes: > > PH> The links are *normally* included in a busybox installation. Sheesh! > > not by default; it is optional. > > on gentoo one has to use USE=make-symlinks. > > debian does not install links (sym or hard) by default.
Because Debian is a desktop/server distro, which ordinarily uses full-blown executables. On (Debian-derived) Ubuntu: $ type awk awk is /usr/bin/awk $ ll -i /usr/bin/awk 5505113 lrwxrwxrwx 1 root root 21 Jun 7 2019 /usr/bin/awk -> /etc/alternatives/awk* $ ll -i /etc/alternatives/awk 6839074 lrwxrwxrwx 1 root root 13 Jun 14 2019 /etc/alternatives/awk -> /usr/bin/gawk* $ ll -i /usr/bin/gawk 5505388 -rwxr-xr-x 1 root root 662168 Aug 17 2023 /usr/bin/gawk* $ type busybox busybox is /bin/busybox $ ll -i /bin/busybox 1048581 -rwxr-xr-x 1 root root 2066752 Aug 30 2023 /bin/busybox* # So there are no other hard links to the busybox executable. # Look for symlinks (in the same directory). $ ( cd /bin && ll | grep busybox ) -rwxr-xr-x 1 root root 2066752 Aug 30 2023 busybox* lrwxrwxrwx 1 root root 7 Aug 30 2023 static-sh -> busybox* $ file /bin/busybox /bin/busybox: ELF 64-bit LSB executable ... statically linked ... That statically linked busybox is in /bin, and its shell is configured to recognize its applets in command lines without needing links to find them. IOW it is intended as a recovery environment, for use when things are fouled up, rather than as a development environment. Meanwhile (g)awk is in /usr/bin -- along with most if not all of the other full-blown executables. > afaict, only the dists which use bb applets by default do so. > > but the point was that the binary does not require them. > > so if a dist lacks awk in $PATH, but has busybox in $PATH, then calling > "busybox awk $rest" could be checked so as to make the scripts work. > > i only asked whether that would be useful for the autotools, just in > case it is the only already-installed option. > > i do not understand the negativity to that. How many distros do you know of which * provide a busybox containing awk, * do not provide any other awk, and * do not provide an awk -> busybox/awk link? I suspect the number is vanishingly small. If autoconf routinely checked for unlinked busybox versions of other commands (e.g. sed), it would make sense to do the same for awk. But why should we go to that extra trouble *only* for awk?