lots of moving

This commit is contained in:
Ella-0 2021-08-03 22:17:36 +00:00
parent e46f5d532a
commit 31d9629111
46 changed files with 0 additions and 0 deletions

28
extra/alsa-lib/build.sh Normal file
View file

@ -0,0 +1,28 @@
pkgname=alsa-lib
pkgver=1.2.5.1
fetch() {
curl -L "http://www.alsa-project.org/files/pub/lib/alsa-lib-$pkgver.tar.bz2" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--build=$TRIPLE \
--host=$TRIPLE
make
}
package() {
cd $pkgname-$pkgver
make install DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

22
extra/bat/build.sh Normal file
View file

@ -0,0 +1,22 @@
pkgname=bat
pkgver=0.17.1
fetch() {
curl -L "https://github.com/sharkdp/bat/archive/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
}
build() {
cd $pkgname-$pkgver
cargo build --release --locked --all-features
}
package() {
cd $pkgname-$pkgver
install -Dm 755 target/release/${pkgname} "${pkgdir}/usr/bin/"
}
license() {
cd $pkgname-$pkgver
cat LICENSE-MIT
}

26
extra/bin86/build.sh Normal file
View file

@ -0,0 +1,26 @@
pkgname=bin86
pkgver=0.16.21
fetch() {
curl "https://sources.archlinux.org/other/community/dev86/$pkgname-$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
cd $pkgname-$pkgver
curl -L "https://github.com/ataraxialinux/ataraxia/raw/master/stuff/bin86/bin86-0.16.17-x86_64-1.patch" | patch -p1
}
build() {
cd $pkgname-$pkgver
gmake PREFIX=/usr
}
package() {
cd $pkgname-$pkgver
install -d $pkgdir/usr/bin
install -d $pkgdir/usr/share/man/man1
gmake PREFIX=$pkgdir/usr MANDIR=$pkgdir/usr/share/man/man1 install
}
license() {
cd $pkgname-$pkgver
cat README
}

30
extra/brotli/build.sh Normal file
View file

@ -0,0 +1,30 @@
pkgname=brotli
pkgver=1.0.9
fetch() {
curl -L "https://github.com/google/brotli/archive/refs/tags/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mkdir $pkgname-$pkgver/build
}
build() {
cd $pkgname-$pkgver
cd build
cmake -G Ninja ../ \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib
samu
}
package() {
cd $pkgname-$pkgver
cd build
DESTDIR=$pkgdir samu install
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

30
extra/ccache/build.sh Normal file
View file

@ -0,0 +1,30 @@
pkgname=ccache
pkgver=4.2.1
fetch() {
curl -L "https://github.com/ccache/ccache/releases/download/v4.2.1/ccache-4.2.1.tar.xz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mkdir $pkgname-$pkgver/build
}
build() {
cd $pkgname-$pkgver
cd build
cmake -G Ninja ../ \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib
samu
}
package() {
cd $pkgname-$pkgver
cd build
DESTDIR=$pkgdir samu install
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

35
extra/distcc/build.sh Normal file
View file

@ -0,0 +1,35 @@
pkgname=distcc
pkgver=3.3.5
bad="gmake"
fetch() {
curl -L "https://github.com/distcc/distcc/releases/download/v$pkgver/distcc-$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--build=x86_64-unknown-linux-musl \
--host=x86_64-unknown-linux-musl \
--without-libiberty
gmake
}
package() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir
install -d $pkgdir/usr/lib/distcc
ln -sr $pkgdir/usr/bin/distcc $pkgdir/usr/lib/distcc/cc
ln -sr $pkgdir/usr/bin/distcc $pkgdir/usr/lib/distcc/c89
ln -sr $pkgdir/usr/bin/distcc $pkgdir/usr/lib/distcc/c99
ln -sr $pkgdir/usr/bin/distcc $pkgdir/usr/lib/distcc/c++
}
license() {
cd $pkgname-$pkgver
cat COPYING
}

40
extra/dropbear/build.sh Normal file
View file

@ -0,0 +1,40 @@
pkgname=dropbear
pkgver=2020.81
bad=gmake
ext=doc
fetch() {
curl "https://matt.ucc.asn.au/dropbear/releases/dropbear-$pkgver.tar.bz2" -o $pkgname-$pkgver.tar.bz2
tar -xf $pkgname-$pkgver.tar.bz2
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--build=x86_64-unknown-linux-musl \
--host=x86_64-unknown-linux-musl
gmake PROGRAMS='dropbear dbclient dropbearkey dropbearconvert scp'
}
package() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir PROGRAMS='dropbear dbclient dropbearkey dropbearconvert scp'
ln -sr $pkgdir/usr/sbin/dropbear $pkgdir/usr/sbin/sshd
ln -sr $pkgdir/usr/bin/dbclient $pkgdir/usr/bin/ssh
rm -r $pkgdir/usr/share
}
package_doc() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir PROGRAMS='dropbear dbclient dropbearkey dropbearconvert scp'
rm -r $pkgdir/usr/bin
rm -r $pkgdir/usr/sbin
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

32
extra/fish/build.sh Normal file
View file

@ -0,0 +1,32 @@
pkgver=3.1.2
pkgname=fish
pkgrel=1
fetch() {
curl -L "https://github.com/fish-shell/fish-shell/releases/download/3.1.2/fish-3.1.2.tar.gz" -o $pkgname-$pkgver.tar.gz
tar -xf $pkgname-$pkgver.tar.gz
cd $pkgname-$pkgver
patch -p1 < ../../output_tputs_cast.patch
}
build() {
cd $pkgname-$pkgver
mkdir build
cd build
cmake -G Ninja .. \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_EXE_LINKER_FLAGS=-lterminfo \
-DCMAKE_INSTALL_PREFIX='/usr'
samu
}
package() {
cd $pkgname-$pkgver
cd build
DESTDIR="$pkgdir/" samu install
}
license() {
cd $pkgname-$pkgver
cat COPYING
}

View file

@ -0,0 +1,8 @@
--- git_version_gen.sh.1
+++ git_version_gen.sh
@@ -1,4 +1,4 @@
-#!/usr/bin/env sh
+#!/bin/sh
# Originally from the git sources (GIT-VERSION-GEN)
# Presumably (C) Junio C Hamano <junkio@cox.net>
# Reused under GPL v2.0

View file

@ -0,0 +1,11 @@
--- a/src/output.cpp
+++ b/src/output.cpp
@@ -364,7 +364,7 @@
scoped_push<outputter_t *> push(&s_tputs_receiver, this);
// On some systems, tputs takes a char*, on others a const char*.
// Like tparm, we just cast it to unconst, that should work everywhere.
- return tputs(const_cast<char *>(str), affcnt, tputs_writer);
+ return tputs(const_cast<char *>(str), affcnt, (int (*)(int)) tputs_writer);
}
/// Write a wide character to the outputter. This should only be used when writing characters from

