git: 167f75b07993 - main - graphics/maim: Fix build with ICU 76+
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 25 Jan 2025 17:32:28 UTC
The branch main has been updated by diizzy:
URL: https://cgit.FreeBSD.org/ports/commit/?id=167f75b0799322f55c0208061c578e8e104f951e
commit 167f75b0799322f55c0208061c578e8e104f951e
Author: Daniel Engberg <diizzy@FreeBSD.org>
AuthorDate: 2025-01-25 16:16:49 +0000
Commit: Daniel Engberg <diizzy@FreeBSD.org>
CommitDate: 2025-01-25 17:31:49 +0000
graphics/maim: Fix build with ICU 76+
* Bump C++ version to c++17
* Adjust CMake build script to include all required ICU libraries
PR: 278420
Approved by: portmgr (blanket, build fix)
---
graphics/maim/Makefile | 2 +-
graphics/maim/files/patch-CMakeLists.txt | 27 +++++++++++++++++++++++++++
2 files changed, 28 insertions(+), 1 deletion(-)
diff --git a/graphics/maim/Makefile b/graphics/maim/Makefile
index 28799252ca1b..42527c44d114 100644
--- a/graphics/maim/Makefile
+++ b/graphics/maim/Makefile
@@ -16,7 +16,7 @@ LIB_DEPENDS= libicuuc.so:devel/icu \
libslopy.so:x11/slop \
libwebp.so:graphics/webp
-USES= cmake compiler:c++11-lang gl jpeg xorg
+USES= cmake compiler:c++17-lang gl jpeg xorg
USE_GITHUB= yes
GH_ACCOUNT= naelstrof
USE_GL= gl
diff --git a/graphics/maim/files/patch-CMakeLists.txt b/graphics/maim/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..be0a132e6b0f
--- /dev/null
+++ b/graphics/maim/files/patch-CMakeLists.txt
@@ -0,0 +1,27 @@
+--- CMakeLists.txt.orig 2025-01-25 11:05:57 UTC
++++ CMakeLists.txt
+@@ -38,7 +38,7 @@ set_property(TARGET ${BIN_TARGET} PROPERTY CXX_STANDAR
+ find_package( GLM REQUIRED )
+
+ set_property(TARGET ${BIN_TARGET} PROPERTY CXX_STANDARD_REQUIRED ON)
+-set_property(TARGET ${BIN_TARGET} PROPERTY CXX_STANDARD 11)
++set_property(TARGET ${BIN_TARGET} PROPERTY CXX_STANDARD 17)
+ set_property(TARGET ${BIN_TARGET} PROPERTY CXX_EXTENSIONS OFF)
+
+ # Includes
+@@ -70,13 +70,13 @@ else()
+ if( ${CMAKE_VERSION} VERSION_LESS 3.7 )
+ message( WARNING "CMake version is below 3.7, CMake version >= 3.7 is required for unicode support." )
+ else()
+- find_package(ICU COMPONENTS uc)
++ find_package(ICU COMPONENTS i18n uc)
+ set( MAIM_UNICODE TRUE CACHE BOOL "To enable or disable unicode support." )
+ if ( MAIM_UNICODE AND ICU_FOUND )
+ # ICU is required for old nvidia drivers to work for whatever reason.
+ add_definitions(-DCXXOPTS_USE_UNICODE)
+ include_directories( ${ICU_INCLUDE_DIR} )
+- target_link_libraries( ${BIN_TARGET} ${ICU_UC_LIBRARIES} )
++ target_link_libraries( ${BIN_TARGET} ${ICU_I18N_LIBRARIES} ${ICU_UC_LIBRARIES} )
+ endif()
+ endif()
+