Upgrade to CImg.1.0.7 version (pre-release).

This commit is contained in:
Thierry Thomas 2004-10-20 20:54:08 +00:00
parent 2d6723f827
commit f1652585f6
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=119876
6 changed files with 49 additions and 311 deletions

View File

@ -6,7 +6,7 @@
#
PORTNAME= cimg
PORTVERSION= 1.0.6
PORTVERSION= 1.0.7
CATEGORIES= graphics devel
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
@ -17,6 +17,7 @@ MAINTAINER= thierry@FreeBSD.org
COMMENT= The C++ Template Image Processing Library
USE_ZIP= yes
BUILD_WRKSRC= ${WRKSRC}/examples
MAKE_ENV= CPPFLAGS="${CFLAGS} ${LAPACK_DEF} ${PTHREAD_CFLAGS}" \
LDFLAGS="${LDFLAGS} ${LAPACK_LIB} ${PTHREAD_LIBS}" \
X11PATH=${X11BASE}
@ -25,9 +26,12 @@ MAKE_ENV= CPPFLAGS="${CFLAGS} ${LAPACK_DEF} ${PTHREAD_CFLAGS}" \
BUILD_DEPENDS+= doxygen:${PORTSDIR}/devel/doxygen
USE_GCC= 3.4
USE_REINPLACE= yes
REINPLACE_ARGS= -i ""
DOCBASE= CHANGES.txt README.txt
.else
NOBUILD= yes
.endif
.if !defined(WITHOUT_IM)
RUN_DEPENDS+= ${LOCALBASE}/lib/libMagick.so.6:${PORTSDIR}/graphics/ImageMagick
.endif
@ -37,23 +41,23 @@ LAPACK_LIB= -L${LOCALBASE}/lib -lalapack -lcblas -lf77blas -lg2c -latlas
LAPACK_DEF= -Dcimg_lapack
.endif
post-extract:
@${CP} ${WRKSRC}/CImg.h ${WRKSRC}/CImg.h.dos
@${TR} -d '\r' < ${WRKSRC}/CImg.h.dos > ${WRKSRC}/CImg.h
#post-extract:
# @${CP} ${WRKSRC}/CImg.h ${WRKSRC}/CImg.h.dos
# @${TR} -d '\r' < ${WRKSRC}/CImg.h.dos > ${WRKSRC}/CImg.h
.if !defined(NOPORTDOCS)
post-patch:
@${REINPLACE_CMD} -e "s|examples/|${EXAMPLESDIR}/|g" \
${WRKSRC}/CImg_test.cpp
@${GREP} -lR 'img/' ${BUILD_WRKSRC} | \
${XARGS} ${REINPLACE_CMD} -e 's|img/|${EXAMPLESDIR}/img/|g'
.endif
do-install:
${INSTALL_DATA} ${WRKSRC}/CImg.h ${PREFIX}/include
.if !defined(NOPORTDOCS)
${INSTALL_PROGRAM} ${WRKSRC}/CImg_test ${PREFIX}/bin
${INSTALL_PROGRAM} ${BUILD_WRKSRC}/CImg_test ${PREFIX}/bin
${MKDIR} ${DOCSDIR} ${EXAMPLESDIR}
${INSTALL_DATA} ${WRKSRC}/README.txt ${DOCSDIR}
${CP} -R ${WRKSRC}/html/* ${DOCSDIR}
${INSTALL_DATA} ${DOCBASE:S|^|${WRKSRC}/|} ${DOCSDIR}
${CP} -R ${WRKSRC}/documentation/* ${DOCSDIR}
${CP} -R ${WRKSRC}/examples/* ${EXAMPLESDIR}
@(cd ${EXAMPLESDIR} && ${MAKE} clean)
${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${DOCSDIR} ${EXAMPLESDIR}

View File

@ -1,2 +1,2 @@
MD5 (cimg-1.0.6/CImg.zip) = cb61151e3db744b4f644b88fcdb8446c
SIZE (cimg-1.0.6/CImg.zip) = 2739063
MD5 (cimg-1.0.7/CImg.zip) = 381f29c8342379d702954a985e9c220c
SIZE (cimg-1.0.7/CImg.zip) = 4205936

View File

@ -1,54 +0,0 @@
--- CImg.h.orig Mon Oct 11 21:46:09 2004
+++ CImg.h Mon Oct 11 22:04:08 2004
@@ -55,7 +55,7 @@
// Autodetection of the current OS
#ifndef cimg_OS
-#if defined(sun) || defined(__sun)
+#if defined(sun) || defined(__sun)
// Solaris
#define cimg_OS 0
#ifndef cimg_display_type
@@ -82,6 +82,15 @@
#ifndef cimg_display_type
#define cimg_display_type 1
#endif
+#elif defined(__FreeBSD__)
+// FreeBSD
+#define cimg_OS 4
+#ifndef cimg_display_type
+#define cimg_display_type 1
+#endif
+#ifndef cimg_color_terminal
+#define cimg_color_terminal
+#endif
#else
// Other configurations
#define cimg_OS -1
@@ -1110,7 +1119,7 @@
t_red,cimg_version,t_normal,__DATE__,__TIME__);
std::fprintf(stderr," > Architecture : %s%-12s%s %s(cimg_OS=%d)\n%s",
t_bold,
- cimg_OS==0?"Solaris":(cimg_OS==1?"Linux":(cimg_OS==2?"Windows":(cimg_OS==3?"Mac OS X":"Unknown"))),
+ cimg_OS==0?"Solaris":(cimg_OS==1?"Linux":(cimg_OS==2?"Windows":(cimg_OS==3?"Mac OS X":(cimg_OS==4?"FreeBSD":"Unknown")))),
t_normal,t_purple,cimg_OS,t_normal);
std::fprintf(stderr," > Display type : %s%-12s%s %s(cimg_display_type=%d)%s\n",
t_bold,cimg_display_type==0?"No":(cimg_display_type==1?"X11":(cimg_display_type==2?"WindowsGDI":"Unknown")),t_normal,t_purple,cimg_display_type,t_normal);
@@ -1542,7 +1551,7 @@
uint width; //!< Width of the display window.
uint height; //!< Height of the display window.
uint normalize; //!< Pixel value normalization.
- const uint attributes; //!< Attributes of the display window.
+ uint attributes; //!< Attributes of the display window.
volatile int mousex; //!< When (attributes&3)>=2, this variable corresponds to the mouse pointer X-coordinate into the display window.
volatile int mousey; //!< When (attributes&3)>=2, this variable corresponds to the mouse pointer Y-coordinate into the display window.
volatile uint button; //!< When (attributes&3)>=2, these variables corresponds to the mouse button clicked into the display window.
@@ -6575,7 +6584,7 @@
Here are the different environment variables used by the CImg Library :
- \b \c cimg_OS : This variable defines the type of your current OS. It can be set to 0 (Solaris), 1 (Linux),
- 2 (Windows), 3 (Mac OS X) or -1 (Other configuration).
+ 2 (Windows), 3 (Mac OS X), 4 (FreeBSD) or -1 (Other configuration).
It should be actually auto-detected by the CImg library. If this is not the case (cimg_OS=-1), then you
will probably have to tune the environment variables described below.
- \b \c cimg_display_type : This variable defines the type of display library that will be used to

View File

@ -1,85 +0,0 @@
--- Makefile.orig Fri Aug 6 17:35:44 2004
+++ Makefile Mon Oct 11 22:42:11 2004
@@ -1,41 +1,41 @@
-#--------------------------------------------------------------------------------------
-#
-# File : Makefile
-#
-# Description : Makefile to compile CImg for Linux and Solaris
-#
-# Author : David Tschumperlé
-#
-# Institution : ODYSSEE, INRIA Sophia Antipolis.
-#
-# Contact : David.Tschumperle@sophia.inria.fr
-#
-# Date : Project started november 1999.
-#
-# -----------------------------------------------------------------------------------
-
-# Set correct variables and paths
-CC = g++ -O4 -Wall-ansi -ffast-math
-X11PATH = /usr/X11R6
-X11FLAGS = -I$(X11PATH)/include -L$(X11PATH)/lib -lX11
-
-# Compilation rules
-.cpp:
- @echo "> Compiling '$*'"
- @$(CC) -o $* $< $(CFLAGS) $(X11FLAGS) $(LDFLAGS)
-linux:
- @echo -e "\n** Starting the compilation of the entire CImg package for Linux. Please wait...\n"
- make "LDFLAGS=-lm -lpthread -Wl,-rpath $(X11PATH)/lib" all
-solaris:
- @echo -e "\n** Starting the compilation of the entire CImg package for Solaris. Please wait...\n"
- make "LDFLAGS=-lm -lpthread -R$(X11PATH)/lib -lnsl -lsocket" all
-doc:
- @echo "> Create documentation (you need the 'doxygen' tool, see http://www.doxygen.org)."
- @doxygen CImg.doxygen >/dev/null
-all: CImg_test
- cd examples && make all
- make doc
- @echo -e "\n** All done successfully. You can launch 'CImg_test', or read documentation 'html/index.html'. **\n"
-clean:
- cd examples && make clean
- rm -rf documentation CImg_test cimg_new core *~ *.o *.exe
+#--------------------------------------------------------------------------------------
+#
+# File : Makefile
+#
+# Description : Makefile to compile CImg for Linux and Solaris
+#
+# Author : David Tschumperlé
+#
+# Institution : ODYSSEE, INRIA Sophia Antipolis.
+#
+# Contact : David.Tschumperle@sophia.inria.fr
+#
+# Date : Project started november 1999.
+#
+# -----------------------------------------------------------------------------------
+
+# Set correct variables and paths
+CC = $(CXX)
+#X11PATH = /usr/X11R6
+X11FLAGS = -I$(X11PATH)/include -L$(X11PATH)/lib -lX11
+
+# Compilation rules
+.cpp:
+ @echo "> Compiling '$*'"
+ $(CC) -o $* $< $(CPPFLAGS) -Wall -ansi -ffast-math $(X11FLAGS) $(LDFLAGS)
+linux:
+ @echo -e "\n** Starting the compilation of the entire CImg package for Linux. Please wait...\n"
+ make "LDFLAGS=-lm -lpthread -Wl,-rpath $(X11PATH)/lib" all
+solaris:
+ @echo -e "\n** Starting the compilation of the entire CImg package for Solaris. Please wait...\n"
+ make "LDFLAGS=-lm -lpthread -R$(X11PATH)/lib -lnsl -lsocket" all
+doc:
+ @echo "> Create documentation (you need the 'doxygen' tool, see http://www.doxygen.org)."
+ @doxygen CImg.doxygen >/dev/null
+all: CImg_test
+ cd examples && make all
+ make doc
+ @echo -e "\n** All done successfully. After install, you can launch 'CImg_test', or read documentation 'html/index.html'. **\n"
+clean:
+ cd examples && make clean
+ rm -rf documentation CImg_test cimg_new core *~ *.o *.exe

View File

@ -1,117 +1,28 @@
--- examples/Makefile.orig Fri Aug 6 17:35:46 2004
+++ examples/Makefile Mon Oct 11 22:43:13 2004
@@ -1,57 +1,57 @@
-#--------------------------------------------------------------------------------------
-#
-# Makefile : Makefile for compiling CImg examples
-#
-# Author : David Tschumperlé
-#
-# Institution : ODYSSEE, INRIA Sophia Antipolis.
-#
-# Contact : David.Tschumperle@sophia.inria.fr
-#
-# Date : Project started november 1999.
-#
-# -----------------------------------------------------------------------------------
-
-# Set correct variables and paths
-CC = g++ -O4 -Wall -ansi -ffast-math
-X11PATH = /usr/X11R6
-X11FLAGS = -I$(X11PATH)/include -L$(X11PATH)/lib -lX11
-
-# Compilation rules
-.cpp:
- @echo "> Compiling '$*'"
- @$(CC) -o $* $< $(CFLAGS) $(X11FLAGS) $(LDFLAGS)
-linux:
- make "LDFLAGS=-lm -lpthread -Wl,-rpath $(X11PATH)/lib" all
-solaris:
- make "LDFLAGS=-lm -lpthread -R$(X11PATH)/lib -lnsl -lsocket" all
-
-all: fade_images \
- inpainter \
- odykill \
- pslider \
- inrcast \
- inrcrop \
- optical_flow \
- hough_transform \
- render3d \
- tutorial \
- tetris \
- pde_heatflow2D \
- pde_TschumperleDeriche2D
-
-clean:
- rm -f *.exe *~ \
- fade_images \
- inpainter \
- odykill \
- pslider \
- inrcast \
- inrcrop \
- optical_flow \
- hough_transform \
- render3d \
- tutorial \
- tetris \
- pde_heatflow2D \
- pde_TschumperleDeriche2D
+#--------------------------------------------------------------------------------------
+#
+# Makefile : Makefile for compiling CImg examples
+#
+# Author : David Tschumperlé
+#
+# Institution : ODYSSEE, INRIA Sophia Antipolis.
+#
+# Contact : David.Tschumperle@sophia.inria.fr
+#
+# Date : Project started november 1999.
+#
+# -----------------------------------------------------------------------------------
+
+# Set correct variables and paths
--- examples/Makefile.orig Wed Oct 20 16:49:34 2004
+++ examples/Makefile Wed Oct 20 21:16:24 2004
@@ -7,14 +7,14 @@
# -----------------------------------------------------------------------------------
# Set correct variables and paths
-CC = g++ -O4 -Wall -ansi -ffast-math
-X11PATH = /usr/X11R6
+CC = $(CXX)
+#X11PATH = /usr/X11R6
+X11FLAGS = -I$(X11PATH)/include -L$(X11PATH)/lib -lX11
+
+# Compilation rules
+.cpp:
+ @echo "> Compiling '$*'"
+ $(CC) -o $* $< $(CPPFLAGS) -Wall -ansi -ffast-math $(X11FLAGS) $(LDFLAGS)
+linux:
+ make "LDFLAGS=-lm -lpthread -Wl,-rpath $(X11PATH)/lib" all
+solaris:
+ make "LDFLAGS=-lm -lpthread -R$(X11PATH)/lib -lnsl -lsocket" all
+
+all: fade_images \
+ inpainter \
+ odykill \
+ pslider \
+ inrcast \
+ inrcrop \
+ optical_flow \
+ hough_transform \
+ render3d \
+ tutorial \
+ tetris \
+ pde_heatflow2D \
+ pde_TschumperleDeriche2D
+
+clean:
+ rm -f *.exe *~ *.orig \
+ fade_images \
+ inpainter \
+ odykill \
+ pslider \
+ inrcast \
+ inrcrop \
+ optical_flow \
+ hough_transform \
+ render3d \
+ tutorial \
+ tetris \
+ pde_heatflow2D \
+ pde_TschumperleDeriche2D
X11FLAGS = -I$(X11PATH)/include -L$(X11PATH)/lib -lX11
# Compilation rules
.cpp:
@echo -e "\n** Compiling '$*'\n"
- @$(CC) -o $* $< $(CFLAGS) $(X11FLAGS) $(LDFLAGS)
+ @$(CC) -o $* $< $(CPPFLAGS) -Wall -ansi -ffast-math $(X11FLAGS) $(LDFLAGS)
linux:
make "LDFLAGS=-lm -lpthread -Wl,-rpath $(X11PATH)/lib" all
solaris:
@@ -37,6 +37,7 @@
clean:
rm -f *.exe *~ \
+ Makefile.orig \
CImg_test \
fade_images \
inpainter \

View File

@ -1,7 +1,10 @@
%%PORTDOCS%%bin/CImg_test
include/CImg.h
%%PORTDOCS%%%%DOCSDIR%%/CHANGES.txt
%%PORTDOCS%%%%DOCSDIR%%/CImg.doxygen
%%PORTDOCS%%%%DOCSDIR%%/README.txt
%%PORTDOCS%%%%DOCSDIR%%/download.shtml
%%PORTDOCS%%%%DOCSDIR%%/favicon.ico
%%PORTDOCS%%%%DOCSDIR%%/favicon.png
%%PORTDOCS%%%%DOCSDIR%%/head.html
%%PORTDOCS%%%%DOCSDIR%%/head_reference.html
%%PORTDOCS%%%%DOCSDIR%%/img/CImgLogo.jpg
@ -10,7 +13,6 @@ include/CImg.h
%%PORTDOCS%%%%DOCSDIR%%/img/FAQ_item.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/LastNews.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/download_item.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/inria_logo.gif
%%PORTDOCS%%%%DOCSDIR%%/img/item_codesample.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/item_getting.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/item_intro.jpg
@ -39,6 +41,7 @@ include/CImg.h
%%PORTDOCS%%%%DOCSDIR%%/img/ss_mini_000014.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_mini_000015.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_mini_000016.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_mini_000017.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_odykill.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_optflow.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_paint.jpg
@ -46,57 +49,19 @@ include/CImg.h
%%PORTDOCS%%%%DOCSDIR%%/img/ss_render3d.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_restoration.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_rotozoom.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_shadebobs.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_tetris.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_triangle.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/ss_volume3d.jpg
%%PORTDOCS%%%%DOCSDIR%%/img/tutorial.jpg
%%PORTDOCS%%%%DOCSDIR%%/index.shtml
%%PORTDOCS%%%%DOCSDIR%%/news.html
%%PORTDOCS%%%%DOCSDIR%%/reference/annotated.html
%%PORTDOCS%%%%DOCSDIR%%/reference/doxygen.css
%%PORTDOCS%%%%DOCSDIR%%/reference/doxygen.png
%%PORTDOCS%%%%DOCSDIR%%/reference/functions.html
%%PORTDOCS%%%%DOCSDIR%%/reference/functions_func.html
%%PORTDOCS%%%%DOCSDIR%%/reference/functions_rela.html
%%PORTDOCS%%%%DOCSDIR%%/reference/functions_vars.html
%%PORTDOCS%%%%DOCSDIR%%/reference/group__cimg__drawing.html
%%PORTDOCS%%%%DOCSDIR%%/reference/group__cimg__environment.html
%%PORTDOCS%%%%DOCSDIR%%/reference/group__cimg__exceptions.html
%%PORTDOCS%%%%DOCSDIR%%/reference/group__cimg__structure.html
%%PORTDOCS%%%%DOCSDIR%%/reference/group__cimg__tutorial.html
%%PORTDOCS%%%%DOCSDIR%%/reference/hierarchy.html
%%PORTDOCS%%%%DOCSDIR%%/reference/index.html
%%PORTDOCS%%%%DOCSDIR%%/reference/modules.html
%%PORTDOCS%%%%DOCSDIR%%/reference/namespacecimg.html
%%PORTDOCS%%%%DOCSDIR%%/reference/namespacemembers.html
%%PORTDOCS%%%%DOCSDIR%%/reference/namespacemembers_func.html
%%PORTDOCS%%%%DOCSDIR%%/reference/namespacemembers_vars.html
%%PORTDOCS%%%%DOCSDIR%%/reference/namespaces.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImg-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImg.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgArgumentException-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgArgumentException.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgDisplay-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgDisplay.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgDisplayException-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgDisplayException.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgException-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgException.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgIOException-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgIOException.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgInstanceException-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgInstanceException.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgROI-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgROI.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgStats-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgStats.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgl-members.html
%%PORTDOCS%%%%DOCSDIR%%/reference/structCImgl.html
%%PORTDOCS%%%%DOCSDIR%%/screenshots.shtml
%%PORTDOCS%%%%EXAMPLESDIR%%/CImg_test.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/Makefile
%%PORTDOCS%%%%EXAMPLESDIR%%/README.txt
%%PORTDOCS%%%%EXAMPLESDIR%%/fade_images.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/hough_transform.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/image_registration.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/img/background.jpg
%%PORTDOCS%%%%EXAMPLESDIR%%/img/brain.png
%%PORTDOCS%%%%EXAMPLESDIR%%/img/cdrom.png
@ -133,9 +98,7 @@ include/CImg.h
%%PORTDOCS%%%%EXAMPLESDIR%%/img/tomato.png
%%PORTDOCS%%%%EXAMPLESDIR%%/inpainter.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/inrcast.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/inrcrop.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/odykill.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/optical_flow.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/pde_TschumperleDeriche2D.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/pde_TschumperleDeriche3D.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/pde_heatflow2D.cpp
@ -143,7 +106,6 @@ include/CImg.h
%%PORTDOCS%%%%EXAMPLESDIR%%/render3d.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/tetris.cpp
%%PORTDOCS%%%%EXAMPLESDIR%%/tutorial.cpp
%%PORTDOCS%%@dirrm %%DOCSDIR%%/reference
%%PORTDOCS%%@dirrm %%DOCSDIR%%/img
%%PORTDOCS%%@dirrm %%DOCSDIR%%
%%PORTDOCS%%@dirrm %%EXAMPLESDIR%%/img