summaryrefslogtreecommitdiffstats
path: root/graphics/cairo
diff options
context:
space:
mode:
authorpav <pav@df743ca5-7f9a-e211-a948-0013205c9059>2007-09-09 20:07:04 +0800
committerpav <pav@df743ca5-7f9a-e211-a948-0013205c9059>2007-09-09 20:07:04 +0800
commit75f62e991a811ac7a5cf9324094b95307926a097 (patch)
tree50f402e0293d239cb910a02097a23c51dbc867ff /graphics/cairo
parent740276e2a0148b732c14c74b4a31c58ff303e12f (diff)
downloadmarcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.tar
marcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.tar.gz
marcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.tar.bz2
marcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.tar.lz
marcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.tar.xz
marcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.tar.zst
marcuscom-ports-75f62e991a811ac7a5cf9324094b95307926a097.zip
- Push USE_XLIB out of cairo and pango (but not gtk20 for now)
PR: ports/115870, ports/115872 Submitted by: mm Tested by: pointyhat exprun (on GNOME 2.18 ports) git-svn-id: svn://creme-brulee.marcuscom.com/ports/trunk@9544 df743ca5-7f9a-e211-a948-0013205c9059
Diffstat (limited to 'graphics/cairo')
-rw-r--r--graphics/cairo/Makefile67
-rw-r--r--graphics/cairo/distinfo3
-rw-r--r--graphics/cairo/files/patch-src_cairo-ft-font.c28
-rw-r--r--graphics/cairo/files/patch-src_cairo-xlib-surface.c11
-rw-r--r--graphics/cairo/files/patch-src_cairoint.h14
-rw-r--r--graphics/cairo/pkg-descr13
-rw-r--r--graphics/cairo/pkg-plist24
7 files changed, 160 insertions, 0 deletions
diff --git a/graphics/cairo/Makefile b/graphics/cairo/Makefile
new file mode 100644
index 000000000..8a1c1bea5
--- /dev/null
+++ b/graphics/cairo/Makefile
@@ -0,0 +1,67 @@
+# New ports collection makefile for: cairo
+# Date created: 2004-10-06
+# Whom: Michael Johnson <ahze@FreeBSD.org>
+#
+# $FreeBSD: ports/graphics/cairo/Makefile,v 1.29 2007/06/28 00:22:14 ahze Exp $
+# $MCom: ports/graphics/cairo/Makefile,v 1.56 2007/03/06 13:39:18 ahze Exp $
+#
+
+PORTNAME= cairo
+PORTVERSION= 1.4.10
+PORTREVISION?= 1
+CATEGORIES= graphics
+MASTER_SITES= http://cairographics.org/releases/
+#MASTER_SITES= http://cairographics.org/snapshots/
+
+MAINTAINER= gnome@FreeBSD.org
+COMMENT= Vector graphics library with cross-device output support
+
+.if !defined(REFERENCE_PORT)
+
+LIB_DEPENDS= freetype.9:${PORTSDIR}/print/freetype2 \
+ png.5:${PORTSDIR}/graphics/png \
+ fontconfig.1:${PORTSDIR}/x11-fonts/fontconfig
+
+CONFIGURE_ARGS= --with-html-dir=${DOCSDIR} \
+ --enable-pdf \
+ --enable-ps
+USE_GNOME= gnometarget gnomehack ltverhack referencehack
+USE_AUTOTOOLS= libtool:15
+USE_LDCONFIG= yes
+
+CONFIGURE_ENV= CPPFLAGS="${PTHREAD_CFLAGS} -I${X11BASE}/include" \
+ LDFLAGS="${PTHREAD_LIBS}"
+
+.if defined(WITHOUT_X11)
+CONFIGURE_ARGS+=--disable-xlib
+PLIST_SUB+= X11="@comment "
+.else
+USE_XORG+= xrender
+PLIST_SUB+= X11=""
+.endif
+
+OPTIONS+= GLITZ "Enable Glitz OpenGL Support" Off
+
+.include <bsd.port.pre.mk>
+
+.if defined(WITH_GLITZ)
+LIB_DEPENDS+= glitz-glx.1:${PORTSDIR}/graphics/glitz
+CONFIGURE_ARGS+= --enable-glitz
+PLIST_SUB+= GLITZ=""
+.else
+CONFIGURE_ARGS+= --disable-glitz
+PLIST_SUB+= GLITZ="@comment "
+.endif
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|' \
+ ${WRKSRC}/test/Makefile.in
+ @${REINPLACE_CMD} -e 's|-lcairo|-lcairo ${PTHREAD_LIBS}|' \
+ ${WRKSRC}/src/*.pc.in
+ @${REINPLACE_CMD} -e 's|src test doc|src doc|; \
+ s|@CAIRO_HAS_PNG_FUNCTIONS_TRUE@am__append_1 = test||' \
+ ${WRKSRC}/Makefile.in
+
+.include <bsd.port.post.mk>
+
+.endif
diff --git a/graphics/cairo/distinfo b/graphics/cairo/distinfo
new file mode 100644
index 000000000..ac20959e1
--- /dev/null
+++ b/graphics/cairo/distinfo
@@ -0,0 +1,3 @@
+MD5 (cairo-1.4.10.tar.gz) = 5598a5e500ad922e37b159dee72fc993
+SHA256 (cairo-1.4.10.tar.gz) = 594e78a66044898c321e378d47faf43b665b23ba638834d2787e344ba13e5132
+SIZE (cairo-1.4.10.tar.gz) = 3216689
diff --git a/graphics/cairo/files/patch-src_cairo-ft-font.c b/graphics/cairo/files/patch-src_cairo-ft-font.c
new file mode 100644
index 000000000..8cd60665f
--- /dev/null
+++ b/graphics/cairo/files/patch-src_cairo-ft-font.c
@@ -0,0 +1,28 @@
+--- src/cairo-ft-font.c.orig Tue Aug 16 14:46:46 2005
++++ src/cairo-ft-font.c Tue Aug 16 14:46:59 2005
+@@ -44,6 +44,11 @@
+ #include <fontconfig/fontconfig.h>
+ #include <fontconfig/fcfreetype.h>
+
++#include <sys/types.h>
++#include <stdlib.h>
++#include <time.h>
++#include <unistd.h>
++
+ #include <ft2build.h>
+ #include FT_FREETYPE_H
+ #include FT_OUTLINE_H
+@@ -257,7 +262,12 @@ _cairo_ft_unscaled_font_init_key (cairo_
+ key->id = id;
+
+ /* 1607 is just an arbitrary prime. */
+- hash = _cairo_hash_string (filename);
++ if (filename != NULL) {
++ hash = _cairo_hash_string (filename);
++ } else {
++ srandom(time(NULL) * getpid());
++ hash = random();
++ }
+ hash += ((unsigned long) id) * 1607;
+
+ key->base.hash_entry.hash = hash;
diff --git a/graphics/cairo/files/patch-src_cairo-xlib-surface.c b/graphics/cairo/files/patch-src_cairo-xlib-surface.c
new file mode 100644
index 000000000..396ac3e29
--- /dev/null
+++ b/graphics/cairo/files/patch-src_cairo-xlib-surface.c
@@ -0,0 +1,11 @@
+--- src/cairo-xlib-surface.c.orig Mon Oct 3 22:44:43 2005
++++ src/cairo-xlib-surface.c Wed Nov 16 18:59:40 2005
+@@ -1758,7 +1758,7 @@
+
+ surface->buggy_repeat = FALSE;
+ if (strstr (ServerVendor (dpy), "X.Org") != NULL) {
+- if (VendorRelease (dpy) <= 60802000)
++ if (VendorRelease (dpy) < 60900000)
+ surface->buggy_repeat = TRUE;
+ } else if (strstr (ServerVendor (dpy), "XFree86") != NULL) {
+ if (VendorRelease (dpy) <= 40500000)
diff --git a/graphics/cairo/files/patch-src_cairoint.h b/graphics/cairo/files/patch-src_cairoint.h
new file mode 100644
index 000000000..a9b3ce480
--- /dev/null
+++ b/graphics/cairo/files/patch-src_cairoint.h
@@ -0,0 +1,14 @@
+--- src/cairoint.h.orig Sun Oct 15 18:02:35 2006
++++ src/cairoint.h Sun Oct 15 18:10:11 2006
+@@ -50,6 +50,11 @@
+ #include "config.h"
+ #endif
+
++#ifndef INT16_MAX
++#define INT16_MAX 0x7fff
++#define INT16_MIN (-0x7fff-1)
++#endif
++
+ #include <assert.h>
+ #include <stdlib.h>
+ #include <string.h>
diff --git a/graphics/cairo/pkg-descr b/graphics/cairo/pkg-descr
new file mode 100644
index 000000000..4fd137a19
--- /dev/null
+++ b/graphics/cairo/pkg-descr
@@ -0,0 +1,13 @@
+Cairo is a vector graphics library with cross-device output
+support. Currently supported output targets include the X Window
+System and in-memory image buffers. PostScript and PDF file output is
+planned. Cairo is designed to produce identical output on all output
+media while taking advantage of display hardware acceleration when
+available (eg. through the X Render Extension).
+
+Cairo provides a stateful user-level API with capabilities similar to
+the PDF 1.4 imaging model. Cairo provides operations including stroking
+and filling Bezier cubic splines, transforming and compositing translucent
+images, and antialiased text rendering.
+
+WWW: http://www.cairographics.org
diff --git a/graphics/cairo/pkg-plist b/graphics/cairo/pkg-plist
new file mode 100644
index 000000000..c81b6e936
--- /dev/null
+++ b/graphics/cairo/pkg-plist
@@ -0,0 +1,24 @@
+include/cairo/cairo-deprecated.h
+include/cairo/cairo-features.h
+include/cairo/cairo-ft.h
+%%GLITZ%%include/cairo/cairo-glitz.h
+include/cairo/cairo-pdf.h
+include/cairo/cairo-ps.h
+include/cairo/cairo-svg.h
+%%X11%%include/cairo/cairo-xlib-xrender.h
+%%X11%%include/cairo/cairo-xlib.h
+include/cairo/cairo.h
+lib/libcairo.a
+lib/libcairo.la
+lib/libcairo.so
+lib/libcairo.so.2
+libdata/pkgconfig/cairo.pc
+libdata/pkgconfig/cairo-ft.pc
+%%GLITZ%%libdata/pkgconfig/cairo-glitz.pc
+libdata/pkgconfig/cairo-pdf.pc
+libdata/pkgconfig/cairo-png.pc
+libdata/pkgconfig/cairo-ps.pc
+libdata/pkgconfig/cairo-svg.pc
+%%X11%%libdata/pkgconfig/cairo-xlib.pc
+%%X11%%libdata/pkgconfig/cairo-xlib-xrender.pc
+@dirrm include/cairo