This port globally sets SSE for the build, which does not exist on
arm64.  While here, change post-patch target to pre-configure, so
make update-patches works as expected.

Game now builds on arm64 and I can play amd64.

OK?


Index: games/choria/Makefile
===================================================================
RCS file: /cvs/openbsd/ports/games/choria/Makefile,v
retrieving revision 1.15
diff -u -p -u -p -r1.15 Makefile
--- games/choria/Makefile       25 Jan 2023 10:15:21 -0000      1.15
+++ games/choria/Makefile       2 Feb 2023 14:07:48 -0000
@@ -6,6 +6,7 @@ DISTNAME =      choria-${V}-${COMMIT}-src
 PKGNAME =      choria-${V}
 CATEGORIES =   games x11
 MAINTAINER =   Sebastian Reitenbach <[email protected]>
+REVISION =     0
 
 HOMEPAGE =     https://choria.gitlab.io/
 
@@ -43,7 +44,7 @@ NO_TEST =     Yes
 
 WRKDIST =      ${WRKDIR}/choria-${V}-${COMMIT}
 
-post-patch:
+pre-configure:
        perl -pi -e "s,games/,,g" ${WRKSRC}/CMakeLists.txt \
                                  ${WRKSRC}/deployment/choria
        perl -pi -e "s,games,bin,g" ${WRKSRC}/CMakeLists.txt
Index: games/choria/patches/patch-CMakeLists_txt
===================================================================
RCS file: /cvs/openbsd/ports/games/choria/patches/patch-CMakeLists_txt,v
retrieving revision 1.3
diff -u -p -u -p -r1.3 patch-CMakeLists_txt
--- games/choria/patches/patch-CMakeLists_txt   25 Jan 2023 10:15:22 -0000      
1.3
+++ games/choria/patches/patch-CMakeLists_txt   2 Feb 2023 14:07:24 -0000
@@ -1,6 +1,15 @@
 Index: CMakeLists.txt
 --- CMakeLists.txt.orig
 +++ CMakeLists.txt
+@@ -34,7 +34,7 @@ if(NOT CMAKE_BUILD_TYPE)
+ endif()
+ 
+ # compiler flags
+-set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wno-unused-result 
-Wno-switch -Wno-unused-parameter -pedantic -std=c++17 -msse -mfpmath=sse")
++set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wno-unused-result 
-Wno-switch -Wno-unused-parameter -pedantic -std=c++17")
+ 
+ # Set gl preference
+ if(NOT DEFINED OpenGL_GL_PREFERENCE)
 @@ -132,7 +132,7 @@ if(EXISTS "${PROJECT_SOURCE_DIR}/assets/source/process
                list(APPEND DATA_SCRIPTS "${SCRIPT_OUTPUT}")
                add_custom_command(


-- 
We will have solar energy as soon as the utility companies solve one
technical problem -- how to run a sunbeam through a meter.

Reply via email to