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

Collapse All | Expand All

(-)b/emulators/Makefile (+1 lines)
Lines 35-40 Link Here
35
    SUBDIR += es-de
35
    SUBDIR += es-de
36
    SUBDIR += fceux
36
    SUBDIR += fceux
37
    SUBDIR += flexemu
37
    SUBDIR += flexemu
38
    SUBDIR += flycast
38
    SUBDIR += fmsx
39
    SUBDIR += fmsx
39
    SUBDIR += frodo
40
    SUBDIR += frodo
40
    SUBDIR += fs-uae
41
    SUBDIR += fs-uae
(-)b/emulators/flycast/Makefile (+66 lines)
Added Link Here
1
PORTNAME=	flycast
2
DISTVERSIONPREFIX=	v
3
DISTVERSION=	2.4
4
CATEGORIES=	emulators
5
6
MAINTAINER=	bsdcode@disroot.org
7
COMMENT=	Multi-platform Sega Dreamcast emulator
8
WWW=		https://github.com/flyinghead/flycast
9
10
LICENSE=	GPLv2
11
LICENSE_FILE=	${WRKSRC}/LICENSE
12
13
LIB_DEPENDS=	libchdr.so:devel/libchdr \
14
		libcurl.so:ftp/curl \
15
		libminiupnpc.so:net/miniupnpc \
16
		libzip.so:archivers/libzip \
17
		libzstd.so:archivers/zstd
18
19
USES=		cmake compiler:c++17-lang lua:52+ pkgconfig sdl
20
USE_GITHUB=	yes
21
GH_ACCOUNT=	flyinghead
22
USE_SDL=	sdl2
23
24
.include "${.CURDIR}/Makefile.tuples"
25
26
OPTIONS_DEFINE=		DOCS OPENMP VULKAN
27
OPTIONS_DEFAULT=	ALSA AO OPENMP OSS VULKAN
28
OPTIONS_GROUP=		AUDIO
29
OPTIONS_GROUP_AUDIO=	ALSA AO OSS PULSEAUDIO
30
31
VULKAN_DESC=	Build with Vulkan support
32
33
ALSA_LIB_DEPENDS=	libasound.so:audio/alsa-lib
34
ALSA_CMAKE_BOOL=	USE_ALSA
35
36
AO_LIB_DEPENDS=		libao.so:audio/libao
37
AO_CMAKE_BOOL=		USE_AO
38
39
OPENMP_CMAKE_BOOL=	USE_OPENMP
40
41
OSS_CMAKE_BOOL=		USE_OSS
42
43
PULSEAUDIO_LIB_DEPENDS=	libpulse.so:audio/pulseaudio
44
PULSEAUDIO_CMAKE_BOOL=	USE_PULSEAUDIO
45
46
VULKAN_BUILD_DEPENDS=	glslang:graphics/glslang \
47
			vulkan-headers:graphics/vulkan-headers
48
VULKAN_CMAKE_BOOL=	USE_HOST_GLSLANG USE_VULKAN
49
50
post-install-DOCS-on:
51
	${MKDIR} ${STAGEDIR}${DOCSDIR}