28
extra/flex/build.sh Normal file
View file

@ -0,0 +1,28 @@
pkgname=flex
pkgver=2.6.4
fetch() {
curl -L "https://github.com/westes/flex/releases/download/v2.6.4/flex-$pkgver.tar.gz" -o $pkgname-$pkgver.tar.gz
tar -xf $pkgname-$pkgver.tar.gz
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--build=$TRIPLE \
--host=$TRIPLE
make
}
package() {
cd $pkgname-$pkgver
make install DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

23
extra/glibr/build.sh Normal file
View file

@ -0,0 +1,23 @@
pkgname=glibr
pkgver=main
fetch() {
curl -L "https://github.com/iglunix/glibr/archive/main.tar.gz" -o $pkgname-$pkgver.tar.gz
tar -xf $pkgname-$pkgver.tar.gz
}
build() {
cd $pkgname-$pkgver
make
}
package() {
cd $pkgname-$pkgver
make install PREFIX=/usr DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

22
extra/glow/build.sh Normal file
View file

@ -0,0 +1,22 @@
pkgname=glow
pkgver=1.3.0
fetch() {
curl -L "https://github.com/charmbracelet/glow/archive/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
}
build() {
cd $pkgname-$pkgver
go build -o build/
}
package() {
cd $pkgname-$pkgver
install -Dm755 build/$pkgname $pkgdir/usr/bin/$pkgname
}
license() {
cd $pkgname-$pkgver
cat LICENSE
}

30
extra/librespot/build.sh Normal file
View file

@ -0,0 +1,30 @@
pkgname=librespot
pkgver=0.2.0
_clear_vendor_checksums() {
sed -i 's/\("files":{\)[^}]*/\1/' vendor/$1/.cargo-checksum.json
}
fetch() {
curl -L "https://github.com/librespot-org/librespot/archive/refs/tags/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
cd $pkgname-$pkgver
mkdir -p .cargo
cargo vendor > .cargo/config
}
build() {
cd $pkgname-$pkgver
cargo build --release --locked --no-default-features --features alsa-backend
}
package() {
cd $pkgname-$pkgver
install -Dm755 target/release/$pkgname $pkgdir/usr/bin/$pkgname
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

30
extra/libxml2/build.sh Normal file
View file

@ -0,0 +1,30 @@
pkgver=2.9.10
pkgname=libxml2
bad=""
ext="dev"
fetch() {
curl "ftp://xmlsoft.org/libxml2/libxml2-2.9.10.tar.gz" -o $pkgname-$pkgver.tar.gz
tar -xf $pkgname-$pkgver.tar.gz
}
build() {
cd $pkgname-$pkgver
./configure --prefix=/usr --without-python
gmake
}
package() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir
}
package_dev() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat Copyright
}

31
extra/lynx/build.sh Normal file
View file

@ -0,0 +1,31 @@
pkgname=lynx
pkgver=2.8.9
fetch() {
curl "https://invisible-mirror.net/archives/lynx/tarballs/lynx2.8.9rel.1.tar.bz2" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mv lynx2.8.9rel.1 $pkgname-$pkgver
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--with-ssl=/usr \
--build=x86_64-unknown-linux-musl \
--host=x86_64-unknown-linux-musl
gmake
}
package() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

27
extra/mold/build.sh Normal file
View file

@ -0,0 +1,27 @@
pkgname=mold
pkgver=main
deps="musl:libexecinfo"
fetch() {
curl -L "https://github.com/rui314/mold/archive/refs/heads/main.tar.gz" -o $pkgname-$pkgver.tar.gz
tar -xf $pkgname-$pkgver.tar.gz
cd $pkgname-$pkgver
patch -p1 < ../../musl.patch
}
build() {
cd $pkgname-$pkgver
gmake
}
package() {
cd $pkgname-$pkgver
gmake install DESTDIR=$pkgdir
ln -sr $pkgdir/usr/bin/mold $pkgdir/usr/bin/ld.mold
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

95
extra/mold/musl.patch Normal file
View file

@ -0,0 +1,95 @@
diff --git a/Makefile b/Makefile
index 1b36943..c6e0407 100644
--- a/Makefile
+++ b/Makefile
@@ -8,7 +8,7 @@ CPPFLAGS = -g -Imimalloc/include -pthread -std=c++20 \
-DGIT_HASH=\"$(GIT_HASH)\" \
$(EXTRA_CPPFLAGS)
LDFLAGS += $(EXTRA_LDFLAGS) -rdynamic
-LIBS = -Wl,-as-needed -lcrypto -pthread -lz -lxxhash -ldl -lm
+LIBS = -Wl,-as-needed -lcrypto -pthread -lz -lxxhash -lexecinfo -ldl -lm
OBJS = main.o object_file.o input_sections.o output_chunks.o \
mapfile.o perf.o linker_script.o archive_file.o output_file.o \
subprocess.o gc_sections.o icf.o symbols.o cmdline.o filepath.o \
diff --git a/mold.h b/mold.h
index 550545c..8bab9b9 100644
--- a/mold.h
+++ b/mold.h
@@ -27,6 +27,7 @@
#include <tbb/task_group.h>
#include <unistd.h>
#include <unordered_set>
+#include <unordered_map>
#include <vector>
#include <xxh3.h>
@@ -41,6 +42,9 @@ typedef int32_t i32;
typedef int64_t i64;
static constexpr i32 SECTOR_SIZE = 512;
+#ifdef PAGE_SIZE
+#undef PAGE_SIZE
+#endif
static constexpr i32 PAGE_SIZE = 4096;
static constexpr i32 SHA256_SIZE = 32;
@@ -2198,7 +2202,7 @@ InputFile<E>::get_string(Context<E> &ctx, const ElfShdr<E> &shdr) {
u8 *end = begin + shdr.sh_size;
if (mb->data(ctx) + mb->size() < end)
Fatal(ctx) << *this << ": shdr corrupted";
- return {(char *)begin, (char *)end};
+ return {(char *)begin, (size_t)(end-begin)};
}
template <typename E>
diff --git a/oneTBB/include/oneapi/tbb/detail/_config.h b/oneTBB/include/oneapi/tbb/detail/_config.h
index 27a3dd7..bb422b0 100644
--- a/oneTBB/include/oneapi/tbb/detail/_config.h
+++ b/oneTBB/include/oneapi/tbb/detail/_config.h
@@ -257,7 +257,7 @@
#define __TBB_CPP20_COMPARISONS_PRESENT __TBB_CPP20_PRESENT
#endif
-#define __TBB_RESUMABLE_TASKS (!__TBB_WIN8UI_SUPPORT && !__ANDROID__)
+#define __TBB_RESUMABLE_TASKS (!__TBB_WIN8UI_SUPPORT && __GLIBC__)
/* This macro marks incomplete code or comments describing ideas which are considered for the future.
* See also for plain comment with TODO and FIXME marks for small improvement opportunities.
diff --git a/oneTBB/src/tbbmalloc_proxy/proxy.cpp b/oneTBB/src/tbbmalloc_proxy/proxy.cpp
index b286e51..8057708 100644
--- a/oneTBB/src/tbbmalloc_proxy/proxy.cpp
+++ b/oneTBB/src/tbbmalloc_proxy/proxy.cpp
@@ -24,7 +24,8 @@
// of aligned_alloc as required by new C++ standard, this makes it hard to
// redefine aligned_alloc here. However, running on systems with new libc
// version, it still needs it to be redefined, thus tricking system headers
-#if defined(__GLIBC_PREREQ) && !__GLIBC_PREREQ(2, 16) && _GLIBCXX_HAVE_ALIGNED_ALLOC
+#if defined(__GLIBC_PREREQ)
+#if !__GLIBC_PREREQ(2, 16) && _GLIBCXX_HAVE_ALIGNED_ALLOC
// tell <cstdlib> that there is no aligned_alloc
#undef _GLIBCXX_HAVE_ALIGNED_ALLOC
// trick <stdlib.h> to define another symbol instead
@@ -33,6 +34,7 @@
#include <cstdlib>
#undef aligned_alloc
#endif // defined(__GLIBC_PREREQ)&&!__GLIBC_PREREQ(2, 16)&&_GLIBCXX_HAVE_ALIGNED_ALLOC
+#endif // defined(__GLIBC_PREREQ)
#endif // __linux__ && !__ANDROID__
#include "proxy.h"
@@ -256,6 +258,7 @@ int mallopt(int /*param*/, int /*value*/) __THROW
return 1;
}
+#ifdef __GLIBC__
struct mallinfo mallinfo() __THROW
{
struct mallinfo m;
@@ -263,6 +266,7 @@ struct mallinfo mallinfo() __THROW
return m;
}
+#endif
#if __ANDROID__
// Android doesn't have malloc_usable_size, provide it to be compatible

