- Unbreak by fixing the FindOpenJPEG CMake module

Reported by:    ph (via pav)
This commit is contained in:
Pietro Cerutti 2012-06-14 12:03:43 +00:00
parent 266aab05ce
commit 1baec24370
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=299255
2 changed files with 21 additions and 10 deletions

View file

@ -16,8 +16,6 @@ COMMENT= Grassroots DICOM library
LIB_DEPENDS= openjpeg.2:${PORTSDIR}/graphics/openjpeg \
expat.6:${PORTSDIR}/textproc/expat2
BROKEN= does not compile
OPTIONS= VTK "Build the VTK bindings" off
USE_BZIP2= yes
@ -26,11 +24,16 @@ USE_OPENSSL= yes
USE_LDCONFIG= ${PREFIX}/lib \
${PREFIX}/lib/gdcm-${GDCM_MAJ}
CFLAGS+= -I${LOCALBASE}/include
CMAKE_OUTSOURCE=yes
CMAKE_ARGS+= -DGDCM_PDF_DOCUMENTATION:BOOL=NO \
-DGDCM_USE_SYSTEM_OPENSSL:BOOL=YES \
-DGDCM_USE_SYSTEM_EXPAT:BOOL=YES \
-DGDCM_USE_SYSTEM_OPENJPEG:BOOL=YES \
-DGDCM_USE_SYSTEM_ZLIB:BOOL=YES
-DGDCM_USE_SYSTEM_ZLIB:BOOL=YES \
-DGDCM_BUILD_APPLICATIONS:BOOL=YES \
-DGDCM_BUILD_SHARED_LIBS:BOOL=YES \
-DGDCM_BUILD_EXAMPLES:BOOL=NO \
-DGDCM_INSTALL_DATA_DIR:STRING=${DATADIR}
.include <bsd.port.options.mk>
@ -50,13 +53,6 @@ PLIST_SUB+= GDCM_MAJ="${GDCM_MAJ}" \
GDCM_MIN="${GDCM_MIN}" \
GDCM_SO="${GDCM_SO}"
CMAKE_OUTSOURCE=yes
CMAKE_ARGS+= -DGDCM_BUILD_APPLICATIONS:BOOL=YES \
-DGDCM_BUILD_SHARED_LIBS:BOOL=YES \
-DGDCM_BUILD_EXAMPLES:BOOL=NO \
-DGDCM_INSTALL_DATA_DIR:STRING=${DATADIR} \
-DGDCM_USE_SYSTEM_OPENJPEG:BOOL=YES
.if !defined(NOPORTDOCS)
BUILD_DEPENDS+= doxygen:${PORTSDIR}/devel/doxygen \
pdflatex:${PORTSDIR}/print/teTeX-base

View file

@ -0,0 +1,15 @@
--- CMake/FindOpenJPEG.cmake.orig 2012-06-14 12:47:50.000000000 +0200
+++ CMake/FindOpenJPEG.cmake 2012-06-14 12:47:59.000000000 +0200
@@ -21,7 +21,6 @@
# Try first to locate a cmake config file
FIND_PACKAGE(OpenJPEG QUIET NO_MODULE)
-if( NOT OpenJPEG_DIR )
SET(OPENJPEG_MAJOR_VERSION 1) # FIXME ?
FIND_PATH(OPENJPEG_INCLUDE_DIR
NAMES openjpeg.h #openjpeg-1.0/openjpeg.h
@@ -50,4 +49,3 @@
OPENJPEG_LIBRARY
OPENJPEG_INCLUDE_DIR
)
-endif()