52
	(cd ${WRKSRC}/docs && \
53
		${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
54
55
# For maintainer (do not forget to clean up Makefile.tuples afterwards to
56
# remove useless submodules)
57
Makefile.tuples::
58
	${RM} -f ${.CURDIR}/Makefile.tuples
59
	${RM} -rf ${WRKDIR}/.maintainer.checkout
60
	${MKDIR} ${WRKDIR}/.maintainer.checkout
61
	(cd ${WRKDIR}/.maintainer.checkout && \
62
		git clone --recursive --branch=${DISTVERSIONPREFIX}${DISTVERSION} \
63
		https://github.com/${GH_ACCOUNT}/${PORTNAME} . && \
64
		${SH} ${FILESDIR}/gen_gh_tuple.sh > ${.CURDIR}/Makefile.tuples)
65
66
.include <bsd.port.mk>
(-)b/emulators/flycast/Makefile.tuples (+4 lines)
Added Link Here
1
GH_TUPLE= \
2
	vinniefalco:LuaBridge:fab7b33b896a42dcc865ba5ecdbacd9f409137f8:LuaBridge/core/deps/luabridge \
3
	GPUOpen-LibrariesAndSDKs:VulkanMemoryAllocator:6eb62e1515072827db992c2befd80b71b2d04329:VulkanMemoryAllocator/core/deps/VulkanMemoryAllocator \
4
	RetroAchievements:rcheevos:563230b1c249774b4852c944dc7cdcb952c9e8e8:rcheevos/core/deps/rcheevos \
(-)b/emulators/flycast/distinfo (+9 lines)
Added Link Here
1
TIMESTAMP = 1731443633
2
SHA256 (flyinghead-flycast-v2.4_GH0.tar.gz) = 44b2ff5d172f7be2be9db613ebd22635760cfc846ddb4c25e1da0d8fa79b1a1b
3
SIZE (flyinghead-flycast-v2.4_GH0.tar.gz) = 30398953
4
SHA256 (vinniefalco-LuaBridge-fab7b33b896a42dcc865ba5ecdbacd9f409137f8_GH0.tar.gz) = d393adc6bf1659faf2683f6ef2766ee7223650c8087ce53f8ab529e44c1c1575
5
SIZE (vinniefalco-LuaBridge-fab7b33b896a42dcc865ba5ecdbacd9f409137f8_GH0.tar.gz) = 543800
6
SHA256 (GPUOpen-LibrariesAndSDKs-VulkanMemoryAllocator-6eb62e1515072827db992c2befd80b71b2d04329_GH0.tar.gz) = 9afe46ce02681799ca907fb79990ff276877dfb6324d48da21b215b92649368d
7
SIZE (GPUOpen-LibrariesAndSDKs-VulkanMemoryAllocator-6eb62e1515072827db992c2befd80b71b2d04329_GH0.tar.gz) = 877925
8
SHA256 (RetroAchievements-rcheevos-563230b1c249774b4852c944dc7cdcb952c9e8e8_GH0.tar.gz) = fab0809e60d8ed64a4a2bef2964315e9f4b6e770db4c963630441352d1dd21d1
9
SIZE (RetroAchievements-rcheevos-563230b1c249774b4852c944dc7cdcb952c9e8e8_GH0.tar.gz) = 669618
(-)b/emulators/flycast/files/gen_gh_tuple.sh (+29 lines)
Added Link Here
1
#!/bin/sh
2
3
echo "GH_TUPLE= \\"
4
for _sm_root in $(find . -type f -name .gitmodules | sed 's/\.gitmodules$//' | sort)
5
do
6
  (
7
    cd "${_sm_root}"
8
9
    # Crawl name|path|url list of submodules within _sm_root
10
    grep -e '^\[submodule "' -e 'path = ' -e 'url = ' .gitmodules | \
11
      sed -E -e 's|.*"([^"]+)".*|\1|' -e 's|.*= ||' | \
12
      paste - - - | \
13
      sed -E 's/[[:space:]]+/|/g' | \
14
    while read _sm
15
    do
16
      _sm_name=$(echo "${_sm}" | cut -d '|' -f 1)
17
      _sm_path=$(echo "${_sm}" | cut -d '|' -f 2)
18
      _sm_url=$(echo "${_sm}" | cut -d '|' -f 3)
19
20
      _sm_prefix=$(echo "${_sm_root}" | sed 's|^\./||')
21
22
      _account_project=$(echo "${_sm_url}" | sed -e 's|^https://github.com/||' -e 's|/|:|g' -e 's|\.git$||')
23
      _group=$(echo "${_account_project}" | cut -d ':' -f 2 | tr -cd 'a-zA-Z0-9_')
24
      _tagname_group_subdir=$(git submodule status "${_sm_path}" | sed -E -e 's|^.||' -e "s|[[:space:]]+|:${_group}/${_sm_prefix}|" -e 's|[[:space:]]+.*$||')
25
      echo -e "\t${_account_project}:${_tagname_group_subdir} \\"
26
    done
27
  )
28
done
29
echo ""
(-)b/emulators/flycast/files/patch-CMakeLists.txt (+57 lines)
Added Link Here
1
--- CMakeLists.txt.orig	2024-10-21 14:13:00 UTC
2
+++ CMakeLists.txt
3
@@ -410,9 +410,13 @@ endif()
4
 	target_link_libraries(${PROJECT_NAME} PRIVATE glslang::glslang-default-resource-limits glslang::SPIRV)
5
 endif()
6
 
7
+if(USE_OSS)
8
+	target_compile_definitions(${PROJECT_NAME} PRIVATE USE_OSS)
9
+endif()
10
+
11
 if(NOT LIBRETRO)
12
 	find_package(ALSA)
13
-	if(ALSA_FOUND AND NOT ANDROID)
14
+	if(USE_ALSA AND ALSA_FOUND AND NOT ANDROID)
15
 		target_compile_definitions(${PROJECT_NAME} PRIVATE USE_ALSA)
16
 		target_include_directories(${PROJECT_NAME} PRIVATE ${ALSA_INCLUDE_DIRS})
17
 		target_link_libraries(${PROJECT_NAME} PRIVATE ${ALSA_LIBRARIES})
18
@@ -471,9 +475,8 @@ endif()
19
 	endif()
20
 endif()
21
 
22
-add_subdirectory(core/deps/libchdr EXCLUDE_FROM_ALL)
23
-target_link_libraries(${PROJECT_NAME} PRIVATE chdr-static)
24
-target_include_directories(${PROJECT_NAME} PRIVATE core/deps/libchdr/include)
25
+pkg_check_modules(libchdr REQUIRED libchdr)
26
+target_link_libraries(${PROJECT_NAME} PRIVATE ${libchdr_LINK_LIBRARIES})
27
 
28
 if(NOT WITH_SYSTEM_ZLIB)
29
 	set(ZLIB_RELATIVE_PATH "core/deps/libchdr/deps/zlib-1.3.1")
30
@@ -490,7 +493,7 @@ if(PKG_CONFIG_FOUND AND NOT ANDROID AND NOT APPLE AND 
31
 find_package(PkgConfig)
32
 if(PKG_CONFIG_FOUND AND NOT ANDROID AND NOT APPLE AND NOT LIBRETRO)
33
 	pkg_check_modules(AO IMPORTED_TARGET ao)
34
-	if(AO_FOUND)
35
+	if(USE_AO AND AO_FOUND)
36
 		target_compile_definitions(${PROJECT_NAME} PRIVATE USE_LIBAO)
37
 		target_link_libraries(${PROJECT_NAME} PRIVATE PkgConfig::AO)
38
 	endif()
39
@@ -510,7 +513,7 @@ if(PKG_CONFIG_FOUND AND NOT ANDROID AND NOT APPLE AND 
40
 	endif()
41
 
42
 	pkg_check_modules(LIBPULSE IMPORTED_TARGET libpulse)
43
-	if(LIBPULSE_FOUND)
44
+	if(USE_PULSEAUDIO AND LIBPULSE_FOUND)
45
 		target_compile_definitions(${PROJECT_NAME} PRIVATE USE_PULSEAUDIO)
46
 		target_link_libraries(${PROJECT_NAME} PRIVATE PkgConfig::LIBPULSE)
47
 	endif()
48
@@ -1338,8 +1341,7 @@ if(USE_VULKAN)
49
 		target_compile_definitions(${PROJECT_NAME} PUBLIC VK_USE_PLATFORM_METAL_EXT)
50
 	endif()
51
 
52
-	add_subdirectory(core/deps/Vulkan-Headers)
53
-	target_link_libraries(${PROJECT_NAME} PRIVATE Vulkan::Headers)
54
+	find_package(VulkanHeaders)
55
 
56
 	add_subdirectory(core/deps/VulkanMemoryAllocator)
57
 	target_compile_options(VulkanMemoryAllocator INTERFACE $<$<AND:$<COMPILE_LANGUAGE:CXX>,$<CXX_COMPILER_ID:AppleClang,Clang>>:-Wno-nullability-completeness>)
(-)b/emulators/flycast/files/patch-core_rend_vulkan_vmallocator.cpp (+9 lines)
Added Link Here
1
--- core/rend/vulkan/vmallocator.cpp.orig	2024-11-10 23:58:20 UTC
2
+++ core/rend/vulkan/vmallocator.cpp
3
@@ -71,5 +71,5 @@ void VMAllocator::Init(vk::PhysicalDevice physicalDevi
4
 #endif
5
 
6
 	VkResult rc = vmaCreateAllocator(&allocatorInfo, &allocator);
7
-	vk::resultCheck(static_cast<vk::Result>(rc), "vmaCreateAllocator failed");
8
+	vk::detail::resultCheck(static_cast<vk::Result>(rc), "vmaCreateAllocator failed");
9
 }
(-)b/emulators/flycast/files/patch-core_rend_vulkan_vmallocator.h (+38 lines)
Added Link Here
1
--- core/rend/vulkan/vmallocator.h.orig	2024-11-10 23:58:42 UTC
2
+++ core/rend/vulkan/vmallocator.h
3
@@ -64,7 +64,7 @@ class Allocation (public)
4
 			return allocInfo.pMappedData;
5
 		void *p;
6
 		VkResult res = vmaMapMemory(allocator, allocation, &p);
7
-		vk::resultCheck(static_cast<vk::Result>(res), "vmaMapMemory failed");
8
+		vk::detail::resultCheck(static_cast<vk::Result>(res), "vmaMapMemory failed");
9
 		VkMemoryPropertyFlags flags;
10
 		vmaGetMemoryTypeProperties(allocator, allocInfo.memoryType, &flags);
11
 		if ((flags & VK_MEMORY_PROPERTY_HOST_CACHED_BIT) && (flags & VK_MEMORY_PROPERTY_HOST_COHERENT_BIT) == 0)
12
@@ -114,7 +114,7 @@ class VMAllocator (public)
13
 		VmaAllocation vmaAllocation;
14
 		VmaAllocationInfo allocInfo;
15
 		VkResult rc = vmaAllocateMemory(allocator, (VkMemoryRequirements*)&memoryRequirements, &allocCreateInfo, &vmaAllocation, &allocInfo);
16
-		vk::resultCheck(static_cast<vk::Result>(rc), "vmaAllocateMemory failed");
17
+		vk::detail::resultCheck(static_cast<vk::Result>(rc), "vmaAllocateMemory failed");
18
 		return Allocation(allocator, vmaAllocation, allocInfo);
19
 	}
20
 
21
@@ -123,7 +123,7 @@ class VMAllocator (public)
22
 		VmaAllocation vmaAllocation;
23
 		VmaAllocationInfo allocInfo;
24
 		VkResult rc = vmaAllocateMemoryForImage(allocator, (VkImage)image, &allocCreateInfo, &vmaAllocation, &allocInfo);
25
-		vk::resultCheck(static_cast<vk::Result>(rc), "vmaAllocateMemoryForImage failed");
26
+		vk::detail::resultCheck(static_cast<vk::Result>(rc), "vmaAllocateMemoryForImage failed");
27
 		vmaBindImageMemory(allocator, vmaAllocation, (VkImage)image);
28
 
29
 		return Allocation(allocator, vmaAllocation, allocInfo);
30
@@ -134,7 +134,7 @@ class VMAllocator (public)
31
 		VmaAllocation vmaAllocation;
32
 		VmaAllocationInfo allocInfo;
33
 		VkResult rc = vmaAllocateMemoryForBuffer(allocator, (VkBuffer)buffer, &allocCreateInfo, &vmaAllocation, &allocInfo);
34
-		vk::resultCheck(static_cast<vk::Result>(rc), "vmaAllocateMemoryForBuffer failed");
35
+		vk::detail::resultCheck(static_cast<vk::Result>(rc), "vmaAllocateMemoryForBuffer failed");
36
 		vmaBindBufferMemory(allocator, vmaAllocation, (VkBuffer)buffer);
37
 
38
 		return Allocation(allocator, vmaAllocation, allocInfo);
(-)b/emulators/flycast/files/patch-core_rend_vulkan_vulkan__context.cpp (+19 lines)
Added Link Here
1
--- core/rend/vulkan/vulkan_context.cpp.orig	2024-10-21 14:13:00 UTC
2
+++ core/rend/vulkan/vulkan_context.cpp
3
@@ -42,6 +42,7 @@ VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE
4
 #endif
5
 
6
 #include <memory>
7
+#include <set>
8
 
9
 void ReInitOSD();
10
 
11
@@ -146,7 +147,7 @@ bool VulkanContext::InitInstance(const char** extensio
12
 #if defined(__ANDROID__) && HOST_CPU == CPU_ARM64
13
 		vkGetInstanceProcAddr = loadVulkanDriver();
14
 #else
15
-		static vk::DynamicLoader dl;
16
+		static vk::detail::DynamicLoader dl;
17
 		vkGetInstanceProcAddr = dl.getProcAddress<PFN_vkGetInstanceProcAddr>("vkGetInstanceProcAddr");
18
 #endif
19
 		if (vkGetInstanceProcAddr == nullptr) {
(-)b/emulators/flycast/pkg-descr (+14 lines)
Added Link Here
1
Flycast is a multi-platform Sega Dreamcast, Naomi, Naomi 2, and Atomiswave
2
emulator derived from the inactive reicast project.
3
4
Flycast provides high performance and high compatibility. It supports an HLE
5
BIOS, so dumping a real BIOS from a console isn't required (but it is still
6
recommended for increased compatibility). Furthermore it supports widescreen,
7
either with a generic hack to render outside of the screen, or by auto-applying
8
codes/patches to certain games which provides better results. Resolution and
9
texture upscaling is supported alongside dumping and loading of custom textures.
10
Flycast emulates standard Dreamcast controllers, keyboard, mouse, light-gun
11
(with your mouse), Twin Sticks, and even the ASCII Mission Stick. It can emulate
12
two expansion sockets per controller (VMU, Purupuru/Rumble Pack, or Microphone).
13
Most if not all games compatible with Dreamcast Live servers are supported by
14
Flycast.
(-)b/emulators/flycast/pkg-plist (-1 / +17 lines)
Added Link Here
0
- 
1
bin/flycast
2
share/applications/flycast.desktop
3
%%PORTDOCS%%%%DOCSDIR%%/DreamCast_Specs.md
4
%%PORTDOCS%%%%DOCSDIR%%/Dynarec Architecture.md
5
%%PORTDOCS%%%%DOCSDIR%%/Naomi_Overview.md
6
%%PORTDOCS%%%%DOCSDIR%%/Notable game bugs.md
7
%%PORTDOCS%%%%DOCSDIR%%/microphone support notes.txt
8
%%PORTDOCS%%%%DOCSDIR%%/neil_corlett_aica_notes.txt
9
share/icons/hicolor/128x128/apps/flycast.png
10
share/icons/hicolor/16x16/apps/flycast.png
11
share/icons/hicolor/256x256/apps/flycast.png
12
share/icons/hicolor/32x32/apps/flycast.png
13
share/icons/hicolor/512x512/apps/flycast.png
14
share/icons/hicolor/64x64/apps/flycast.png
15
share/man/man1/flycast.1.gz
16
share/metainfo/org.flycast.Flycast.metainfo.xml
17
share/pixmaps/flycast.png

Return to bug 282691