54
extra/ncspot/build.sh Normal file
View file

@ -0,0 +1,54 @@
pkgname=ncspot
pkgver=0.7.3
_clear_vendor_checksums() {
sed -i 's/\("files":{\)[^}]*/\1/' vendor/$1/.cargo-checksum.json
}
fetch() {
curl -L "https://github.com/hrkfdn/ncspot/archive/refs/tags/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.gz
# curl -L "https://github.com/sfackler/rust-openssl/archive/refs/tags/openssl-v0.10.34.tar.gz" -o rust-openssl.tar.gz
curl -L "https://github.com/Ella-0/ncurses-rs/archive/refs/heads/master.tar.gz" -o ncurses.tar.gz
curl -L "https://github.com/Ella-0/pancurses/archive/refs/heads/master.tar.gz" -o pancurses.tar.gz
tar -xf ncurses.tar.gz
mv ncurses-rs-master ncurses
tar -xf pancurses.tar.gz
mv pancurses-master pancurses
tar -xf $pkgname-$pkgver.tar.gz
tar -xf rust-openssl.tar.gz
cp ../cursive_ptr.patch .
cd $pkgname-$pkgver
mkdir -p .cargo
cargo vendor > .cargo/config
# _clear_vendor_checksums openssl-sys
# _clear_vendor_checksums openssl
_clear_vendor_checksums ncurses
_clear_vendor_checksums pancurses
_clear_vendor_checksums cursive
# cp -r ../rust-openssl-openssl-v0.10.34/openssl/ vendor/
# cp -r ../rust-openssl-openssl-v0.10.34/openssl-sys/ vendor/
cp -r ../ncurses/ vendor/
cp -r ../pancurses/ vendor/
# sed vendor/openssl/Cargo.toml -i -e 's/0.10.34/0.10.33/g'
# sed vendor/openssl/Cargo.toml -i -e 's/0.9.62/0.9.61/g'
# sed vendor/openssl-sys/Cargo.toml -i -e 's/0.9.62/0.9.61/g'
sed vendor/ncurses/Cargo.toml -i -e 's/5.100.0/5.101.0/g'
patch -p1 < ../cursive_ptr.patch
}
build() {
cd $pkgname-$pkgver
cargo build --release --no-default-features --features cursive/pancurses-backend,alsa_backend
}
package() {
cd $pkgname-$pkgver
install -Dm 755 target/release/$pkgname $pkgdir/usr/bin/
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

View file

@ -0,0 +1,11 @@
--- a/vendor/cursive/src/backends/curses/pan.rs
+++ b/vendor/cursive/src/backends/curses/pan.rs
@@ -70,7 +70,7 @@
pancurses::mouseinterval(0);
pancurses::mousemask(
pancurses::ALL_MOUSE_EVENTS | pancurses::REPORT_MOUSE_POSITION,
- ::std::ptr::null_mut(),
+ None,
);
// This asks the terminal to provide us with mouse drag events

28
extra/openssh/build.sh Normal file
View file

@ -0,0 +1,28 @@
pkgname=openssh
pkgver=8.6p1
fetch() {
curl "https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--build=x86_64-unknown-linux-musl \
--host=x86_64-unknown-linux-musl \
--libexecdir=/usr/lib
make
}
package() {
cd $pkgname-$pkgver
make install DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENCE
}

36
extra/tbb/build.sh Normal file
View file

@ -0,0 +1,36 @@
pkgname=tbb
pkgver=master
fetch() {
curl -L "https://github.com/oneapi-src/oneTBB/archive/refs/heads/master.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mv oneTBB-$pkgver $pkgname-$pkgver
mkdir $pkgname-$pkgver/build
cd $pkgname-$pkgver
patch -p1 < ../../musl-malloc-proxy.patch
patch -p1 < ../../musl-rtld.patch
}
build() {
cd $pkgname-$pkgver
cd build
cmake -G Ninja ../ \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DTBB_TEST=OFF \
-DCMAKE_CXX_FLAGS=-Wno-unused-command-line-argument
samu
}
package() {
cd $pkgname-$pkgver
cd build
DESTDIR=$pkgdir samu install
}
license() {
cd $pkgname-$pkgver
cat LICENSE.txt
# cat COPYING
}

View file

@ -0,0 +1,38 @@
--- a/src/tbbmalloc_proxy/proxy.cpp
+++ b/src/tbbmalloc_proxy/proxy.cpp
@@ -24,7 +24,8 @@
// of aligned_alloc as required by new C++ standard, this makes it hard to
// redefine aligned_alloc here. However, running on systems with new libc
// version, it still needs it to be redefined, thus tricking system headers
-#if defined(__GLIBC_PREREQ) && !__GLIBC_PREREQ(2, 16) && _GLIBCXX_HAVE_ALIGNED_ALLOC
+#if defined(__GLIBC_PREREQ)
+#if !__GLIBC_PREREQ(2, 16) && _GLIBCXX_HAVE_ALIGNED_ALLOC
// tell <cstdlib> that there is no aligned_alloc
#undef _GLIBCXX_HAVE_ALIGNED_ALLOC
// trick <stdlib.h> to define another symbol instead
@@ -32,7 +33,8 @@
// Fix the state and undefine the trick
#include <cstdlib>
#undef aligned_alloc
-#endif // defined(__GLIBC_PREREQ)&&!__GLIBC_PREREQ(2, 16)&&_GLIBCXX_HAVE_ALIGNED_ALLOC
+#endif // !__GLIBC_PREREQ(2, 16)&&_GLIBCXX_HAVE_ALIGNED_ALLOC
+#endif // defined(__GLIBC_PREREQ)
#endif // __linux__ && !__ANDROID__
#include "proxy.h"
@@ -253,6 +255,7 @@
return 1;
}
+#ifdef __GLIBC__
struct mallinfo mallinfo() __THROW
{
struct mallinfo m;
@@ -260,6 +263,7 @@
return m;
}
+#endif
#if __ANDROID__
// Android doesn't have malloc_usable_size, provide it to be compatible

