| git.druid.rocks | index | druid520 | ports | ports/ | libraries/ | libbsd/ | add.sh |
ports/libraries/libbsd/add.sh
set -e
# freedesktop.org's userspace BSD-compatibility library -- provides the
# BSD headers/functions musl doesn't (sys/queue.h, sys/tree.h, strlcpy,
# setproctitle, ...) via its "overlay" pkg-config module (libbsd-overlay:
# an -isystem into a bsd/ header directory that shadows the system one,
# so plain "#include <sys/queue.h>" just works), which is exactly what
# several BSD-portability-minded ports here already assume is available
# (editors/mg's own GNUmakefile, for one -- see its own
# "pkg-config --cflags libbsd-overlay" branch). needs libmd (its MD5/
# SHA* digest wrappers are deprecated stubs delegating to the real
# implementation there) at configure time, hard: "cannot find required
# MD5 functions in libc or libmd" otherwise.
#
# source checkout deliberately NOT self-cleaned -- see libraries/libmd's
# own add.sh comment for why (del.sh needs it).
git clone https://gitlab.freedesktop.org/libbsd/libbsd.git
cd libbsd
autoreconf -fi
./configure --prefix=$MP_PREFIX
make
make install
make clean || true