a few more musl compat fixes

using those and a somewhat shitty and hackish gnu makefile (not included), the following applets build against musl:
(note that this is only the set compiling without additional dependencies like openssl, and excluding any shell scripts such as "true")

````
apply
ar
arch
asa
awk
banner
basename
biff
cal
cat
cmp
col
colrm
column
comm
csplit
ctags
cut
dd
deroff
diff
diff3
dirname
domainname
echo
ed
env
expand
expr
fgen
file
file2c
finger
fmt
fold
from
fsplit
getconf
getopt
head
hexdump
hostname
id
indent
ipcrm
join
jot
kill
ksh
lam
last
leave
ln
lndir
logger
logname
look
m4
mail
man
mesg
mkdir
mkstr
mktemp
mv
nice
nohup
paste
patch
pr
printenv
printf
pwd
rcs
readlink
rev
rmail
rmdir
rs
sdiff
sed
sleep
spell
split
sync
tee
test
time
touch
tr
tsort
tty
uname
unexpand
unifdef
uniq
unvis
users
uudecode
uuencode
vis
wall
wc
what
which
who
whois
write
xargs
xstr
yacc
yes
````