diff options
author | Vladimir Druzenko <vvd@FreeBSD.org> | 2024-06-02 10:52:40 +0000 |
---|---|---|
committer | Vladimir Druzenko <vvd@FreeBSD.org> | 2024-06-02 11:09:31 +0000 |
commit | d6b1bdaf042ee04786083b137b9c441888eb1d0f (patch) | |
tree | e729c3b08cb54bf4d27bfd7ccc156fa23e7cda42 | |
parent | 559b574607a969d99ef4aa1d2f3ce464a8f15950 (diff) | |
download | ports-d6b1bdaf042ee04786083b137b9c441888eb1d0f.tar.gz ports-d6b1bdaf042ee04786083b137b9c441888eb1d0f.zip |
graphics/{,py-}openimageio: sort out Makefile, remove unnecessary dependencies and pet portclippy
- Add VDB_IMPLIES=TBB: OpenVDB require TBB - build warning:
"Not using OpenVDB -- disabled (because TBB was not found)"
- Remove unused dependencies science/hdf5 and graphics/squish.
- Move devel/libfmt and graphics/libjpeg-turbo to BUILD_DEPENDS and
RUN_DEPENDS: check during configure stage and doesn't link this both.
- Force use devel/libfmt and textproc/pugixml from ports and prevent
use embedded copies.
- Remove GL=glew from IMAGEVIEWER - it doesn't link with libGLEW.
- Remove old and removed by upstream CMAKE options NOTHREADS,
USE_OPENSSL, USE_OPENGL.
- Sort options.
PR: 279454
Approved by: Shane <FreeBSD@ShaneWare.Biz> (maintainer)
-rw-r--r-- | graphics/openimageio/Makefile | 86 | ||||
-rw-r--r-- | graphics/openimageio/pkg-plist | 6 | ||||
-rw-r--r-- | graphics/py-openimageio/Makefile | 4 |
3 files changed, 46 insertions, 50 deletions
diff --git a/graphics/openimageio/Makefile b/graphics/openimageio/Makefile index f262d2b29ef5..2ad927eeff66 100644 --- a/graphics/openimageio/Makefile +++ b/graphics/openimageio/Makefile @@ -5,7 +5,7 @@ DISTVERSION= 2.5.8.0 # py-openimageio's PORTREVISION. # Also, just to be on the safe side, when resetting, # best keep PORTREVISION?= 0. -PORTREVISION?= 0 +PORTREVISION?= 1 CATEGORIES?= graphics multimedia MAINTAINER?= FreeBSD@Shaneware.biz @@ -14,19 +14,20 @@ WWW= https://www.openimageio.org/ LICENSE= BSD3CLAUSE -BUILD_DEPENDS= ${LOCALBASE}/include/tsl/robin_map.h:devel/robin-map +BUILD_DEPENDS= ${LOCALBASE}/include/tsl/robin_map.h:devel/robin-map \ + libfmt>10.0.0:devel/libfmt \ + libjpeg-turbo>3.0.0:graphics/libjpeg-turbo LIB_DEPENDS= libboost_thread.so:devel/boost-libs \ - libfmt.so:devel/libfmt \ - libhdf5.so:science/hdf5 \ libImath.so:math/Imath \ libOpenColorIO.so:graphics/opencolorio \ libOpenEXR.so:graphics/openexr \ libheif.so:graphics/libheif \ - libturbojpeg.so:graphics/libjpeg-turbo \ libpng.so:graphics/png \ - libsquish.so:graphics/squish \ + libpugixml.so:textproc/pugixml \ libtiff.so:graphics/tiff \ libwebp.so:graphics/webp +RUN_DEPENDS= libfmt>10.0.0:devel/libfmt \ + libjpeg-turbo>3.0.0:graphics/libjpeg-turbo USES= cmake jpeg compiler:c++17-lang iconv:wchar_t @@ -37,70 +38,72 @@ GH_PROJECT= OpenImageIO CMAKE_ARGS= -DCMAKE_CXX_STANDARD:INTEGER=17 # OpenVDB uses the C++17 STL # feature std::tuple_size_v; since the slave port py-openimageio excludes # options - this is a global line here -CMAKE_OFF= BUILDSTATIC INSTALL_FONTS LINKSTATIC NOTHREADS \ - STOP_ON_WARNING USE_OPENSSL OIIO_DOWNLOAD_MISSING_TESTDATA \ - USE_Package +CMAKE_ON= BUILD_SHARED_LIBS USE_EXTERNAL_PUGIXML +CMAKE_OFF= BUILD_FMT_FORCE BUILD_MISSING_FMT INSTALL_FONTS INTERNALIZE_FMT \ + LINKSTATIC OIIO_DOWNLOAD_MISSING_TESTDATA OIIO_USING_FMT_LOCAL \ + STOP_ON_WARNING + +SHL1= ${PORTVERSION:R:R:R} +SHL2= ${PORTVERSION:R:R} +SHL3= ${PORTVERSION:R} +PLIST_SUB= SHL1=${SHL1} SHL2=${SHL2} SHL3=${SHL3} OPTIONS_DEFINE= DICOM DOCS FFMPEG FREETYPE GIF IMAGEVIEWER \ OPENCV OPENJPEG PTEX RAW TBB TEST TOOLS VDB -OPTIONS_DEFAULT= DICOM FREETYPE GIF OPENJPEG PTEX TOOLS VDB +OPTIONS_DEFAULT= DICOM FREETYPE GIF OPENJPEG PTEX TBB TOOLS VDB OPTIONS_SUB= yes -DOCS_CMAKE_BOOL= INSTALL_DOCS -DOCS_CMAKE_ON= -DCMAKE_INSTALL_DOCDIR:STRING=${DOCSDIR} - DICOM_DESC= DICOM/MEDICOM support -DICOM_CMAKE_BOOL= USE_DICOM +FFMPEG_DESC= Use FFmpeg to support extra file types +IMAGEVIEWER_DESC= Build image viewer (requires Qt) +PTEX_DESC= ptex support +TBB_DESC= Intel tbb support +TOOLS_DESC= Build CLI tools +VDB_DESC= OpenVDB support + DICOM_LIB_DEPENDS= libdcmimage.so:graphics/dcmtk +DICOM_CMAKE_BOOL= USE_DICOM + +DOCS_CMAKE_BOOL= INSTALL_DOCS +DOCS_CMAKE_ON= -DCMAKE_INSTALL_DOCDIR:STRING=${DOCSDIR} -FFMPEG_DESC= Use FFmpeg to support extra file types -FFMPEG_CMAKE_BOOL= USE_FFMPEG FFMPEG_LIB_DEPENDS= libavutil.so:multimedia/ffmpeg +FFMPEG_CMAKE_BOOL= USE_FFMPEG -FREETYPE_CMAKE_BOOL= USE_FREETYPE FREETYPE_LIB_DEPENDS= libfreetype.so:print/freetype2 FREETYPE_RUN_DEPENDS= ${LOCALBASE}/share/fonts/Droid/DroidSans.ttf:x11-fonts/droid-fonts-ttf +FREETYPE_CMAKE_BOOL= USE_FREETYPE -GIF_CMAKE_BOOL= USE_GIF GIF_LIB_DEPENDS= libgif.so:graphics/giflib +GIF_CMAKE_BOOL= USE_GIF -IMAGEVIEWER_DESC= Build image viewer (requires Qt) -IMAGEVIEWER_USES= gl qt:6 IMAGEVIEWER_IMPLIES= TOOLS -IMAGEVIEWER_CMAKE_BOOL= USE_OPENGL USE_QT -IMAGEVIEWER_USE= GL=gl,glu,glew QT=base +IMAGEVIEWER_USES= gl qt:6 +IMAGEVIEWER_USE= GL=gl,glu QT=base +IMAGEVIEWER_CMAKE_BOOL= USE_QT -OPENCV_CMAKE_BOOL= USE_OPENCV OPENCV_IMPLIES= OPENJPEG -OPENCV_LIB_DEPENDS= libopencv_highgui.so:graphics/opencv \ - libopencv_core.so:graphics/opencv +OPENCV_LIB_DEPENDS= libopencv_core.so:graphics/opencv +OPENCV_CMAKE_BOOL= USE_OPENCV -OPENJPEG_CMAKE_BOOL= USE_OPENJPEG OPENJPEG_LIB_DEPENDS= libopenjp2.so:graphics/openjpeg +OPENJPEG_CMAKE_BOOL= USE_OPENJPEG -PTEX_DESC= ptex support PTEX_LIB_DEPENDS= libPtex.so:graphics/ptex -RAW_CMAKE_BOOL= USE_LIBRAW RAW_LIB_DEPENDS= libraw_r.so:graphics/libraw +RAW_CMAKE_BOOL= USE_LIBRAW -TBB_DESC= Intel tbb support -TBB_CMAKE_BOOL= USE_TBB TBB_LIB_DEPENDS= libtbb.so:devel/onetbb +TBB_CMAKE_BOOL= USE_TBB TEST_CMAKE_BOOL= OIIO_BUILD_TESTS -TOOLS_DESC= Build CLI tools TOOLS_CMAKE_BOOL= OIIO_BUILD_TOOLS -VDB_DESC= OpenVDB support -VDB_CMAKE_BOOL= USE_OPENVDB +VDB_IMPLIES= TBB VDB_LIB_DEPENDS= libopenvdb.so:misc/openvdb - -PLIST_SUB= SHL3=${PORTVERSION:R} SHL2=${PORTVERSION:R:R} SHL1=${PORTVERSION:R:R:R} -SHL3= ${PORTVERSION:R} -SHL2= ${PORTVERSION:R:R} -SHL1= ${PORTVERSION:R:R:R} +VDB_CMAKE_BOOL= USE_OPENVDB post-patch: @${REINPLACE_CMD} -e "s,%%LOCALBASE%%,${LOCALBASE}," \ @@ -111,14 +114,13 @@ post-patch: .if ${SLAVE_PORT} == yes BUILD_DEPENDS+= ${PREFIX}/share/cmake/pybind11/pybind11Config.cmake:devel/pybind11 LIB_DEPENDS+= libOpenImageIO.so:graphics/openimageio -PLIST= ${PKGDIR}/pkg-plist-pybind USES+= python USE_PYTHON= flavors +CMAKE_ARGS+= -DPYTHON_VERSION:STRING=${PYTHON_VER} CMAKE_ON+= USE_PYTHON # we don't need the apps built - only libs. -CMAKE_OFF+= USE_QT USE_OPENGL OIIO_BUILD_TOOLS OIIO_BUILD_TESTS \ - EMBED_PLUGINS -CMAKE_ARGS+= -DPYTHON_VERSION:STRING=${PYTHON_VER} +CMAKE_OFF+= EMBED_PLUGINS OIIO_BUILD_TESTS OIIO_BUILD_TOOLS USE_DICOM USE_FFMPEG USE_FREETYPE USE_GIF USE_LIBRAW USE_OPENCV USE_OPENJPEG USE_OPENVDB USE_QT USE_TBB +PLIST= ${PKGDIR}/pkg-plist-pybind do-install: ${MKDIR} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} diff --git a/graphics/openimageio/pkg-plist b/graphics/openimageio/pkg-plist index 1b159cfef4e7..485484f2231f 100644 --- a/graphics/openimageio/pkg-plist +++ b/graphics/openimageio/pkg-plist @@ -15,17 +15,11 @@ include/OpenImageIO/color.h include/OpenImageIO/dassert.h include/OpenImageIO/deepdata.h include/OpenImageIO/detail/farmhash.h -include/OpenImageIO/detail/fmt/chrono.h -include/OpenImageIO/detail/fmt/core.h -include/OpenImageIO/detail/fmt/format-inl.h include/OpenImageIO/detail/fmt/format.h include/OpenImageIO/detail/fmt/ostream.h include/OpenImageIO/detail/fmt/printf.h include/OpenImageIO/detail/fmt/std.h include/OpenImageIO/detail/fmt.h -include/OpenImageIO/detail/pugixml/pugiconfig.hpp -include/OpenImageIO/detail/pugixml/pugixml.cpp -include/OpenImageIO/detail/pugixml/pugixml.hpp include/OpenImageIO/errorhandler.h include/OpenImageIO/export.h include/OpenImageIO/filesystem.h diff --git a/graphics/py-openimageio/Makefile b/graphics/py-openimageio/Makefile index 1e173e9fc75f..5327113c05b0 100644 --- a/graphics/py-openimageio/Makefile +++ b/graphics/py-openimageio/Makefile @@ -1,10 +1,10 @@ -PORTREVISION= 0 +PORTREVISION= 1 CATEGORIES= graphics multimedia python PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} COMMENT= OpenImageIO python bindings MASTERDIR= ${.CURDIR}/../openimageio -OPTIONS_EXCLUDE=${OPTIONS_DEFINE} +OPTIONS_EXCLUDE= ${OPTIONS_DEFINE} .include "${MASTERDIR}/Makefile" |