14
extra/tbb/musl-rtld.patch Normal file
View file

@ -0,0 +1,14 @@
--- a/src/tbb/dynamic_link.cpp
+++ b/src/tbb/dynamic_link.cpp
@@ -413,9 +413,9 @@
int flags = RTLD_NOW;
if (local_binding) {
flags = flags | RTLD_LOCAL;
-#if __linux__ && !__ANDROID__ && !__TBB_USE_ADDRESS_SANITIZER
+#if __linux__ && defined(__GLIBC__) && !__TBB_USE_ADDRESS_SANITIZER
flags = flags | RTLD_DEEPBIND;
-#endif /*__linux__ && !__ANDROID__ && !__TBB_USE_ADDRESS_SANITIZER*/
+#endif /*__linux__ && defined(__GLIBC__) && !__TBB_USE_ADDRESS_SANITIZER*/
} else {
flags = flags | RTLD_GLOBAL;
}

25
extra/xxhash/build.sh Normal file
View file

@ -0,0 +1,25 @@
pkgname=xxhash
pkgver=0.8.0
deps=musl
fetch() {
curl -L "https://github.com/Cyan4973/xxHash/archive/refs/tags/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mv xxHash-$pkgver $pkgname-$pkgver
}
build() {
cd $pkgname-$pkgver
gmake PREFIX=/usr
}
package() {
cd $pkgname-$pkgver
gmake install PREFIX=/usr DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENSE
# cat COPYING
}

