aboutsummaryrefslogtreecommitdiff
path: root/core/musl/build
diff options
context:
space:
mode:
authorCem Keylan <cem@ckyln.com>2019-12-09 19:17:24 +0300
committerCem Keylan <cem@ckyln.com>2019-12-09 19:17:24 +0300
commit03423e0583057cbe5a16f8439183e2dbc0e8dd7c (patch)
tree81fe3ba69d94146f83fb5541d1fb2da0ac4eac08 /core/musl/build
downloadrepository-03423e0583057cbe5a16f8439183e2dbc0e8dd7c.tar.gz
secondary commit
Diffstat (limited to 'core/musl/build')
-rwxr-xr-xcore/musl/build19
1 files changed, 19 insertions, 0 deletions
diff --git a/core/musl/build b/core/musl/build
new file mode 100755
index 00000000..b2c7144f
--- /dev/null
+++ b/core/musl/build
@@ -0,0 +1,19 @@
+#!/bin/sh -e
+
+./configure \
+ --prefix=/usr \
+ --syslibdir=/usr/lib
+
+make
+make DESTDIR="$1" install
+
+mkdir -p "$1/usr/bin"
+ln -s "/usr/lib/ld-musl-x86_64.so.1" "$1/usr/bin/ldd"
+
+# Install BSD compatibility headers.
+install -Dm 755 cdefs.h "$1/usr/include/sys/cdefs.h"
+install -Dm 755 queue.h "$1/usr/include/sys/queue.h"
+install -Dm 755 tree.h "$1/usr/include/sys/tree.h"
+
+# Install getconf.
+cc getconf.c -o "$1/usr/bin/getconf"