summaryrefslogtreecommitdiff
path: root/repo
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2022-02-27 00:55:34 +0000
committerdavidovski <david@davidovski.xyz>2022-02-27 00:55:34 +0000
commit79c82d8fc0a4f6618429a0373bb832afd105543e (patch)
tree81353122644b10b2c3d5be52bf3524890cbc377b /repo
parent7e7775ad670c99b2823d812c782f6ff258e79b9b (diff)
added all missing libraries and headers that musl doesnt have
Diffstat (limited to 'repo')
-rw-r--r--repo/devel/make.xibuild2
-rw-r--r--repo/meta/base.xibuild2
-rw-r--r--repo/system/argp-standalone.xibuild24
-rw-r--r--repo/system/gettext.xibuild28
-rw-r--r--repo/system/musl-fts.xibuild27
-rw-r--r--repo/system/musl-legacy-compat.xibuild21
-rw-r--r--repo/system/musl-obstack.xibuild24
-rw-r--r--repo/system/musl.xibuild13
-rw-r--r--repo/system/ncurses.xibuild13
-rw-r--r--repo/system/skalibs.xibuild22
-rw-r--r--repo/system/utmps.xibuild38
11 files changed, 190 insertions, 24 deletions
diff --git a/repo/devel/make.xibuild b/repo/devel/make.xibuild
index 4b0595d..bb4412f 100644
--- a/repo/devel/make.xibuild
+++ b/repo/devel/make.xibuild
@@ -1,6 +1,6 @@
#!/bin/sh
-MAKEDEPS=""
+MAKEDEPS="musl"
DEPS=""
PKG_VER=4.3
diff --git a/repo/meta/base.xibuild b/repo/meta/base.xibuild
index fd7d807..d62915a 100644
--- a/repo/meta/base.xibuild
+++ b/repo/meta/base.xibuild
@@ -1,5 +1,5 @@
#!/bin/sh
-DEPS="bash bzip2 coreutils findutils iana-etc file gawk gettext musl grep gzip iproute2 iputils xipkg pciutils procps-ng psmisc sed shadow sysvinit tar util-linux xz linux-headers sysconfigs "
+DEPS="bash bzip2 coreutils findutils iana-etc file gawk gettext musl grep gzip iproute2 iputils xipkg pciutils procps-ng psmisc sed shadow sysvinit tar util-linux xz linux-headers sysconfigs inetutils"
MAKEDEPS="grep python"
DESC="The base system to be installed"
diff --git a/repo/system/argp-standalone.xibuild b/repo/system/argp-standalone.xibuild
new file mode 100644
index 0000000..c393169
--- /dev/null
+++ b/repo/system/argp-standalone.xibuild
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+MAKEDEPS=""
+DEPS=""
+
+PKG_VER=
+SOURCE=https://github.com/ericonr/argp-standalone/archive/$PKG_VER.tar.gz
+
+DESC="Standalone implementation for the argp interface"
+
+build () {
+ CFLAGS=" -fPIC" ./configure \
+ --prefix=/usr \
+ --disable-static \
+ --sysconfdir=/etc \
+ --localstatedir=/var &&
+ make
+}
+
+package () {
+ cp -v libargp.a $PKG_DEST/usr/lib/
+ cp -v argp.h $PKG_DEST/usr/include/
+}
+
diff --git a/repo/system/gettext.xibuild b/repo/system/gettext.xibuild
index 501a14a..11b6754 100644
--- a/repo/system/gettext.xibuild
+++ b/repo/system/gettext.xibuild
@@ -1,22 +1,28 @@
#!/bin/sh
-MAKEDEPS="make "
+MAKEDEPS="make"
DEPS="acl sh"
-PKG_VER=0.21
-SOURCE=https://ftp.gnu.org/pub/gnu/gettext/gettext-$PKG_VER.tar.gz
-DESC="GNU internationalization library"
+PKG_VER=0.3.2
+SOURCE=https://ftp.barfooze.de/pub/sabotage/tarballs/gettext-tiny-$PKG_VER.tar.xz
+DESC="Lightweight replacement for tools used in the GNU gettext suite"
-build () {
- ./configure --prefix=/usr --disable-static --docdir=/usr/share/doc/gettext-$PKG_VER
- make
+ADDITIONAL="
+ https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/patches/gettext-tiny-adiele/line-length.patch
+ https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/patches/gettext-tiny-adiele/respect-cflags.patch
+ https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/patches/gettext-tiny-adiele/stop-doing-macro-crap.patch
+"
+
+prepare () {
+ for p in *.patch; do
+ patch -Np1 -i $p || true
+ done
}
-check () {
- make check
+build () {
+ LIBINTL=MUSL prefix=/usr make
}
package () {
- make DESTDIR=$PKG_DEST install
- chmod -v 0755 $PKG_DEST/usr/lib/preloadable_libintl.so
+ make LIBINTL=MUSL prefix=/usr DESTDIR=$PKG_DEST install
}
diff --git a/repo/system/musl-fts.xibuild b/repo/system/musl-fts.xibuild
new file mode 100644
index 0000000..daf4841
--- /dev/null
+++ b/repo/system/musl-fts.xibuild
@@ -0,0 +1,27 @@
+#!/bin/sh
+
+MAKEDEPS=""
+DEPS="musl"
+
+PKG_VER=1.2.7
+SOURCE=https://github.com/pullmoll/musl-fts/archive/v$PKG_DEST.tar.gz
+
+DESC="Libraries implementing the set of fts functions missing in musl libc"
+
+prepare () {
+ sed -i "/pkgconfig_DATA/i pkgconfigdir=/usr/lib/pkgconfig" Makefile.am
+ ./bootstrap.sh
+}
+
+build () {
+ CFLAGS=" -fPIC" \
+ ./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ --localstatedir=/var
+ make
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+}
diff --git a/repo/system/musl-legacy-compat.xibuild b/repo/system/musl-legacy-compat.xibuild
new file mode 100644
index 0000000..33d0e45
--- /dev/null
+++ b/repo/system/musl-legacy-compat.xibuild
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+MAKEDEPS=""
+DEPS="musl"
+
+HEADER_SOURCE="https://raw.githubusercontent.com/void-linux/void-packages/master/srcpkgs/musl-legacy-compat/files"
+ADDITIONAL="
+ $HEADER_SOURCE/cdefs.h
+ $HEADER_SOURCE/queue.h
+ $HEADER_SOURCE/tree.h
+"
+
+DESC="Legacy compatibility headers for musl"
+
+package () {
+ for h in cdefs queue tree
+ do
+ install -v -D -m644 $h.h $PKG_DEST/usr/include/sys
+ done
+}
+
diff --git a/repo/system/musl-obstack.xibuild b/repo/system/musl-obstack.xibuild
new file mode 100644
index 0000000..bbc014d
--- /dev/null
+++ b/repo/system/musl-obstack.xibuild
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+MAKEDEPS=""
+DEPS="musl"
+
+PKG_VER=1.1
+SOURCE=https://github.com/pullmoll/musl-obstack/archive/v$PKG_VER.tar.gz
+
+DESC="Obstack functions found in GNU libiberty"
+
+prepare () {
+ sed -i "/pkgconfig_DATA/i pkgconfigdir=/usr/lib/pkgconfig" Makefile.am
+ ./bootstrap.sh
+}
+
+build () {
+ CFLAGS=" -fPIC" \
+ ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
+ make
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+}
diff --git a/repo/system/musl.xibuild b/repo/system/musl.xibuild
index 921736d..d986ae7 100644
--- a/repo/system/musl.xibuild
+++ b/repo/system/musl.xibuild
@@ -32,9 +32,14 @@ build () {
}
package () {
- make DESTDIR=$PKG_DEST install
- ln -sv /lib/ld-musl-$ARCH.so.1 $PKG_DEST/bin/ldd
- ln -sv libc.so $PKG_DEST/usr/lib/libc.musl-x86_64.so.1
+ make DESTDIR=$PKG_DEST install &&
+
+ install -d $PKG_DEST/etc
+ install -d $PKG_DEST/bin
+ install -d $PKG_DEST/lib
+
+ ln -s /lib/ld-musl-x86_64.so.1 $PKG_DEST/bin/ldd
+ ln -s libc.so $PKG_DEST/usr/lib/libc.musl-x86_64.so.1
cat > $PKG_DEST/etc/ld-musl-x86_64.path << "EOF"
/lib
@@ -42,6 +47,6 @@ package () {
/usr/lib
EOF
- rm -v $PKG_DEST/usr/include/utmpx.h
+ rm $PKG_DEST/usr/include/utmpx.h
}
diff --git a/repo/system/ncurses.xibuild b/repo/system/ncurses.xibuild
index 5a1e4d0..a5e820b 100644
--- a/repo/system/ncurses.xibuild
+++ b/repo/system/ncurses.xibuild
@@ -12,7 +12,6 @@ build () {
./configure --prefix=/usr --mandir=/usr/share/man --with-shared --without-debug --without-normal --enable-pc-files --enable-widec
make
-
}
@@ -20,16 +19,16 @@ package () {
make DESTDIR=$PKG_DEST install
for lib in ncurses form panel menu ; do
- rm -vf $PKG_DEST/usr/lib/lib${lib}.so
+ rm -f $PKG_DEST/usr/lib/lib${lib}.so
echo "INPUT(-l${lib}w)" > $PKG_DEST/usr/lib/lib${lib}.so
- ln -sfv ${lib}w.pc $PKG_DEST/usr/lib/pkgconfig/${lib}.pc
+ ln -sf ${lib}w.pc $PKG_DEST/usr/lib/pkgconfig/${lib}.pc
done
- rm -vf $PKG_DEST/usr/lib/libcursesw.so
+ rm -f $PKG_DEST/usr/lib/libcursesw.so
echo "INPUT(-lncursesw)" > $PKG_DEST/usr/lib/libcursesw.so
- ln -sfv libncurses.so $PKG_DEST/usr/lib/libcurses.so
+ ln -sf libncurses.so $PKG_DEST/usr/lib/libcurses.so
# install docs
- mkdir -pv $PKG_DEST/usr/share/doc/ncurses-$PKG_VER
- cp -v -R doc/* $PKG_DEST/usr/share/doc/ncurses-$PKG_VER
+ mkdir -p $PKG_DEST/usr/share/doc/ncurses-$PKG_VER
+ cp -R doc/* $PKG_DEST/usr/share/doc/ncurses-$PKG_VER
}
diff --git a/repo/system/skalibs.xibuild b/repo/system/skalibs.xibuild
new file mode 100644
index 0000000..0833b6c
--- /dev/null
+++ b/repo/system/skalibs.xibuild
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+MAKEDEPS=""
+DEPS="musl"
+
+PKG_VER=2.11.1.0
+SOURCE=https://skarnet.org/software/skalibs/skalibs-$PKG_VER.tar.gz
+
+DESC="General purpose libraries for skarnet.org software"
+
+build () {
+ ./configure \
+ --enable-shared \
+ --enable-static \
+ --libdir=/usr/lib
+ make
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+}
+
diff --git a/repo/system/utmps.xibuild b/repo/system/utmps.xibuild
new file mode 100644
index 0000000..28b358f
--- /dev/null
+++ b/repo/system/utmps.xibuild
@@ -0,0 +1,38 @@
+#!/bin/sh
+
+MAKEDEPS=""
+DEPS="skalib"
+
+PKG_VER=0.1.1.0
+SOURCE=https://skarnet.org/software/utmps/utmps-0.1.1.0.tar.gz
+
+DESC="Library implementing utmpx.h family of functions"
+
+prepare () {
+ sed -i -e "s/@@VERSION@@/0.1.1.0/g" -- /tmp/*.pc
+}
+
+build () {
+ ./configure \
+ --enable-shared \
+ --libdir=/usr/lib \
+ --with-dynlib=/lib \
+ --libexecdir="/lib/utmps" \
+ --with=dynlib=/lib
+ make
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+ ln -sv utmps/utmpx.h $PKG_DEST/usr/include/utmpx.h
+
+ cat > $PKG_DEST/usr/lib/pkgconfig/utmps.pc << EOF
+Name: utmps
+Description: A secure implementation of the utmp mechanism.
+URL: https://skarnet.org/software/utmps/
+Version: @@VERSION@@
+Requires.private: skalibs
+Libs: -lutmps
+Cflags: -I/usr/include/utmps
+EOF
+}