aboutsummaryrefslogtreecommitdiffstats
path: root/graphics/gegl/Makefile
blob: fc62a982a67ec1609f60778e073e6c887cff7cb5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
# New ports collection Makefile for:    gegl
# Date created:             3 October 2008
# Whom:                 gahr
#
# $FreeBSD$
#

PORTNAME=   gegl
PORTVERSION=    0.0.${GEGL_MINOR}
PORTREVISION=   1
CATEGORIES= graphics
MASTER_SITES=   ftp://ftp.gimp.org/pub/gegl/0.0/

MAINTAINER= gahr@FreeBSD.org
COMMENT=    A graph based image processing framework

LIB_DEPENDS=    babl-0.0:${PORTSDIR}/x11/babl \
            png.5:${PORTSDIR}/graphics/png

OPTIONS=    CAIRO       "Enable Cairo" on \
        FFMPEG      "Enable ffmpeg" on \
        GTK     "Enable GTK+" on \
        GRAPHVIZ    "Enable Graphviz" on \
        JPEG        "Enable JPEG" on \
        OPENEXR     "Enable OpenEXR" on \
        OPENRAW     "Enable OpenRAW" on \
        PANGO       "Enable Pango" on \
        RSVG        "Enable RSVG" on \
        SPIRO       "Enable Spiro" on \
        SDL     "Enable SDL" on

USE_GNOME=  glib20 pkgconfig gnomehack
USE_BZIP2=  yes
USE_GMAKE=  yes
USE_LDCONFIG=   ${PREFIX}/lib/gegl-0.0
GNU_CONFIGURE=  yes
CONFIGURE_ENV+= CPPFLAGS="-I${LOCALBASE}/include" \
        CFLAGS="-I${LOCALBASE}/include" \
        LDFLAGS="-L${LOCALBASE}/lib"
CONFIGURE_ARGS+=--disable-sse \
        --disable-mmx

GEGL_MINOR= 22
PLIST_SUB+= GEGL_MINOR="${GEGL_MINOR}"

EXAMPLES=   2geglbuffer gegl-paint geglbuffer-add-image \
        geglbuffer-clock hello-world hello-world-video

.include <bsd.port.pre.mk>

.if !defined(WITHOUT_CAIRO)
LIB_DEPENDS+=   cairo.2:${PORTSDIR}/graphics/cairo
.else
CONFIGURE_ARGS+=--without-cairo
.endif

.if !defined(WITHOUT_FFMPEG)
LIB_DEPENDS+=   avformat.1:${PORTSDIR}/multimedia/ffmpeg
.else
CONFIGURE_ARGS+=--without-libavformat
.endif

.if !defined(WITHOUT_GTK)
USE_GNOME+= gtk20
.else
CONFIGURE_ARGS+=--without-gtk
.endif

.if !defined(WITHOUT_GRAPHVIZ)
LIB_DEPENDS+=   graph.4:${PORTSDIR}/graphics/graphviz
.else
CONFIGURE_ARGS+=--without-graphviz
.endif

.if !defined(WITHOUT_JPEG)
LIB_DEPENDS+=   jpeg.9:${PORTSDIR}/graphics/jpeg
.else
CONFIGURE_ARGS+=--without-libjpeg
.endif

.if !defined(WITHOUT_OPENEXR)
LIB_DEPENDS+=   IlmImf.6:${PORTSDIR}/graphics/OpenEXR
.else
CONFIGURE_ARGS+=--without-openexr
.endif

.if !defined(WITHOUT_OPENRAW)
LIB_DEPENDS+=   openraw.5:${PORTSDIR}/graphics/libopenraw
.else
CONFIGURE_ARGS+=--without-libopenraw
.endif

.if !defined(WITHOUT_PANGO)
USE_GNOME+= pango
.else
CONFIGURE_ARGS+=--without-pango
.endif

.if !defined(WITHOUT_RSVG)
LIB_DEPENDS+=   rsvg-2.2:${PORTSDIR}/graphics/librsvg2
.else
CONFIGURE_ARGS+=--without-librsvg
.endif

.if !defined(WITHOUT_SDL)
USE_SDL=    sdl
.else
CONFIGURE_ARGS+=--without-sdl
.endif

.if !defined(WITHOUT_SPIRO)
LIB_DEPENDS+=   spiro.0:${PORTSDIR}/graphics/libspiro
.else
CONFIGURE_ARGS+=--without-libspiro
.endif

.if !defined(NOPORTDOCS)
BUILD_DEPENDS+= a2x:${PORTSDIR}/textproc/asciidoc
.else
CONFIGURE_ARGS+=    --disable-docs
.endif

post-patch:
    ${REINPLACE_CMD} -e 's|-T||' ${WRKSRC}/docs/Makefile.am ${WRKSRC}/docs/Makefile.in

post-build:
.if !defined(NOPORTDOCS)
    cd ${WRKSRC}/docs && ${GMAKE}
.endif

post-install:
.if !defined(NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}/gallery
    (cd ${WRKSRC}/docs && \
        ${COPYTREE_SHARE} \*.html ${DOCSDIR} && \
        ${INSTALL_DATA} ChangeLog gegl.css gegl.devhelp devhelp.css ${DOCSDIR} && \
        ${INSTALL_DATA} gallery/OpenRaster* ${DOCSDIR}/gallery && \
        ${INSTALL_DATA} gallery/clones* ${DOCSDIR}/gallery && \
        ${INSTALL_DATA} gallery/index.html ${DOCSDIR}/gallery )
.endif
.if !defined(NOPORTEXAMPLES)
    ${MKDIR} ${EXAMPLESDIR}/data
    ${INSTALL_DATA} ${WRKSRC}/examples/data/surfer.png ${EXAMPLESDIR}/data
.for ex in ${EXAMPLES}
    ${INSTALL_DATA} ${WRKSRC}/examples/${ex}.c ${EXAMPLESDIR}
.endfor
.endif

.include <bsd.port.post.mk>