git: e40c809bda64 - main - graphics/simpleviewer: update the port to the last 3.1.x release
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 17 Oct 2026 08:24:42 UTC
The branch main has been updated by danfe:
URL: https://cgit.FreeBSD.org/ports/commit/?id=e40c809bda6491ab238d6f6420d03eee3325d2f8
commit e40c809bda6491ab238d6f6420d03eee3325d2f8
Author: Alexey Dokuchaev <danfe@FreeBSD.org>
AuthorDate: 2026-10-17 08:23:06 +0000
Commit: Alexey Dokuchaev <danfe@FreeBSD.org>
CommitDate: 2026-10-17 08:23:06 +0000
graphics/simpleviewer: update the port to the last 3.1.x release
- The project had moved to GitHub, adjust WWW and Makefile logic
accordingly, shorten the COMMENT while here
- Regenerate `CMakeLists.txt' patch due to changes made upstream
(mostly cosmetic)
---
graphics/simpleviewer/Makefile | 23 ++++++-----
graphics/simpleviewer/distinfo | 6 +--
graphics/simpleviewer/files/patch-CMakeLists.txt | 51 ++++++++++--------------
graphics/simpleviewer/files/patch-src_main.cpp | 2 +-
4 files changed, 38 insertions(+), 44 deletions(-)
diff --git a/graphics/simpleviewer/Makefile b/graphics/simpleviewer/Makefile
index 72f8b1dd0e9f..88cca6f902d8 100644
--- a/graphics/simpleviewer/Makefile
+++ b/graphics/simpleviewer/Makefile
@@ -1,12 +1,11 @@
PORTNAME= simpleviewer
-PORTVERSION= 3.1.9
-PORTREVISION= 6
+PORTVERSION= 3.1.12
+DISTVERSIONPREFIX= v
CATEGORIES= graphics
-MASTER_SITES= https://bitbucket.org/andreyu/simple-viewer-gl/get/${BB_COMMIT}.tar.bz2?dummy=/
MAINTAINER= danfe@FreeBSD.org
-COMMENT= Small and simple image viewer based on OpenGL
-WWW= https://bitbucket.org/andreyu/simple-viewer-gl
+COMMENT= Small and simple OpenGL-based image viewer
+WWW= https://www.ugolnik.info/simple-viewer-gl/
LICENSE= GPLv2
@@ -15,16 +14,16 @@ LIB_DEPENDS= libfreetype.so:print/freetype2 \
liblz4.so:archivers/liblz4 \
libpng.so:graphics/png
-USES= cmake:insource compiler:c++11-lang gl jpeg pkgconfig \
+USES= cmake compiler:c++14-lang gl jpeg pkgconfig \
tar:bzip2 xorg
USE_GL= gl glu
USE_XORG= ice sm x11 xcursor xext xinerama xrandr xxf86vm
CMAKE_ARGS= -DAPP_VERSION_MAJOR:STRING=${PORTVERSION:S/./ /g:[1]} \
-DAPP_VERSION_MINOR:STRING=${PORTVERSION:S/./ /g:[2]} \
-DAPP_VERSION_RELEASE:STRING=${PORTVERSION:S/./ /g:[3]}
-
-BB_COMMIT= cded7dfe23c4
-WRKSRC= ${WRKDIR}/andreyu-simple-viewer-gl-${BB_COMMIT}
+USE_GITHUB= yes
+GH_ACCOUNT= reybits
+GH_PROJECT= simple-viewer-gl
PLIST_FILES= bin/sviewgl ${DATADIR_REL}/Icon-1024.png \
${DATADIR_REL}/Icon-16.png ${DATADIR_REL}/Icon-32.png
@@ -64,6 +63,10 @@ TIFF_CMAKE_OFF= -DDISABLE_TIFF_SUPPORT:STRING=1
WEBP_LIB_DEPENDS= libwebp.so:graphics/webp
WEBP_CMAKE_OFF= -DDISABLE_WEBP_SUPPORT:STRING=1
+post-extract:
+# Assert known number of optional features to catch unnoticed changes
+ ${TEST} $$(${GREP} -c '^if(.*FOUND)' ${WRKSRC}/CMakeLists.txt) = 24
+
post-patch:
@${REINPLACE_CMD} -e '/#include/s,lz4/,,' \
${WRKSRC}/src/formats/formatage.cpp
@@ -71,7 +74,7 @@ post-patch:
${WRKSRC}/src/main.cpp
do-install:
- ${INSTALL_PROGRAM} ${WRKSRC}/sviewgl ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_PROGRAM} ${INSTALL_WRKSRC}/sviewgl ${STAGEDIR}${PREFIX}/bin
@${MKDIR} ${STAGEDIR}${DATADIR}
${INSTALL_DATA} ${WRKSRC}/res/Icon-*.png ${STAGEDIR}${DATADIR}
diff --git a/graphics/simpleviewer/distinfo b/graphics/simpleviewer/distinfo
index 96fdff89baa5..5403308c0509 100644
--- a/graphics/simpleviewer/distinfo
+++ b/graphics/simpleviewer/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1671715617
-SHA256 (simpleviewer-3.1.9.tar.bz2) = be6ee4b6ffbd5b486168584cf8d9e9c28fd754469236764ce30cf7bd456a9c1c
-SIZE (simpleviewer-3.1.9.tar.bz2) = 1385056
+TIMESTAMP = 1716071599
+SHA256 (reybits-simple-viewer-gl-v3.1.12_GH0.tar.gz) = 251f26c3da05f32138177688ee07a0a4a4619521421ed6e4def71a8300f96e16
+SIZE (reybits-simple-viewer-gl-v3.1.12_GH0.tar.gz) = 4068553
diff --git a/graphics/simpleviewer/files/patch-CMakeLists.txt b/graphics/simpleviewer/files/patch-CMakeLists.txt
index 1a2cb795ef7a..0a432df04739 100644
--- a/graphics/simpleviewer/files/patch-CMakeLists.txt
+++ b/graphics/simpleviewer/files/patch-CMakeLists.txt
@@ -1,48 +1,39 @@
---- CMakeLists.txt.orig 2019-11-13 08:52:44 UTC
+--- CMakeLists.txt.orig 2024-05-18 22:33:19 UTC
+++ CMakeLists.txt
-@@ -27,7 +27,7 @@ message(STATUS "***************************")
+@@ -63,7 +63,7 @@ pretty_print("*" "*" "*" "*" "-")
if(CMAKE_BUILD_TYPE STREQUAL "Release")
- message(STATUS "* Release Build *")
+ pretty_print("*" "Release Build" "*" " " "-")
add_definitions("-DNDEBUG" )
- add_definitions("-Wall -Wextra -pedantic -pedantic-errors -Wno-unused-function -Wno-deprecated-register -O2")
+ add_definitions("-Wall -Wextra")
else()
- message(STATUS "* Debug Build *")
+ pretty_print("*" "Debug Build" "*" " " "-")
add_definitions("-DDEBUG" )
-@@ -250,7 +250,7 @@ set(DISABLE_OPENEXR_SUPPORT "0" CACHE STRING "Disable
+@@ -75,7 +75,6 @@ pretty_print("*" "*" "*" "*" "-")
+ find_package(PkgConfig REQUIRED)
+
+ add_subdirectory(third-party/imgui)
+-add_subdirectory(third-party/lz4)
+
+ # set(VERBOSE_PATHS TRUE)
+
+@@ -298,7 +297,7 @@ set(DISABLE_OPENEXR_SUPPORT "0" CACHE STRING "Disable
if (DISABLE_OPENEXR_SUPPORT EQUAL 0)
pkg_check_modules(OPENEXR QUIET OpenEXR)
if(OPENEXR_FOUND)
- pkg_check_modules(ILMBASE QUIET IlmBase)
+ pkg_check_modules(ILMBASE QUIET Imath)
if(ILMBASE_FOUND)
- message(STATUS "(+) OpenEXR support enabled")
+ pretty_print("* " "[+] OpenEXR support enabled" " *" " " "<")
if(VERBOSE_PATHS)
-@@ -261,7 +261,7 @@ if (DISABLE_OPENEXR_SUPPORT EQUAL 0)
- link_directories(${ILMBASE_LIBRARY_DIRS} ${OPENEXR_LIBRARY_DIRS})
- include_directories(${ILMBASE_INCLUDE_DIRS} ${OPENEXR_INCLUDE_DIRS})
- else()
-- message(STATUS "(-) ILMBase not found")
-+ message(STATUS "(-) Imath not found")
- endif()
- else()
- message(STATUS "(-) OpenEXR support dropped")
-@@ -316,7 +316,6 @@ endif()
- message(STATUS "***************************")
-
- add_subdirectory(third-party/imgui)
--add_subdirectory(third-party/lz4)
-
- include_directories("src")
-
-@@ -349,8 +348,8 @@ else()
- add_executable(sviewgl ${SVIEW_SOURCES})
+@@ -398,8 +397,8 @@ else()
+ add_executable(${APPLICATION_NAME} ${SVIEW_SOURCES})
endif()
--add_dependencies(sviewgl ImGui LZ4)
--target_link_libraries(sviewgl ImGui LZ4)
-+add_dependencies(sviewgl ImGui)
-+target_link_libraries(sviewgl ImGui lz4)
+-add_dependencies(${APPLICATION_NAME} ImGui LZ4)
+-target_link_libraries(${APPLICATION_NAME} ImGui LZ4)
++add_dependencies(${APPLICATION_NAME} ImGui)
++target_link_libraries(${APPLICATION_NAME} ImGui lz4)
if(OPENGL_FOUND)
- target_link_libraries(sviewgl ${OPENGL_LIBRARY})
+ target_link_libraries(${APPLICATION_NAME} ${OPENGL_LIBRARY})
diff --git a/graphics/simpleviewer/files/patch-src_main.cpp b/graphics/simpleviewer/files/patch-src_main.cpp
index ec12652d70d3..72c28e9897b1 100644
--- a/graphics/simpleviewer/files/patch-src_main.cpp
+++ b/graphics/simpleviewer/files/patch-src_main.cpp
@@ -70,7 +70,7 @@
+ fclose(fp);
+ }
+
- void setup(GLFWwindow* window)
+ void setContext(GLFWwindow* window)
{
glfwMakeContextCurrent(window);
@@ -173,6 +232,18 @@ namespace