mkports

recipes for building multiple softwares with mk(1)
git clone git://z3bra.org/mkports
Log | Files | Refs

commit 7e51b336db4721fd84ae2fb9732fc116804441b5
parent d6a11a16456c2e2f5e6539fee46ccc06729f5993
Author: z3bra <willyatmailoodotorg>
Date:   Fri Jan 15 22:29:18 2016

musl: new port

Diffstat:
 musl/ldconfig | 18 ++++++++++++++++++
 musl/mkfile   | 14 ++++++++++++++
 2 files changed, 32 insertions(+), 0 deletions(-)

diff --git a/musl/ldconfig b/musl/ldconfig @@ -0,0 +1,18 @@ +#!/bin/sh +scan_dirs() { + scanelf -qS "$@" | while read SONAME FILE; do + TARGET="${FILE##*/}" + LINK="${FILE%/*}/$SONAME" + case "$FILE" in + /lib/*|/usr/lib/*|/usr/local/lib/*) ;; + *) [ -h "$LINK" -o ! -e "$LINK" ] && ln -sf "$TARGET" "$LINK" + esac + done + return 0 +} +# eat ldconfig options +while getopts "nNvXvf:C:r:" opt; do + : +done +shift $(( $OPTIND - 1 )) +[ $# -gt 0 ] && scan_dirs "$@" diff --git a/musl/mkfile b/musl/mkfile @@ -0,0 +1,14 @@ +pkg = musl +ver = 1.1.12 +url=http://www.musl-libc.org/releases/$pkg-$ver.tar.gz + +<../config.mk +<../default.mk + +install:QV: build + mkdir -p $pkg-$ver/.rootfs/bin + cd $pkg-$ver + make DESTDIR=$(pwd)/.rootfs install + ln -sf /lib/ld-musl-x86_64.so.1 .rootfs/bin/ldd + cp ../ldconfig .rootfs/bin/ldconfig + chmod 755 .rootfs/bin/ldconfig