29
extra/youtube-dl/build.sh Normal file
View file

@ -0,0 +1,29 @@
pkgver=2021.04.07
pkgname=youtube-dl
deps=python
bad=""
fetch() {
curl -L "https://github.com/ytdl-org/youtube-dl/releases/download/2021.04.07/youtube-dl-2021.04.07.tar.gz" -o $pkgname-$pkgver.tar.gz
tar -xf $pkgname-$pkgver.tar.gz
mv $pkgname $pkgname-$pkgver
}
build() {
cd $pkgname-$pkgver
python setup.py build
}
package() {
cd $pkgname-$pkgver
python setup.py install --prefix=/usr --root=$pkgdir
}
package_doc() {
echo $pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENSE
}

View file

@ -0,0 +1,25 @@
pkgname=zsh-autosuggestions
pkgver=0.6.4
fetch() {
curl -L "https://github.com/zsh-users/$pkgname/archive/v$pkgver.tar.gz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
#mv zsh-users-$pkgname-* $pkgname-$pkgver
}
build() {
cd $pkgname-$pkgver
make
}
package() {
cd $pkgname-$pkgver
install -Dm644 ./$pkgname.zsh "$pkgdir/usr/share/zsh/plugins/$pkgname/"
install -Dm644 ./$pkgname.plugin.zsh "$pkgdir/usr/share/zsh/plugins/$pkgname/"
}
license() {
cd $pkgname-$pkgver
cat LICENSE
}

