Compare commits
5 Commits
eb9fe8ffc6
...
46dd411273
Author | SHA1 | Date |
---|---|---|
|
46dd411273 | |
|
2e2ee11452 | |
|
ce0df333b3 | |
|
8bbda78272 | |
|
945509fc93 |
|
@ -7,7 +7,6 @@ DEPENDENCIES=('zlib' 'zstd' 'expat')
|
|||
CONFIGURE_OPTIONS=(
|
||||
'-Dprefix=/usr'
|
||||
'-Dosmesa=true'
|
||||
'-Dgallium-drivers=softpipe'
|
||||
'-Dvulkan-drivers=[]'
|
||||
'-Dplatforms=[]'
|
||||
'-Dglx=disabled'
|
||||
|
@ -15,7 +14,50 @@ CONFIGURE_OPTIONS=(
|
|||
)
|
||||
|
||||
configure() {
|
||||
meson setup --reconfigure --cross-file "$MESON_CROSS_FILE" "${CONFIGURE_OPTIONS[@]}" build || exit 1
|
||||
llvm_version='20.1.8'
|
||||
llvm_root="../../llvm/llvm-$llvm_version-$BANAN_ARCH"
|
||||
|
||||
gallium_driver=softpipe
|
||||
|
||||
if [ -d "$llvm_root" ]; then
|
||||
llvm_lib=$(realpath "$llvm_root/build/lib")
|
||||
|
||||
mkdir -p subprojects/llvm
|
||||
|
||||
wrap_file='subprojects/llvm/meson.build'
|
||||
echo "project('llvm', ['cpp'])" >$wrap_file
|
||||
echo "" >>$wrap_file
|
||||
echo "cpp = meson.get_compiler('cpp')" >>$wrap_file
|
||||
echo "" >>$wrap_file
|
||||
echo "_deps = []" >>$wrap_file
|
||||
echo "_search = '$llvm_lib'" >>$wrap_file
|
||||
echo "foreach d : [" >>$wrap_file
|
||||
for path in $llvm_lib/libLLVM*.a; do
|
||||
name=$(basename $path)
|
||||
echo " '${name:3:-2}'," >>$wrap_file
|
||||
done
|
||||
echo " ]" >>$wrap_file
|
||||
echo " _deps += cpp.find_library(d, dirs : _search)" >>$wrap_file
|
||||
echo "endforeach" >>$wrap_file
|
||||
echo "" >>$wrap_file
|
||||
echo "dep_llvm = declare_dependency(" >>$wrap_file
|
||||
echo " include_directories : include_directories(" >>$wrap_file
|
||||
echo " '$(realpath $llvm_root/llvm/include)'," >>$wrap_file
|
||||
echo " '$(realpath $llvm_root/build/include)'," >>$wrap_file
|
||||
echo " )," >>$wrap_file
|
||||
echo " dependencies : _deps," >>$wrap_file
|
||||
echo " version : '$llvm_version'," >>$wrap_file
|
||||
echo ")" >>$wrap_file
|
||||
|
||||
gallium_driver=llvmpipe
|
||||
fi
|
||||
|
||||
meson setup \
|
||||
--reconfigure \
|
||||
--cross-file "$MESON_CROSS_FILE" \
|
||||
"${CONFIGURE_OPTIONS[@]}" \
|
||||
"-Dgallium-drivers=$gallium_driver" \
|
||||
build || exit 1
|
||||
}
|
||||
|
||||
build() {
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
diff -ru mesa-25.0.7-banan_os/src/gallium/drivers/llvmpipe/lp_texture.c mesa-25.0.7-x86_64/src/gallium/drivers/llvmpipe/lp_texture.c
|
||||
--- mesa-25.0.7-banan_os/src/gallium/drivers/llvmpipe/lp_texture.c 2025-05-28 18:20:23.000000000 +0300
|
||||
+++ mesa-25.0.7-x86_64/src/gallium/drivers/llvmpipe/lp_texture.c 2025-08-03 19:16:20.254971098 +0300
|
||||
@@ -59,7 +59,7 @@
|
||||
#include "frontend/sw_winsys.h"
|
||||
#include "git_sha1.h"
|
||||
|
||||
-#ifndef _WIN32
|
||||
+#if !defined(_WIN32) && !defined(__banan_os__)
|
||||
#include "drm-uapi/drm_fourcc.h"
|
||||
#endif
|
||||
|
||||
@@ -1713,7 +1713,7 @@
|
||||
case PIPE_RESOURCE_PARAM_LAYER_STRIDE:
|
||||
*value = lpr->img_stride[level];
|
||||
return true;
|
||||
-#ifndef _WIN32
|
||||
+#if !defined(_WIN32) && !defined(__banan_os__)
|
||||
case PIPE_RESOURCE_PARAM_MODIFIER:
|
||||
*value = lpr->dmabuf ? DRM_FORMAT_MOD_LINEAR : DRM_FORMAT_MOD_INVALID;
|
||||
return true;
|
|
@ -20,7 +20,7 @@ configure() {
|
|||
done
|
||||
popd
|
||||
|
||||
./waf configure -T release --disable-gl || exit 1
|
||||
./waf configure -T release || exit 1
|
||||
}
|
||||
|
||||
build() {
|
||||
|
@ -29,6 +29,7 @@ build() {
|
|||
|
||||
install() {
|
||||
./waf install --destdir=$BANAN_SYSROOT/home/user/halflife || exit 1
|
||||
patchelf --add-needed libxash.so $BANAN_SYSROOT/home/user/halflife/xash3d
|
||||
|
||||
cat > $BANAN_SYSROOT/home/user/halflife/start.sh << EOF
|
||||
#!/bin/Shell
|
||||
|
|
|
@ -134,8 +134,9 @@ struct sigevent
|
|||
#define SA_NODEFER 0x040
|
||||
#define SS_ONSTACK 0x080
|
||||
#define SS_DISABLE 0x100
|
||||
#define MINSIGSTKSZ 0x200
|
||||
#define SIGSTKSZ 0x400
|
||||
|
||||
#define MINSIGSTKSZ 4096
|
||||
#define SIGSTKSZ 4096
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
|
|
@ -25,7 +25,7 @@ __BEGIN_DECLS
|
|||
struct sockaddr
|
||||
{
|
||||
sa_family_t sa_family; /* Address family. */
|
||||
char sa_data[]; /* Socket address (variable-length data). */
|
||||
char sa_data[0]; /* Socket address (variable-length data). */
|
||||
};
|
||||
|
||||
struct sockaddr_storage
|
||||
|
|
|
@ -542,6 +542,9 @@ int getc_unlocked(FILE* file)
|
|||
if (file->eof)
|
||||
return EOF;
|
||||
|
||||
if (file == stdin && file->buffer_type == _IOLBF && stdout->buffer_type == _IOLBF && stdout->buffer_idx)
|
||||
fflush(stdout);
|
||||
|
||||
// read characters from ungetc
|
||||
if (file->unget_buf_idx)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue