diff --git a/science/orthanc/Makefile b/science/orthanc/Makefile index e2760ebdd218..aea16f8b7f97 100644 --- a/science/orthanc/Makefile +++ b/science/orthanc/Makefile @@ -1,63 +1,57 @@ PORTNAME= orthanc -DISTVERSION= 1.12.6 -PORTREVISION= 4 +DISTVERSION= 1.12.9 CATEGORIES= science MASTER_SITES= https://orthanc.uclouvain.be/downloads/sources/orthanc/ DISTNAME= Orthanc-${PORTVERSION} MAINTAINER= maintainer.freebsd@xpoundit.com COMMENT= Lightweight DICOM server for healthcare and medical research WWW= https://www.orthanc-server.com/ LICENSE= GPLv3 LICENSE_FILE= ${WRKSRC}/COPYING -BUILD_DEPENDS= protoc:devel/protobuf - +BUILD_DEPENDS= protoc:devel/protobuf \ + googletest>0:devel/googletest LIB_DEPENDS= libboost_atomic.so:devel/boost-libs \ libcivetweb.so:www/civetweb \ libcurl.so:ftp/curl \ libdcmtkcharls.so:graphics/dcmtk \ - libgtest.so:devel/googletest \ - libicuuc.so:devel/icu \ libjsoncpp.so:devel/jsoncpp \ libpng16.so:graphics/png \ libprotobuf.so:devel/protobuf \ libpugixml.so:textproc/pugixml \ - libtiff.so:graphics/tiff \ libuuid.so:misc/libuuid USES= cmake gnome iconv jpeg lua python:build sqlite ssl -USE_GNOME= libxml2 -USE_LDCONFIG= yes USE_RC_SUBR= orthanc # Keep in sync with graphics/dcmtk version CMAKE_ARGS= -DDCMTK_DICTIONARY_DIR:STRING=${LOCALBASE}/share/dcmtk-3.6.9 CMAKE_ON= USE_SYSTEM_BOOST USE_SYSTEM_CIVETWEB USE_SYSTEM_DCMTK \ USE_SYSTEM_GOOGLE_TEST USE_SYSTEM_JSONCPP USE_SYSTEM_LIBICONV \ USE_SYSTEM_LIBJPEG USE_SYSTEM_LIBPNG USE_SYSTEM_LUA \ USE_SYSTEM_OPENSSL USE_SYSTEM_PUGIXML USE_SYSTEM_SQLITE \ USE_SYSTEM_UUID USE_SYSTEM_ZLIB CMAKE_OFF= BUILD_CONNECTIVITY_CHECKS UNIT_TESTS_WITH_HTTP_CONNEXIONS CMAKE_SOURCE_PATH= ${WRKSRC}/OrthancServer CFLAGS+= -DNDEBUG CXXFLAGS+= -DNDEBUG WRKSRC= ${WRKDIR}/Orthanc-${PORTVERSION} USERS= orthanc GROUPS= orthanc PLIST_SUB+= DISTVERSION=${DISTVERSION} post-install: ${MKDIR} ${STAGEDIR}/var/db/orthanc/db/db-v5 ${MKDIR} ${STAGEDIR}${DATADIR}/plugins ${MKDIR} ${STAGEDIR}${ETCDIR} ${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' ${CMAKE_SOURCE_PATH}/Resources/Configuration.json ${CP} ${CMAKE_SOURCE_PATH}/Resources/Configuration.json ${STAGEDIR}${ETCDIR}/orthanc.json.sample .include diff --git a/science/orthanc/distinfo b/science/orthanc/distinfo index 2498469be620..d57475212b4a 100644 --- a/science/orthanc/distinfo +++ b/science/orthanc/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1739138261 -SHA256 (Orthanc-1.12.6.tar.gz) = aa5b6d6309965ed360625b5572e79068e6c501b603163e330629f2f0a56a0fe9 -SIZE (Orthanc-1.12.6.tar.gz) = 2089779 +TIMESTAMP = 1761178767 +SHA256 (Orthanc-1.12.9.tar.gz) = 7a7cbc5f3663939fbef31ded021b36fcd52420337911ed43491bb663bcb5a4b2 +SIZE (Orthanc-1.12.9.tar.gz) = 2165182 diff --git a/science/orthanc/files/orthanc.in b/science/orthanc/files/orthanc.in index 85d6af45d8a1..9cbe3d1cd321 100644 --- a/science/orthanc/files/orthanc.in +++ b/science/orthanc/files/orthanc.in @@ -1,40 +1,40 @@ #!/bin/sh # $FreeBSD$ # # PROVIDE: orthanc # REQUIRE: LOGIN # KEYWORD: shutdown # # Add these lines to /etc/rc.conf.local or /etc/rc.conf # to enable this service: # # orthanc_enable (bool): Set to NO by default. # Set it to YES to enable Orthanc. # orthanc_flags (str): Set to %%ETCDIR%%/orthanc.json # by default. . /etc/rc.subr name=orthanc rcvar=orthanc_enable desc="Lightweight DICOM server for healthcare and medical research" load_rc_config $name : ${orthanc_enable:=NO} -: ${orthanc_flags="%%ETCDIR%%/orthanc.json"} +: ${orthanc_config="%%ETCDIR%%/orthanc.json"} start_precmd=orthanc_prestart pidfile=/var/run/orthanc.pid procname=%%PREFIX%%/sbin/Orthanc command=/usr/sbin/daemon -command_args=" -f -p ${pidfile} -u orthanc ${procname} ${orthanc_flags}" +command_args=" --output-file /var/log/orthanc --sighup --child-pidfile ${pidfile} --user orthanc ${procname} ${orthanc_flags} ${orthanc_config}" orthanc_prestart() { # Have to empty rc_flags so they don't get passed to daemon(8) rc_flags="" } run_rc_command "$1" diff --git a/science/orthanc/files/patch-OrthancFramework_Sources_Images_JpegWriter.cpp b/science/orthanc/files/patch-OrthancFramework_Sources_Images_JpegWriter.cpp deleted file mode 100644 index 59b845085092..000000000000 --- a/science/orthanc/files/patch-OrthancFramework_Sources_Images_JpegWriter.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- OrthancFramework/Sources/Images/JpegWriter.cpp.orig 2024-12-17 16:33:40 UTC -+++ OrthancFramework/Sources/Images/JpegWriter.cpp -@@ -187,7 +187,7 @@ namespace Orthanc - **/ - unsigned long size; - #else -- size_t size; -+ unsigned long size; - #endif - - if (setjmp(jerr.GetJumpBuffer())) diff --git a/science/orthanc/files/patch-OrthancServer_Resources_Configuration.json b/science/orthanc/files/patch-OrthancServer_Resources_Configuration.json index f6b4af632e2e..212fadfde386 100644 --- a/science/orthanc/files/patch-OrthancServer_Resources_Configuration.json +++ b/science/orthanc/files/patch-OrthancServer_Resources_Configuration.json @@ -1,25 +1,25 @@ --- OrthancServer/Resources/Configuration.json.orig 2024-12-17 16:33:40 UTC +++ OrthancServer/Resources/Configuration.json @@ -15,12 +15,12 @@ // Path to the directory that holds the heavyweight files (i.e. the // raw DICOM instances). Backslashes must be either escaped by // doubling them, or replaced by forward slashes "/". - "StorageDirectory" : "OrthancStorage", -+ "StorageDirectory" : "/var/db/orthanc/db-v5", ++ "StorageDirectory" : "/var/db/orthanc/db/db-v5", // Path to the directory that holds the SQLite index (if unset, the // value of StorageDirectory is used). This index could be stored on // a RAM-drive or a SSD device for performance reasons. - "IndexDirectory" : "OrthancStorage", -+ "IndexDirectory" : "/var/db/orthanc/db-v5", ++ "IndexDirectory" : "/var/db/orthanc/db/db-v5", // Path to the directory where Orthanc stores its large temporary // files. The content of this folder can be safely deleted once @@ -85,6 +85,7 @@ // find shared libraries. Backslashes must be either escaped by // doubling them, or replaced by forward slashes "/". "Plugins" : [ + "%%PREFIX%%/share/orthanc/plugins/" ], // Maximum number of processing jobs that are simultaneously running diff --git a/science/orthanc/files/patch-OrthancServer_Sources_Database_PrepareDatabase.sql b/science/orthanc/files/patch-OrthancServer_Sources_Database_PrepareDatabase.sql new file mode 100644 index 000000000000..ffe19920c2b0 --- /dev/null +++ b/science/orthanc/files/patch-OrthancServer_Sources_Database_PrepareDatabase.sql @@ -0,0 +1,13 @@ +--- OrthancServer/Sources/Database/PrepareDatabase.sql.orig 2025-08-11 16:02:50 UTC ++++ OrthancServer/Sources/Database/PrepareDatabase.sql +@@ -160,4 +160,9 @@ -- The "1" corresponds to the "GlobalProperty_Database + + -- Set the version of the database schema + -- The "1" corresponds to the "GlobalProperty_DatabaseSchemaVersion" enumeration +-INSERT INTO GlobalProperties VALUES (1, "6"); ++-- Upstream code has (1, "6"), which causes startup to fail on FreeBSD ++-- E1023 08:43:05.328003 MAIN Connection.cpp:169] SQLite execute error: no such column: "6" - should this be a string literal in single-quotes? (1) ++-- Apparently due to sqlite 3.41+ being stricter about string literals ++-- Debian packages currently uses 3.34 ++-- https://orthanc.uclouvain.be/bugs/show_bug.cgi?id=227 ++INSERT INTO GlobalProperties VALUES (1, 6);