summaryrefslogtreecommitdiff
path: root/repo/system
diff options
context:
space:
mode:
Diffstat (limited to 'repo/system')
-rw-r--r--repo/system/dbus-glib/dbus-glib.xibuild24
-rw-r--r--repo/system/fftw/cycle.h.patch54
-rw-r--r--repo/system/fftw/fftw.xibuild54
-rw-r--r--repo/system/gettext/fix-xgettext-version-string.patch11
-rw-r--r--repo/system/gettext/flip-macro-logic.patch20
-rw-r--r--repo/system/gettext/gettext.xibuild11
-rw-r--r--repo/system/gettext/line-length.patch15
-rw-r--r--repo/system/gettext/respect-cflags.patch11
-rw-r--r--repo/system/glib-networking/glib-networking.xibuild24
-rw-r--r--repo/system/iniparser/iniparser.xibuild24
-rw-r--r--repo/system/iniparser/rpath.patch10
-rw-r--r--repo/system/libproxy/libproxy.xibuild27
-rw-r--r--repo/system/libucontext/libucontext.xibuild18
-rw-r--r--repo/system/nspr/nspr.xibuild2
-rw-r--r--repo/system/nss/nss.xibuild2
-rw-r--r--repo/system/ruby/dont-install-bundled-gems.patch20
-rw-r--r--repo/system/ruby/ruby.xibuild48
-rw-r--r--repo/system/ruby/test_insns-lower-recursion-depth.patch47
18 files changed, 414 insertions, 8 deletions
diff --git a/repo/system/dbus-glib/dbus-glib.xibuild b/repo/system/dbus-glib/dbus-glib.xibuild
new file mode 100644
index 0000000..d831891
--- /dev/null
+++ b/repo/system/dbus-glib/dbus-glib.xibuild
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+NAME="dbus-glib"
+DESC="GLib bindings for DBUS"
+
+MAKEDEPS="make "
+DEPS="dbus glib expat musl "
+
+PKG_VER=0.112
+SOURCE="https://dbus.freedesktop.org/releases/dbus-glib/dbus-glib-$PKG_VER.tar.gz"
+
+build () {
+ ./configure \
+ --prefix=/usr \
+ --bindir=/usr/bin \
+ --sysconfdir=/etc \
+ --enable-static=no \
+ --enable-bash-completion=no
+ make
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+}
diff --git a/repo/system/fftw/cycle.h.patch b/repo/system/fftw/cycle.h.patch
new file mode 100644
index 0000000..7e55d3e
--- /dev/null
+++ b/repo/system/fftw/cycle.h.patch
@@ -0,0 +1,54 @@
+diff --git a/kernel/cycle.h b/kernel/cycle.h
+index a0e86f3..3ff4c0e 100644
+--- a/kernel/cycle.h
++++ b/kernel/cycle.h
+@@ -368,22 +368,6 @@ INLINE_ELAPSED(inline)
+ #define HAVE_TICK_COUNTER
+ #endif
+
+-/*----------------------------------------------------------------*/
+-/* S390, courtesy of James Treacy */
+-#if defined(__GNUC__) && defined(__s390__) && !defined(HAVE_TICK_COUNTER)
+-typedef unsigned long long ticks;
+-
+-static __inline__ ticks getticks(void)
+-{
+- ticks cycles;
+- __asm__("stck 0(%0)" : : "a" (&(cycles)) : "memory", "cc");
+- return cycles;
+-}
+-
+-INLINE_ELAPSED(__inline__)
+-
+-#define HAVE_TICK_COUNTER
+-#endif
+ /*----------------------------------------------------------------*/
+ #if defined(__GNUC__) && defined(__alpha__) && !defined(HAVE_TICK_COUNTER)
+ /*
+@@ -436,26 +420,6 @@ INLINE_ELAPSED(__inline)
+
+ #define HAVE_TICK_COUNTER
+ #endif
+-/*----------------------------------------------------------------*/
+-/* SGI/Irix */
+-#if defined(HAVE_CLOCK_GETTIME) && defined(CLOCK_SGI_CYCLE) && !defined(HAVE_TICK_COUNTER) && !defined(__ANDROID__)
+-typedef struct timespec ticks;
+-
+-static inline ticks getticks(void)
+-{
+- struct timespec t;
+- clock_gettime(CLOCK_SGI_CYCLE, &t);
+- return t;
+-}
+-
+-static inline double elapsed(ticks t1, ticks t0)
+-{
+- return ((double)t1.tv_sec - (double)t0.tv_sec) * 1.0E9 +
+- ((double)t1.tv_nsec - (double)t0.tv_nsec);
+-}
+-#define HAVE_TICK_COUNTER
+-#endif
+-
+ /*----------------------------------------------------------------*/
+ /* Cray UNICOS _rtc() intrinsic function */
+ #if defined(HAVE__RTC) && !defined(HAVE_TICK_COUNTER)
diff --git a/repo/system/fftw/fftw.xibuild b/repo/system/fftw/fftw.xibuild
new file mode 100644
index 0000000..41dd124
--- /dev/null
+++ b/repo/system/fftw/fftw.xibuild
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+NAME="fftw"
+DESC="Discrete Fourier transform (DFT) library"
+
+MAKEDEPS="make tar"
+DEPS="musl "
+
+PKG_VER=3.3.10
+SOURCE="http://www.fftw.org/fftw-$PKG_VER.tar.gz"
+ADDITIONAL="cycle.h.patch "
+
+precisions="single double long-double"
+
+prepare () {
+ for i in $precisions; do
+ mkdir $i
+ tar -xf fftw-$PKG_VER.tar.gz -C $i
+ done
+}
+
+build () {
+ local i; for i in $precisions; do
+ case "$i" in
+ single) cf="--enable-single";;
+ double) cf="";;
+ long-double) cf="--enable-long-double";;
+ esac
+
+ case "$i" in
+ single | double)
+ cf="$cf --enable-sse2 --enable-avx";;
+ esac
+
+ printf "Building for $i precision ($cf)"
+ cd $BUILD_ROOT/$i/fftw-$PKG_VER
+ ./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+ --enable-shared \
+ --enable-threads \
+ $cf
+ make
+ done
+}
+
+package () {
+ for i in $precisions; do
+ cd $BUILD_ROOT/$i/fftw-$PKG_VER
+ make DESTDIR=$PKG_DEST install
+ done
+}
diff --git a/repo/system/gettext/fix-xgettext-version-string.patch b/repo/system/gettext/fix-xgettext-version-string.patch
new file mode 100644
index 0000000..de35749
--- /dev/null
+++ b/repo/system/gettext/fix-xgettext-version-string.patch
@@ -0,0 +1,11 @@
+--- a/src/xgettext.sh 2020-04-06 11:43:29.000000000 +0100
++++ b/src/xgettext.sh 2020-04-06 11:43:29.000000000 +0100
+@@ -16,7 +16,7 @@
+ }
+
+ show_version() {
+- printf "%s\n", "xgettext (GNU gettext-tools compatible) 99.9999.9999\n"
++ printf "%s\n\n" "xgettext (GNU gettext-tools) 0.19.8.1"
+ exit 0
+ }
+
diff --git a/repo/system/gettext/flip-macro-logic.patch b/repo/system/gettext/flip-macro-logic.patch
new file mode 100644
index 0000000..277bc7a
--- /dev/null
+++ b/repo/system/gettext/flip-macro-logic.patch
@@ -0,0 +1,20 @@
+--- gettext-tiny-0.2.0/include/libintl.h.old 2017-08-02 06:14:20.000000000 -0500
++++ gettext-tiny-0.2.0/include/libintl.h 2018-06-15 02:31:14.241446687 -0500
+@@ -34,14 +34,14 @@
+ #undef gettext_noop
+ #define gettext_noop(X) X
+
+-#ifndef LIBINTL_NO_MACROS
++#ifdef LIBINTL_MACROS
+ /* if these macros are defined, configure checks will detect libintl as
+ * built into the libc because test programs will work without -lintl.
+ * for example:
+ * checking for ngettext in libc ... yes
+ * the consequence is that -lintl will not be added to the LDFLAGS.
+- * so if for some reason you want that libintl.a gets linked,
+- * add -DLIBINTL_NO_MACROS=1 to your CPPFLAGS. */
++ * so if for some reason you dont want that libintl.a gets linked,
++ * add -DLIBINTL_MACROS=1 to your CPPFLAGS. */
+
+ #define gettext(X) ((char*) (X))
+ #define dgettext(dom, X) ((void)(dom), (char*) (X))
diff --git a/repo/system/gettext/gettext.xibuild b/repo/system/gettext/gettext.xibuild
index 11b6754..8da13a5 100644
--- a/repo/system/gettext/gettext.xibuild
+++ b/repo/system/gettext/gettext.xibuild
@@ -8,15 +8,14 @@ SOURCE=https://ftp.barfooze.de/pub/sabotage/tarballs/gettext-tiny-$PKG_VER.tar.x
DESC="Lightweight replacement for tools used in the GNU gettext suite"
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
+ line-length.patch
+ respect-cflags.patch
+ flip-macro-logic.patch
+ fix-xgettext-version-string.patch
"
prepare () {
- for p in *.patch; do
- patch -Np1 -i $p || true
- done
+ apply_patches
}
build () {
diff --git a/repo/system/gettext/line-length.patch b/repo/system/gettext/line-length.patch
new file mode 100644
index 0000000..0ba9781
--- /dev/null
+++ b/repo/system/gettext/line-length.patch
@@ -0,0 +1,15 @@
+https://github.com/sabotage-linux/gettext-tiny/issues/50
+
+We're losing the battle of the bulge; someone really should make this use malloc.
+
+--- gettext-tiny-0.3.1_git20191130/src/msgfmt.c.old 2020-01-14 08:03:11.000000000 +0000
++++ gettext-tiny-0.3.1_git20191130/src/msgfmt.c 2020-01-21 18:58:28.257709860 +0000
+@@ -160,7 +160,7 @@
+
+ int process(FILE *in, FILE *out, bool strict) {
+ struct mo_hdr mohdr = def_hdr;
+- char line[8192]; char *lp;
++ char line[12288]; char *lp;
+ size_t off, i;
+ enum po_error t;
+ char convbuf[32768];
diff --git a/repo/system/gettext/respect-cflags.patch b/repo/system/gettext/respect-cflags.patch
new file mode 100644
index 0000000..dd1cf3f
--- /dev/null
+++ b/repo/system/gettext/respect-cflags.patch
@@ -0,0 +1,11 @@
+--- gettext-tiny-0.2.0/Makefile.old 2017-08-02 06:14:20.000000000 -0500
++++ gettext-tiny-0.2.0/Makefile 2018-06-16 21:21:57.148735892 -0500
+@@ -32,7 +32,7 @@
+ ALL_M4S=$(sort $(wildcard m4/*.m4))
+ ALL_DATA=$(sort $(wildcard data/*))
+
+-CFLAGS=-O0 -fPIC
++CFLAGS ?= -O0 -fPIC
+
+ AR ?= $(CROSS_COMPILE)ar
+ RANLIB ?= $(CROSS_COMPILE)ranlib
diff --git a/repo/system/glib-networking/glib-networking.xibuild b/repo/system/glib-networking/glib-networking.xibuild
new file mode 100644
index 0000000..88e7244
--- /dev/null
+++ b/repo/system/glib-networking/glib-networking.xibuild
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+NAME="glib-networking"
+DESC="Networking support for GLib"
+
+MAKEDEPS="meson ninja "
+DEPS="glib cacerts gnutls gsettings-desktop-schemas intltool musl libproxy"
+
+PKG_VER=2.72.0
+SOURCE="https://download.gnome.org/sources/glib-networking/${PKG_VER%.*}/glib-networking-$PKG_VER.tar.xz"
+
+build () {
+ mkdir build &&
+ cd build &&
+ meson --prefix=/usr \
+ -Dopenssl=disabled \
+ -Dgnutls=enabled \
+ .. &&
+ ninja
+}
+
+package () {
+ DESTDIR=$PKG_DEST ninja install
+}
diff --git a/repo/system/iniparser/iniparser.xibuild b/repo/system/iniparser/iniparser.xibuild
new file mode 100644
index 0000000..7655cf5
--- /dev/null
+++ b/repo/system/iniparser/iniparser.xibuild
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+NAME="iniparser"
+DESC="C library for parsing INI-style files"
+
+MAKEDEPS="make "
+DEPS="musl "
+
+PKG_VER=4.1
+SOURCE="https://github.com/ndevilla/iniparser/archive/v$PKG_VER.tar.gz"
+ADDITIONAL="rpath.patch "
+
+build () {
+ make
+}
+
+package () {
+ install -d "$PKG_DEST"/usr/lib "$PKG_DEST"/usr/include
+ install -m 644 src/dictionary.h "$PKG_DEST"/usr/include/dictionary.h
+ install -m 644 src/iniparser.h "$PKG_DEST"/usr/include/iniparser.h
+ install -m 755 libiniparser.so.1 "$PKG_DEST"/usr/lib/libiniparser.so.1
+ ln -s libiniparser.so.1 "$PKG_DEST"/usr/lib/libiniparser.so
+
+}
diff --git a/repo/system/iniparser/rpath.patch b/repo/system/iniparser/rpath.patch
new file mode 100644
index 0000000..ef7097f
--- /dev/null
+++ b/repo/system/iniparser/rpath.patch
@@ -0,0 +1,10 @@
+--- a/Makefile
++++ b/Makefile
+@@ -21,7 +21,6 @@
+
+ SHLD = ${CC} ${CFLAGS}
+ LDSHFLAGS = -shared -Wl,-Bsymbolic
+-LDFLAGS += -Wl,-rpath -Wl,/usr/lib -Wl,-rpath,/usr/lib
+
+ # .so.0 is for version 3.x, .so.1 is 4.x
+ SO_TARGET ?= libiniparser.so.1
diff --git a/repo/system/libproxy/libproxy.xibuild b/repo/system/libproxy/libproxy.xibuild
new file mode 100644
index 0000000..a844754
--- /dev/null
+++ b/repo/system/libproxy/libproxy.xibuild
@@ -0,0 +1,27 @@
+#!/bin/sh
+
+NAME="libproxy"
+DESC="Library handling all the details of proxy configuration"
+
+MAKEDEPS="cmake "
+DEPS="musl libgcc libstdc++"
+
+PKG_VER=0.4.17
+SOURCE="https://github.com/libproxy/libproxy/archive/$PKG_VER.tar.gz"
+
+build () {
+ cmake -B build \
+ -DCMAKE_BUILD_TYPE=None \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DLIBEXEC_INSTALL_DIR=lib \
+ -DMODULE_INSTALL_DIR=/usr/lib/libproxy/$PKG_VER/modules \
+ -DWITH_PERL=OFF \
+ -DWITH_PYTHON3=ON \
+ -DPYTHON3_EXECUTABLE=/usr/bin/python3
+
+ cmake --build build
+}
+
+package () {
+ DESTDIR="$PKG_DEST" cmake --install build
+}
diff --git a/repo/system/libucontext/libucontext.xibuild b/repo/system/libucontext/libucontext.xibuild
new file mode 100644
index 0000000..801490b
--- /dev/null
+++ b/repo/system/libucontext/libucontext.xibuild
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+NAME="libucontext"
+DESC="ucontext function implementations"
+
+MAKEDEPS="make "
+DEPS="musl "
+
+PKG_VER=1.2
+SOURCE="https://distfiles.dereferenced.org/libucontext/libucontext-$PKG_VER.tar.xz"
+
+build () {
+ make PREFIX=/usr
+}
+
+package () {
+ make PREFIX=/usr DESTDIR=$PKG_DEST install
+}
diff --git a/repo/system/nspr/nspr.xibuild b/repo/system/nspr/nspr.xibuild
index 0b5fdc5..7763d74 100644
--- a/repo/system/nspr/nspr.xibuild
+++ b/repo/system/nspr/nspr.xibuild
@@ -3,7 +3,7 @@
MAKEDEPS="make "
DEPS="musl"
-PKG_VER=4.33
+PKG_VER=4.34
SOURCE=https://archive.mozilla.org/pub/nspr/releases/v$PKG_VER/src/nspr-$PKG_VER.tar.gz
DESC="Netscape Portable Runtime"
diff --git a/repo/system/nss/nss.xibuild b/repo/system/nss/nss.xibuild
index 7318173..fd19569 100644
--- a/repo/system/nss/nss.xibuild
+++ b/repo/system/nss/nss.xibuild
@@ -3,7 +3,7 @@
MAKEDEPS="make perl python patch"
DEPS="nspr libp11-kit sh zlib sqlite3"
-PKG_VER=3.74
+PKG_VER=3.76
SOURCE=https://archive.mozilla.org/pub/security/nss/releases/NSS_$(echo $PKG_VER | sed 's/\./_/g')_RTM/src/nss-$PKG_VER.tar.gz
diff --git a/repo/system/ruby/dont-install-bundled-gems.patch b/repo/system/ruby/dont-install-bundled-gems.patch
new file mode 100644
index 0000000..2a913b9
--- /dev/null
+++ b/repo/system/ruby/dont-install-bundled-gems.patch
@@ -0,0 +1,20 @@
+Don't install bundled gems - we package them separately.
+
+--- a/tool/rbinstall.rb
++++ b/tool/rbinstall.rb
+@@ -1003,6 +1003,7 @@
+ end
+ end
+
++=begin XXX-Patched
+ install?(:ext, :comm, :gem, :'bundled-gems') do
+ if CONFIG['CROSS_COMPILING'] == 'yes'
+ # The following hacky steps set "$ruby = BASERUBY" in tool/fake.rb
+@@ -1104,6 +1105,7 @@
+ puts "skip installing bundled gems because of lacking zlib"
+ end
+ end
++=end
+
+ parse_args()
+
diff --git a/repo/system/ruby/ruby.xibuild b/repo/system/ruby/ruby.xibuild
new file mode 100644
index 0000000..3cc7f7b
--- /dev/null
+++ b/repo/system/ruby/ruby.xibuild
@@ -0,0 +1,48 @@
+#!/bin/sh
+
+NAME="ruby"
+DESC="An object-oriented language for quick and easy programming"
+
+MAKEDEPS="make "
+DEPS="sbase cacerts gmp libucontext musl zlib "
+
+PKG_VER=3.1.2
+SOURCE="https://cache.ruby-lang.org/pub/ruby/${PKG_VER%.*}/ruby-$PKG_VER.tar.gz"
+ADDITIONAL="dont-install-bundled-gems.patch dont-install-bundled-gems.patch test_insns-lower-recursion-depth.patch "
+
+prepare () {
+ apply_patches
+}
+
+build () {
+ export CFLAGS="-O2 -fno-omit-frame-pointer -fno-strict-aliasing"
+ export CPPFLAGS="-O2 -fno-omit-frame-pointer -fno-strict-aliasing"
+
+ # Needed for coroutine stuff
+ export LIBS="-lucontext"
+
+ # ruby saves path to install. we want use $PATH
+ export INSTALL=install
+
+ # the configure script does not detect isnan/isinf as macros
+ export ac_cv_func_isnan=yes
+ export ac_cv_func_isinf=yes
+
+
+ ./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+ --with-sitedir=/usr/local/lib/site_ruby \
+ --with-search-path="/usr/lib/site_ruby/\$(ruby_ver)/x86_64-linux" \
+ --enable-pthread \
+ --disable-rpath \
+ --enable-shared \
+ --with-mantype=man
+ make
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+}
diff --git a/repo/system/ruby/test_insns-lower-recursion-depth.patch b/repo/system/ruby/test_insns-lower-recursion-depth.patch
new file mode 100644
index 0000000..0069720
--- /dev/null
+++ b/repo/system/ruby/test_insns-lower-recursion-depth.patch
@@ -0,0 +1,47 @@
+The patched test is a recursion function. We have lower stack size,
+so we hit SystemStackError sooner than on other platforms.
+
+ #361 test_insns.rb:389:in `block in <top (required)>':
+ # recursive once
+ def once n
+ return %r/#{
+ if n == 0
+ true
+ else
+ once(n-1) # here
+ end
+ }/ox
+ end
+ x = once(128); x = once(7); x = once(16);
+ x =~ "true" && $~
+ #=> "" (expected "true") once
+ Stderr output is not empty
+ bootstraptest.tmp.rb:3:in `once': stack level too deep (SystemStackError)
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ ... 125 levels...
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:11:in `<main>'
+ Test_insns.rb FAIL 1/187
+ FAIL 1/1197 tests failed
+ Make: *** [uncommon.mk:666: yes-btest-ruby] Error 1
+
+--- a/bootstraptest/test_insns.rb
++++ b/bootstraptest/test_insns.rb
+@@ -274,7 +274,7 @@
+ end
+ }/ox
+ end
+- x = once(128); x = once(7); x = once(16);
++ x = once(32); x = once(7); x = once(16);
+ x =~ "true" && $~
+ },
+ [ 'once', <<-'},', ], # {