View | Details | Raw Unified | Return to bug 257171 | Differences between
and this patch

Collapse All | Expand All

(-)b/emulators/libretro-kronos/Makefile (+60 lines)
Added Link Here
1
# Created by Timothy Beyer <beyert@cs.ucr.edu>
2
3
PORTNAME=	libretro-kronos
4
PORTVERSION=	0.20210617
5
CATEGORIES=	emulators games
6
7
MAINTAINER=	beyert@cs.ucr.edu
8
COMMENT=	Sega Saturn and ST-V emulator forked from uoYabause for libretro
9
10
LICENSE=	GPLv2
11
LICENSE_FILE=	${WRKSRC}/yabause/COPYING
12
13
LIB_DEPENDS=	libGL.so:graphics/mesa-libs
14
15
# standalone version uses solely cmake, whereas the retroarch core uses both
16
# cmake and gmake
17
USES=		compiler:c++11-lib cmake gmake gl sdl qt:5 pkgconfig
18
USE_LDCONFIG=	yes
19
20
USE_SDL=	sdl2
21
22
USE_GITHUB=	yes
23
GH_ACCOUNT=	FCare
24
GH_PROJECT=	Kronos
25
GH_TAGNAME=	a39f95a
26
27
USE_GL=	gl glew glu
28
29
USE_QT=	qmake_build buildtools_build core opengl
30
31
CFLAGS+=	-I${LOCALBASE}/include
32
CXXFLAGS+=	-I${LOCALBASE}/include
33
LDFLAGS+=	-L${LOCALBASE}/lib
34
35
PLIST_FILES=	lib/libretro/kronos_libretro.so
36
37
cmake_ARGS=	noninja
38
CMAKE_SOURCE_PATH=	${WRKSRC}/yabause
39
40
MAKE_ARGS=	USE_RTHREADS=1
41
42
pre-build:
43
	cd ${CMAKE_SOURCE_PATH} && ${CMAKE_BIN} .
44
	cd ${WRKSRC}/yabause/src && ${MAKE} m68kmake
45
46
.include <bsd.port.pre.mk>
47
48
do-build:
49
	cd ${WRKSRC}/yabause/src/libretro && ${DO_MAKE_BUILD}
50
51
post-patch:
52
.if ${ARCH} != "amd64"
53
	@${REINPLACE_CMD} -e "s/HAVE_SSE = 1/HAVE_SSE = 0/" ${WRKSRC}/yabause/src/libretro/Makefile
54
.endif
55
56
do-install:
57
	${MKDIR} ${STAGEDIR}/${PREFIX}/lib/libretro;
58
	${INSTALL_LIB} ${WRKSRC}/yabause/src/libretro/kronos_libretro.so ${STAGEDIR}/${PREFIX}/lib/libretro;
59
60
.include <bsd.port.post.mk>
(-)b/emulators/libretro-kronos/distinfo (+3 lines)
Added Link Here
1
TIMESTAMP = 1623926653
2
SHA256 (FCare-Kronos-0.20210617-a39f95a_GH0.tar.gz) = a9edd4b88b874f4b1d1fb0b9e66cf2bc8bc3b643ee02b127db84a79fce31a6e8
3
SIZE (FCare-Kronos-0.20210617-a39f95a_GH0.tar.gz) = 36104449
(-)b/emulators/libretro-kronos/files/patch-yabause_src_libretro_Makefile (+11 lines)
Added Link Here
1
--- yabause/src/libretro/Makefile.orig	2021-06-01 21:12:00 UTC
2
+++ yabause/src/libretro/Makefile
3
@@ -291,7 +291,7 @@ endif
4
 
5
 OBJECTS += $(OBJECTS_C) $(OBJECTS_CXX) $(OBJECTS_S)
6
 
7
-LDFLAGS += $(fpic) $(SHARED) -latomic
8
+LDFLAGS += $(fpic) $(SHARED)
9
 FLAGS += $(fpic)
10
 
11
 INCFLAGS := $(foreach dir,$(INCLUDE_DIRS),-I$(dir))
(-)b/emulators/libretro-kronos/files/patch-yabause_src_libretro_Makefile.common (+36 lines)
Added Link Here
1
--- yabause/src/libretro/Makefile.common.orig	2021-06-01 21:12:00 UTC
2
+++ yabause/src/libretro/Makefile.common
3
@@ -182,6 +182,8 @@ ifeq ($(HAVE_CDROM), 1)
4
 	endif
