ports: many new ports

This commit is contained in:
Matheus
2024-09-08 18:53:24 -03:00
parent b1fff0e09f
commit cb1da228b2
15 changed files with 247 additions and 3 deletions
+4 -2
View File
@@ -13,15 +13,17 @@ index 87bc25f..d7370d0 100644
#define IPPROTO_HOPOPTS 0
#define IPPROTO_ICMP 1
diff --git mlibc-clean/meson.build mlibc-workdir/meson.build
index bb8928f..7fd3280 100644
index bb8928f..969145b 100644
--- mlibc-clean/meson.build
+++ mlibc-workdir/meson.build
@@ -256,6 +256,13 @@ elif host_machine.system() == 'dripos'
@@ -256,6 +256,15 @@ elif host_machine.system() == 'dripos'
rtld_include_dirs += include_directories('sysdeps/dripos/include')
libc_include_dirs += include_directories('sysdeps/dripos/include')
subdir('sysdeps/dripos')
+elif host_machine.system() == 'astral'
+ disable_crypt_option = true
+ disable_iconv_option = true
+ disable_intl_option = true
+ rtld_include_dirs += include_directories('sysdeps/astral/include')
+ libc_include_dirs += include_directories('sysdeps/astral/include')
+ internal_conf.set10('MLIBC_MAP_DSO_SEGMENTS', true)
+63
View File
@@ -0,0 +1,63 @@
diff --git qemu-clean/block/file-posix.c qemu-workdir/block/file-posix.c
index ff928b5..4744f13 100644
--- qemu-clean/block/file-posix.c
+++ qemu-workdir/block/file-posix.c
@@ -110,6 +110,13 @@
#include <sys/diskslice.h>
#endif
+#ifdef __astral__
+#include <sys/ioctl.h>
+#ifdef CONFIG_BLKZONED
+#include <linux/blkzoned.h>
+#endif
+#endif
+
/* OS X does not have O_DSYNC */
#ifndef O_DSYNC
#ifdef O_SYNC
@@ -1217,7 +1224,7 @@ static int hdev_get_max_hw_transfer(int fd, struct stat *st)
/*
* Get a sysfs attribute value as character string.
*/
-#ifdef CONFIG_LINUX
+#if defined(CONFIG_LINUX) || defined(CONFIG_ASTRAL)
static int get_sysfs_str_val(struct stat *st, const char *attribute,
char **val) {
g_autofree char *sysfspath = NULL;
@@ -1271,7 +1278,7 @@ static int get_sysfs_zoned_model(struct stat *st, BlockZoneModel *zoned)
/*
* Get a sysfs attribute value as a long integer.
*/
-#ifdef CONFIG_LINUX
+#if defined(CONFIG_LINUX) || defined(CONFIG_ASTRAL)
static long get_sysfs_long_val(struct stat *st, const char *attribute)
{
g_autofree char *str = NULL;
diff --git qemu-clean/configure qemu-workdir/configure
index d08b71f..837d840 100755
--- qemu-clean/configure
+++ qemu-workdir/configure
@@ -333,7 +333,9 @@ int main(void) { return 0; }
EOF
}
-if check_define __linux__ ; then
+if check_define __astral__ ; then
+ host_os=astral
+elif check_define __linux__ ; then
host_os=linux
elif check_define _WIN32 ; then
host_os=windows
diff --git qemu-clean/meson.build qemu-workdir/meson.build
index fbda17c..b401e8b 100644
--- qemu-clean/meson.build
+++ qemu-workdir/meson.build
@@ -2364,6 +2364,7 @@ config_host_data.set('CONFIG_PIXMAN', pixman.found())
config_host_data.set('CONFIG_SLIRP', slirp.found())
config_host_data.set('CONFIG_SNAPPY', snappy.found())
config_host_data.set('CONFIG_SOLARIS', host_os == 'sunos')
+config_host_data.set('CONFIG_ASTRAL', host_os == 'astral')
if get_option('tcg').allowed()
config_host_data.set('CONFIG_TCG', 1)
config_host_data.set('CONFIG_TCG_INTERPRETER', tcg_arch == 'tci')
+21
View File
@@ -0,0 +1,21 @@
name=gettext
revision=1
from_source=gettext
imagedeps="base-devel"
hostdeps="xgcc xbinutils autoconf automake pkgconfig libtool"
deps="mlibc libiconv"
build() {
cp -rp ${source_dir}/* .
ACLOCAL=true AUTCONF=true AUTOMAKE=true AUTOHEADER=true ./configure --host=x86_64-astral --prefix=${prefix} --disable-static
make -j ${parallelism}
}
package() {
make install DESTDIR=${dest_dir}
rm -f ${dest_dir}/${prefix}/include/libintl.h
rm -f ${dest_dir}/${prefix}/lib/libintl.so*
rm -f ${dest_dir}/${prefix}/share/locale/locale.alias
}
+15
View File
@@ -0,0 +1,15 @@
name=glib
revision=1
from_source=glib
imagedeps="gcc meson ninja"
hostdeps="xgcc xbinutils pkgconfig automake autoconf util-macros libtool"
deps="mlibc libiconv pcre2 libffi libintl"
build() {
meson --cross-file ${base_dir}/util/crossfile --prefix=${prefix} --buildtype=release -Dxattr=false ${source_dir}
ninja -j${parallelism}
}
package() {
DESTDIR=${dest_dir} ninja install
}
+14
View File
@@ -0,0 +1,14 @@
name=install-astral
revision=1
from_source=install-astral
imagedeps="base-devel"
hostdeps="xbinutils xgcc"
deps="mlibc"
build() {
make -C ${source_dir} -j ${parallelism}
}
package() {
make -C ${source_dir} install DESTDIR=${dest_dir}
}
+15
View File
@@ -0,0 +1,15 @@
name=libffi
revision=1
from_source=libffi
imagedeps="base-devel"
hostdeps="xgcc xbinutils autoconf automake pkgconfig libtool"
deps="mlibc ncurses"
build() {
${source_dir}/configure --host=x86_64-astral --prefix=${prefix} --disable-static --enable-shared
make -j ${parallelism}
}
package() {
make install DESTDIR=${dest_dir}
}
+15
View File
@@ -0,0 +1,15 @@
name=libiconv
revision=1
from_source=libiconv
imagedeps="base-devel"
hostdeps="xgcc xbinutils libstdc++-v3"
deps="mlibc"
build() {
${source_dir}/configure --host=x86_64-astral --prefix=${prefix}
make -j ${parallelism}
}
package() {
make install DESTDIR=${dest_dir}
}
+19
View File
@@ -0,0 +1,19 @@
name=libintl
revision=1
from_source=gettext
imagedeps="base-devel"
hostdeps="xgcc xbinutils libstdc++-v3 automake autoconf pkgconfig libtool"
deps="mlibc"
build() {
cp -rp ${source_dir}/* .
ACLOCAL=true AUTCONF=true AUTOMAKE=true AUTOHEADER=true ./configure \
--host=x86_64-astral --prefix=${prefix} --without-emacs --without-lispdir --enable-nls --with-included-gettext --disable-c++ --disable-libasprintf --disable-java --enable-threads=posix --disable-curses --without-git --without-cvs --without-bzip2 --without-xz --disable-static
sed -i 's/touch $@//g' gettext-runtime/intl/Makefile
make -C gettext-runtime/intl -j${parallelism}
}
package() {
make install -C gettext-runtime/intl DESTDIR=${dest_dir}
}
+19
View File
@@ -0,0 +1,19 @@
name=qemu
revision=1
from_source=qemu
imagedeps="base-devel python-sphinx ninja meson git"
hostdeps="xgcc xbinutils pkgconfig libtool"
deps="mlibc sdl2 glib libiconv libintl"
allow_network="yes"
build() {
cp -rp ${source_dir}/* .
./configure --cross-prefix=x86_64-astral- --host=x86_64-astral --prefix=${prefix} --target-list=x86_64-softmmu,i386-softmmu,aarch64-softmmu --with-coroutine=sigaltstack
cd build
ninja -j${parallelism}
}
package() {
cd build
DESTDIR=${dest_dir} ninja install
}
+1 -1
View File
@@ -3,7 +3,7 @@ revision=1
from_source=sdl2
imagedeps="meson ninja base-devel"
hostdeps="xgcc xbinutils pkgconfig cmake libstdc++-v3"
deps="mlibc libx11 libxext libxcursor libxinerama libxi libxfixes libxrandr libxrender libxxf86vm mesa"
deps="mlibc libx11 libxext libxcursor libxinerama libxi libxfixes libxrandr libxrender libxxf86vm mesa libiconv"
build() {
cmake \
+15
View File
@@ -0,0 +1,15 @@
name=gettext
version=0.22.5
source_method=tarball
tarball_url="https://ftp.gnu.org/gnu/gettext/gettext-${version}.tar.gz"
tarball_sha512=d8b22d7fba10052a2045f477f0a5b684d932513bdb3b295c22fbd9dfc2a9d8fccd9aefd90692136c62897149aa2f7d1145ce6618aa1f0be787cb88eba5bc09be
hostdeps="autoconf automake libtool pkgconfig"
regenerate() {
( cd gettext-runtime/libasprintf && autoreconf -fvi )
( cd gettext-runtime/intl && autoreconf -fvi )
( cd gettext-runtime && autoreconf -fvi )
( cd gettext-tools && autoreconf -fvi )
( cd libtextstyle && autoreconf -fvi )
autoreconf -fvi
}
+8
View File
@@ -0,0 +1,8 @@
name=glib
version=2.82
source_method=tarball
tarball_url="https://download.gnome.org/sources/glib/${version}/glib-${version}.0.tar.xz"
tarball_sha512="7ce4dbc2b80fea1dca722bea02b1c35404108747b94c296760469b5416fc5ca737fc29c56a091120e5457a732656761424da614f3a626eb79b80b145507deb00"
regenerate() {
true
}
+10
View File
@@ -0,0 +1,10 @@
name=libffi
version=3.4.2
source_method=tarball
tarball_url="https://github.com/libffi/libffi/releases/download/v${version}/libffi-${version}.tar.gz"
tarball_sha512=31bad35251bf5c0adb998c88ff065085ca6105cf22071b9bd4b5d5d69db4fadf16cadeec9baca944c4bb97b619b035bb8279de8794b922531fddeb0779eb7fb1
hostdeps="autoconf automake libtool pkgconfig libtool"
regenerate() {
autoreconf -fvi
}
+19
View File
@@ -0,0 +1,19 @@
name=libiconv
version=1.17
source_method=tarball
tarball_url="https://ftp.gnu.org/gnu/libiconv/libiconv-${version}.tar.gz"
tarball_sha512=18a09de2d026da4f2d8b858517b0f26d853b21179cf4fa9a41070b2d140030ad9525637dc4f34fc7f27abca8acdc84c6751dfb1d426e78bf92af4040603ced86
hostdeps="autoconf automake libtool pkgconfig"
regenerate() {
cp -v /usr/local/share/aclocal/libtool.m4 ./m4/
cp -v /usr/local/share/aclocal/libtool.m4 ./libcharset/m4/
cp -v /usr/local/share/libtool/build-aux/ltmain.sh ./build-aux/
cp -v /usr/local/share/libtool/build-aux/ltmain.sh ./libcharset/build-aux/
cp -v /usr/local/share/aclocal/ltversion.m4 ./m4
cp -v /usr/local/share/aclocal/ltversion.m4 ./libcharset/m4
autoreconf -vfi -I${source_dir}/m4 -I${source_dir}/srcm4
cp -v $(find /usr/local/share/automake* -name config.sub) ./libcharset/build-aux/
}
+9
View File
@@ -0,0 +1,9 @@
name=qemu
version=9.1.0
source_method=tarball
tarball_url="https://download.qemu.org/qemu-${version}.tar.xz"
tarball_sha512="bf61d65e37945fa8ee8640712c719ace05164d86e6df700b98bdc5f79e0a8d5e8f85bd48e726edb62b2419db20673f63ec8b63a60393a914b09cb365621b35e2"
regenerate() {
true
}