FreeBSD Bugzilla – Attachment 233990 Details for
Bug 257170
[NEW PORT] emulators/libretro-flycast: Standalone port of flycast to libretro
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
[PATCH / NEW PORT] higher quality patch that builds on poudriere, not sure if otherwise different
emulators_libretro-flycast.diff (text/plain), 7.45 KB, created by
Timothy Beyer
on 2022-05-17 05:07:27 UTC
(
hide
)
Description:
[PATCH / NEW PORT] higher quality patch that builds on poudriere, not sure if otherwise different
Filename:
MIME Type:
Creator:
Timothy Beyer
Created:
2022-05-17 05:07:27 UTC
Size:
7.45 KB
patch
obsolete
>From 0a475b7b83b0d205e2795594b4bb7f7e8e1e5c46 Mon Sep 17 00:00:00 2001 >From: Timothy Beyer <beyert_freebsd@fastmail.net> >Date: Mon, 16 May 2022 20:53:46 -0700 >Subject: [PATCH] fix build of emulators/libretro-flycast in poudriere > >--- > /dev/null => emulators/libretro-flycast/Makefile | 62 ++++++++++++++++++++++ > /dev/null => emulators/libretro-flycast/distinfo | 3 ++ > .../libretro-flycast/files/patch-Makefile | 33 ++++++++++++ > .../files/patch-core_hw_aica_dsp__x64.cpp | 11 ++++ > .../files/patch-core_hw_bba_rtl8139c.h | 18 +++++++ > .../patch-core_libretro-common_rthreads_rthreads.c | 14 +++++ > /dev/null => emulators/libretro-flycast/pkg-descr | 6 +++ > .../null => emulators/libretro-flycast/pkg-message | 14 +++++ > 8 files changed, 161 insertions(+) > create mode 100644 emulators/libretro-flycast/Makefile > create mode 100644 emulators/libretro-flycast/distinfo > create mode 100644 emulators/libretro-flycast/files/patch-Makefile > create mode 100644 emulators/libretro-flycast/files/patch-core_hw_aica_dsp__x64.cpp > create mode 100644 emulators/libretro-flycast/files/patch-core_hw_bba_rtl8139c.h > create mode 100644 emulators/libretro-flycast/files/patch-core_libretro-common_rthreads_rthreads.c > create mode 100644 emulators/libretro-flycast/pkg-descr > create mode 100644 emulators/libretro-flycast/pkg-message > >diff --git a/emulators/libretro-flycast/Makefile b/emulators/libretro-flycast/Makefile >new file mode 100644 >index 0000000..e1f0a65 >--- /dev/null >+++ b/emulators/libretro-flycast/Makefile >@@ -0,0 +1,62 @@ >+# $FreeBSD$ >+ >+PORTNAME= libretro-flycast >+PORTVERSION= 0.20210608 >+CATEGORIES= emulators games >+ >+MAINTAINER= beyert@cs.ucr.edu >+COMMENT= Standalone port of flycast to libretro >+ >+LICENSE= GPLv2 >+#LICENSE_COMB= multi >+LICENSE_FILE= ${WRKSRC}/LICENSE >+ >+ONLY_FOR_ARCHS= amd64 i386 >+ >+LIB_DEPENDS+= libcurl.so:ftp/curl \ >+ libasound.so:audio/alsa-lib \ >+ libao.so:audio/libao \ >+ libevdev.so:devel/libevdev \ >+ libpulse.so:audio/pulseaudio \ >+ libudev.so:devel/libudev-devd \ >+ libvulkan.so:graphics/vulkan-loader >+ >+USES= compiler:c++11-lib gmake gl xorg dos2unix >+USE_LDCONFIG= yes >+ >+USE_GITHUB= yes >+GH_ACCOUNT= libretro >+GH_PROJECT= flycast >+GH_TAGNAME= 8e4fa54e >+ >+USE_GL+= gl glew glu >+ >+CFLAGS+= -I${LOCALBASE}/include >+CXXFLAGS+= -I${LOCALBASE}/include >+ >+.include <bsd.port.pre.mk> >+ >+DOS2UNIX_FILES= core/hw/bba/rtl8139c.h >+ >+.if ${ARCH} == amd64 >+CFLAGS+= -DLOW_END >+CXXFLAGS+= -DLOW_END >+.endif >+ >+LDFLAGS+= -L${LOCALBASE}/lib >+MAKE_ARGS= HAVE_VULKAN=0 HAVE_GENERIC_JIT=0 >+ >+.if ${ARCH} == amd64 >+MAKE_ARGS+= WITH_DYNAREC=x86_64 >+.elif ${ARCH} == i386 >+MAKE_ARGS+= WITH_DYNAREC=x86 >+.endif >+ >+PLIST_FILES= lib/libretro/flycast_libretro.so >+ >+do-install: >+ ${MKDIR} ${STAGEDIR}/${PREFIX}/lib/libretro; >+ ${INSTALL_LIB} ${WRKSRC}/flycast_libretro.so \ >+ ${STAGEDIR}/${PREFIX}/lib/libretro/flycast_libretro.so; >+ >+.include <bsd.port.post.mk> >diff --git a/emulators/libretro-flycast/distinfo b/emulators/libretro-flycast/distinfo >new file mode 100644 >index 0000000..eab0e7f >--- /dev/null >+++ b/emulators/libretro-flycast/distinfo >@@ -0,0 +1,3 @@ >+TIMESTAMP = 1623193824 >+SHA256 (libretro-flycast-0.20210608-8e4fa54e_GH0.tar.gz) = c11f19e25cf605ca3a2df74d1595c1b21ef8fff52b7fa42fc9bfc7fde611059e >+SIZE (libretro-flycast-0.20210608-8e4fa54e_GH0.tar.gz) = 6576666 >diff --git a/emulators/libretro-flycast/files/patch-Makefile b/emulators/libretro-flycast/files/patch-Makefile >new file mode 100644 >index 0000000..a0ba13f >--- /dev/null >+++ b/emulators/libretro-flycast/files/patch-Makefile >@@ -0,0 +1,33 @@ >+--- Makefile.orig 2021-05-17 21:23:19 UTC >++++ Makefile >+@@ -45,12 +45,8 @@ CC_AS ?= ${CC_PREFIX}as >+ >+ MFLAGS := >+ ASFLAGS := >+-LDFLAGS := >+ LDFLAGS_END := >+ INCFLAGS := >+-LIBS := >+-CFLAGS := >+-CXXFLAGS := >+ >+ GIT_VERSION := " $(shell git rev-parse --short HEAD || echo unknown)" >+ ifneq ($(GIT_VERSION)," unknown") >+@@ -70,7 +66,7 @@ endif >+ # Target Dynarec >+ WITH_DYNAREC = $(ARCH) >+ >+-ifeq ($(ARCH), $(filter $(ARCH), i386 i686)) >++ifeq ($(ARCH), $(filter $(ARCH), i386 i486 i686)) >+ WITH_DYNAREC = x86 >+ endif >+ >+@@ -145,7 +141,7 @@ ifneq (,$(findstring unix,$(platform))) >+ HAVE_CDROM = 1 >+ fpic = -fPIC >+ >+- ifeq ($(WITH_DYNAREC), $(filter $(WITH_DYNAREC), x86_64 x64)) >++ ifeq ($(WITH_DYNAREC), $(filter $(WITH_DYNAREC), x86_64 x64 amd64)) >+ CFLAGS += -DTARGET_LINUX_x64 >+ SINGLE_PREC_FLAGS=1 >+ HAVE_GENERIC_JIT = 0 >diff --git a/emulators/libretro-flycast/files/patch-core_hw_aica_dsp__x64.cpp b/emulators/libretro-flycast/files/patch-core_hw_aica_dsp__x64.cpp >new file mode 100644 >index 0000000..e49c488 >--- /dev/null >+++ b/emulators/libretro-flycast/files/patch-core_hw_aica_dsp__x64.cpp >@@ -0,0 +1,11 @@ >+--- core/hw/aica/dsp_x64.cpp.orig 2021-05-17 21:23:19 UTC >++++ core/hw/aica/dsp_x64.cpp >+@@ -37,6 +37,8 @@ DECL_ALIGN(4096) static u8 CodeBuffer[32 * 1024] >+ __attribute__((section(".text"))); >+ #elif defined(__MACH__) >+ __attribute__((section("__TEXT,.text"))); >++#elif defined(__FreeBSD__) >++ __attribute__((section(".text"))); >+ #else >+ #error CodeBuffer code section unknown >+ #endif >diff --git a/emulators/libretro-flycast/files/patch-core_hw_bba_rtl8139c.h b/emulators/libretro-flycast/files/patch-core_hw_bba_rtl8139c.h >new file mode 100644 >index 0000000..9f929ed >--- /dev/null >+++ b/emulators/libretro-flycast/files/patch-core_hw_bba_rtl8139c.h >@@ -0,0 +1,18 @@ >+--- core/hw/bba/rtl8139c.h.orig 2021-06-18 06:17:55 UTC >++++ core/hw/bba/rtl8139c.h >+@@ -58,6 +58,7 @@ struct MemoryRegion { >+ /* >+ * Byte swapping utilities >+ */ >++/* >+ static inline uint16_t bswap16(uint16_t x) >+ { >+ return (((x & 0x00ff) << 8) | >+@@ -71,6 +72,7 @@ static inline uint32_t bswap32(uint32_t x) >+ ((x & 0x00ff0000U) >> 8) | >+ ((x & 0xff000000U) >> 24)); >+ } >++*/ >+ #define glue(a, b) _glue(a, b) >+ #define _glue(a, b) a ## b >+ >diff --git a/emulators/libretro-flycast/files/patch-core_libretro-common_rthreads_rthreads.c b/emulators/libretro-flycast/files/patch-core_libretro-common_rthreads_rthreads.c >new file mode 100644 >index 0000000..82c1108 >--- /dev/null >+++ b/emulators/libretro-flycast/files/patch-core_libretro-common_rthreads_rthreads.c >@@ -0,0 +1,14 @@ >+--- core/libretro-common/rthreads/rthreads.c.orig 2021-05-17 21:23:19 UTC >++++ core/libretro-common/rthreads/rthreads.c >+@@ -55,10 +55,9 @@ >+ #include <sys/sys_time.h> >+ #else >+ #include <pthread.h> >+-#include <time.h> >+ #endif >+ >+-#if defined(VITA) || defined(BSD) || defined(ORBIS) >++#if defined(VITA) || defined(__FreeBSD__) || defined(ORBIS) >+ #include <sys/time.h> >+ #endif >+ >diff --git a/emulators/libretro-flycast/pkg-descr b/emulators/libretro-flycast/pkg-descr >new file mode 100644 >index 0000000..af0f3cf >--- /dev/null >+++ b/emulators/libretro-flycast/pkg-descr >@@ -0,0 +1,6 @@ >+Standalone port of Flycast to libretro. >+ >+Flycast is a multi-platform Sega Dreamcast, Naomi and Atomiswave emulator >+derived from Reicast. >+ >+WWW: https://git.libretro.com/libretro/flycast >diff --git a/emulators/libretro-flycast/pkg-message b/emulators/libretro-flycast/pkg-message >new file mode 100644 >index 0000000..4faa580 >--- /dev/null >+++ b/emulators/libretro-flycast/pkg-message >@@ -0,0 +1,14 @@ >+[ >+{ type: install >+ message: <<EOM >+The libretro core of flycast will not run if run ahead support is enabled. >+Please set all lines in ~/.config/retroarch/retroarch.cfg that correspond to >+the setting "run_ahead_enabled" to "false", as shown in the example below: >+ >+run_ahead_enabled = "false" >+ >+To troubleshoot issues, running retroarch with the -v argument may help to >+acquire more diagnostic information. >+EOM >+} >+]
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
beyert
:
maintainer-approval+
Actions:
View
|
Diff
Attachments on
bug 257170
:
226444
| 233990