5
 endif
6
 
7
+SOURCES_C += $(LIBRETRO_COMM_DIR)/string/stdstring.c
8
+
9
 ifeq ($(ARCH_IS_WINDOWS), 1)
10
 	SOURCES_C += $(FLAC_DIR)/src/libFLAC/windows_unicode_filenames.c
11
 endif
12
@@ -209,14 +211,16 @@ ifeq ($(USE_RTHREADS), 1)
13
 	SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-rthreads.c \
14
 		$(LIBRETRO_COMM_DIR)/rthreads/rthreads.c
15
 else
16
-	ifeq ($(ARCH_IS_LINUX), 1)
17
-		SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-linux.c
18
-	else ifeq ($(ARCH_IS_MACOSX), 1)
19
-		SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-linux.c \
20
-			$(SOURCE_DIR)/ctrl/threads/linux/pthread_barrier.c
21
-	else
22
-		SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-windows.c
23
-	endif
24
+
25
+SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-dummy.c
26
+#	ifeq ($(ARCH_IS_LINUX), 1)
27
+#		SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-linux.c
28
+#	else ifeq ($(ARCH_IS_MACOSX), 1)
29
+#		SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-linux.c \
30
+#			$(SOURCE_DIR)/ctrl/threads/linux/pthread_barrier.c
31
+#	else
32
+#		SOURCES_C += $(SOURCE_DIR)/ctrl/threads/thr-windows.c
33
+#	endif
34
 endif
35
 
36
 M68KMAKE_EXE = m68kmake$(EXE_EXT)
(-)b/emulators/libretro-kronos/files/patch-yabause_src_libretro_libretro-common_rthreads_rthreads.c (+11 lines)
Added Link Here
1
--- yabause/src/libretro/libretro-common/rthreads/rthreads.c.orig	2020-05-02 13:49:27 UTC
2
+++ yabause/src/libretro/libretro-common/rthreads/rthreads.c
3
@@ -67,6 +67,8 @@
4
 #include <mach/mach.h>
5
 #endif
6
 
7
+#include <sys/time.h>
8
+
9
 struct thread_data
10
 {
11
    void (*func)(void*);
(-)b/emulators/libretro-kronos/pkg-descr (+6 lines)
Added Link Here
1
Kronos is a Sega Saturn and ST-V emulator forked from uoYabause. Kronos is
2
targetting Linux and Windows OS.
3
4
This is the libretro port of Kronos.
5
6
WWW: https://fcare.github.io
(-)b/emulators/libretro-kronos/pkg-message (+34 lines)
Added Link Here
1
[
2
{ type: install
3
  message: <<EOM
4
For Sega Saturn, it is mandatory to install a supported Sega Saturn bios files
5
(such as saturn_bios.bin) in ~/.config/retroarch/system or
6
~/.config/retroarch/system/kronos.
7
8
Kronos is broadly compatible with all major Saturn BIOSes regardless of region,
9
although unlike Yabause, a BIOS dump is required.  Due to the aforementioned
10
BIOS compatibility, the BIOS guide for the beetle-saturn libretro core may be
11
helpful:
12
13
https://docs.libretro.com/library/beetle_saturn/
14
15
For ST-V, it is necessary to add a compatible stvbios.zip either in
16
~/.config/retroarch/system/kronos or in ~/.config/retroarch/system/.  In
17
contrast to MAME, Kronos will never search for this bios file in the local path
18
of the game.
19
20
If the emulator gets stuck on the BIOS screen, the screen remains blank, or
21
shows audio track navigation controls, then the BIOS is likely incompatible.
22
23
At present, Kronos is only compatible with a subset of the stvbios.zip files
24
used by modern MAME versions.  If the stvbios.zip is not present in the proper
25
place, but one of the proper Sega Saturn BIOSes is instead available, it will
26
try to default to one of those, and in the most optimistic case, merely reach
27
the audio CD track navigation controls, but it will not work, since it is not
28
the same hardware.
29
30
If in doubt, running retroarch with the -v argument may help to acquire more
31
diagnostic information.
32
EOM
33
}
34
]

Return to bug 257171