diff --git a/science/orthanc-postgresql/Makefile b/science/orthanc-postgresql/Makefile new file mode 100644 index 000000000000..35ce3e0c651c --- /dev/null +++ b/science/orthanc-postgresql/Makefile @@ -0,0 +1,47 @@ +# Created by: maintainer.freebsd@xpoundit.com + +PORTNAME= orthanc-postgresql +DISTVERSION= 4.0 +CATEGORIES= science +MASTER_SITES= https://www.orthanc-server.com/downloads/get.php?path=/plugin-postgresql/:main \ + https://www.orthanc-server.com/downloads/get.php?path=/orthanc/:framework \ + https://orthanc.osimis.io/ThirdPartyDownloads/:thirdparty +DISTFILES= OrthancPostgreSQL-${PORTVERSION}.tar.gz:main \ + Orthanc-1.9.3.tar.gz:framework \ + e2fsprogs-1.44.5.tar.gz:thirdparty +DIST_SUBDIR= orthanc +EXTRACT_ONLY= OrthancPostgreSQL-${PORTVERSION}.tar.gz + +MAINTAINER= maintainer.freebsd@xpoundit.com +COMMENT= Orthanc plugin to use PostgreSQL for indexing or storage + +LICENSE= AGPLv3 +LICENSE_FILE= ${WRKSRC}/COPYING + +BUILD_DEPENDS= ${LOCALBASE}/include/orthanc/OrthancCDatabasePlugin.h:science/orthanc +LIB_DEPENDS= libboost_filesystem.so:devel/boost-libs \ + libgdcmCommon.so:devel/gdcm \ + libjsoncpp.so:devel/jsoncpp \ + libpugixml.so:textproc/pugixml +RUN_DEPENDS= Orthanc:science/orthanc + +USES= cmake localbase pgsql:11+ python:build ssl +USE_LDCONFIG= yes + +WRKSRC= ${WRKDIR}/OrthancPostgreSQL-${PORTVERSION} + +CMAKE_SOURCE_PATH= ${WRKSRC}/PostgreSQL +CMAKE_OFF= BUILD_UNIT_TESTS USE_SYSTEM_ORTHANC_SDK USE_SYSTEM_UUID +CMAKE_ARGS= -DORTHANC_FRAMEWORK_ROOT=${WRKSRC}/PostgreSQL/ThirdPartyDownloads/Orthanc-1.9.3/OrthancFramework/Sources \ + -DORTHANC_FRAMEWORK_SOURCE=path +CXXFLAGS+= -I${LOCALBASE}/include -DNDEBUG +LDFLAGS+= -L${LOCALBASE}/lib +CFLAGS+= -DORTHANC_ENABLE_LOGGING_PLUGIN -DNDEBUG + +post-extract: + ${MKDIR} ${WRKSRC}/PostgreSQL/ThirdPartyDownloads + ${CP} ${DISTDIR}/${DIST_SUBDIR}/e2fsprogs-1.44.5.tar.gz ${WRKSRC}/PostgreSQL/ThirdPartyDownloads + ${CP} ${DISTDIR}/${DIST_SUBDIR}/Orthanc-1.9.3.tar.gz ${WRKSRC}/PostgreSQL/ThirdPartyDownloads + ${TAR} -C ${WRKSRC}/PostgreSQL/ThirdPartyDownloads -xf ${WRKSRC}/PostgreSQL/ThirdPartyDownloads/Orthanc-1.9.3.tar.gz + +.include diff --git a/science/orthanc-postgresql/distinfo b/science/orthanc-postgresql/distinfo new file mode 100644 index 000000000000..a438656c3e1d --- /dev/null +++ b/science/orthanc-postgresql/distinfo @@ -0,0 +1,7 @@ +TIMESTAMP = 1620906912 +SHA256 (orthanc/OrthancPostgreSQL-4.0.tar.gz) = a5049ed8a5d6bb8b6529636cf1d9f631d1b61f6e0bbfdc6accae45aded42bac5 +SIZE (orthanc/OrthancPostgreSQL-4.0.tar.gz) = 318047 +SHA256 (orthanc/Orthanc-1.9.3.tar.gz) = 41cc35a3d15ecb0d7b834e8e28a740cc4ffa1f333c019a764228d60e96608960 +SIZE (orthanc/Orthanc-1.9.3.tar.gz) = 1818313 +SHA256 (orthanc/e2fsprogs-1.44.5.tar.gz) = 2e211fae27ef74d5af4a4e40b10b8df7f87c655933bd171aab4889bfc4e6d1cc +SIZE (orthanc/e2fsprogs-1.44.5.tar.gz) = 7619237 diff --git a/science/orthanc-postgresql/files/patch-PostgreSQL_CMakeLists.txt b/science/orthanc-postgresql/files/patch-PostgreSQL_CMakeLists.txt new file mode 100644 index 000000000000..389ee26f4b28 --- /dev/null +++ b/science/orthanc-postgresql/files/patch-PostgreSQL_CMakeLists.txt @@ -0,0 +1,12 @@ +--- PostgreSQL/CMakeLists.txt.orig 2021-05-17 12:24:06 UTC ++++ PostgreSQL/CMakeLists.txt +@@ -23,6 +23,9 @@ set(OPENSSL_STATIC_VERSION "1.1.1" CACHE STRING "Force + + include(${CMAKE_SOURCE_DIR}/../Resources/CMake/DatabasesPluginConfiguration.cmake) + ++set(CMAKE_CXX_STANDARD 11) ++set(CMAKE_CXX_STANDARD_REQUIRED ON) ++set(CMAKE_CXX_EXTENSIONS OFF) + + if (${CMAKE_SYSTEM_NAME} STREQUAL "Windows") + execute_process( diff --git a/science/orthanc-postgresql/pkg-descr b/science/orthanc-postgresql/pkg-descr new file mode 100644 index 000000000000..50adcae692c8 --- /dev/null +++ b/science/orthanc-postgresql/pkg-descr @@ -0,0 +1,4 @@ +Orthanc can be extended with two plugins that replace the default SQLite +engine of Orthanc with a PostgreSQL back-end. + +WWW: https://www.orthanc-server.com/static.php?page=postgresql diff --git a/science/orthanc-postgresql/pkg-plist b/science/orthanc-postgresql/pkg-plist new file mode 100644 index 000000000000..c28eabfc4d2d --- /dev/null +++ b/science/orthanc-postgresql/pkg-plist @@ -0,0 +1,4 @@ +share/orthanc/plugins/libOrthancPostgreSQLIndex.so +share/orthanc/plugins/libOrthancPostgreSQLIndex.so.4.0 +share/orthanc/plugins/libOrthancPostgreSQLStorage.so +share/orthanc/plugins/libOrthancPostgreSQLStorage.so.4.0