View file

@ -0,0 +1,23 @@
pkgname=zsh-syntax-highlighting
pkgver=0.7.1
fetch() {
curl -L "https://github.com/zsh-users/$pkgname/tarball/$pkgver" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
mv zsh-users-$pkgname-* $pkgname-$pkgver
}
build() {
cd $pkgname-$pkgver
make
}
package() {
cd $pkgname-$pkgver
make PREFIX="/usr" SHARE_DIR="$pkgdir/usr/share/zsh/plugins/$pkgname" DESTDIR="$pkgdir" install
}
license() {
cd $pkgname-$pkgver
cat COPYING.md
}

38
extra/zsh/build.sh Normal file
View file

@ -0,0 +1,38 @@
pkgname=zsh
pkgver=5.8
ext=doc
fetch() {
curl "https://www.zsh.org/pub/zsh-$pkgver.tar.xz" -o $pkgname-$pkgver.tar.xz
tar -xf $pkgname-$pkgver.tar.xz
cp ../zprofile.zsh .
}
build() {
cd $pkgname-$pkgver
./configure \
--prefix=/usr \
--build=$TRIPLE \
--host=$TRIPLE
make
}
package() {
cd $pkgname-$pkgver
make install DESTDIR=$pkgdir
install -d /etc
install -Dm644 ../zprofile.zsh $pkgdir/etc/zprofile
rm -rf $pkgdir/usr/share/man
}
package_doc() {
cd $pkgname-$pkgver
make install.man DESTDIR=$pkgdir
}
license() {
cd $pkgname-$pkgver
cat LICENCE
# cat COPYING
}

2
extra/zsh/zprofile.zsh Normal file
View file

@ -0,0 +1,2 @@
emulate sh -c 'source /etc/profile'
export PS1='%m%# '