View | Details | Raw Unified | Return to bug 172397
Collapse All | Expand All

(-)zbar/Makefile (-17 / +14 lines)
Lines 21-52 Link Here
21
USE_LDCONFIG=	yes
21
USE_LDCONFIG=	yes
22
USE_ICONV=	yes
22
USE_ICONV=	yes
23
23
24
OPTIONS=	X11         "Build with X support" on \
24
OPTIONS_DEFINE=	X11 IMAGEMAGICK V4L PYTHON GTK2 QT4
25
		IMAGEMAGICK "ImageMagick graphics support" on \
25
OPTIONS_DEFAULT=	X11 IMAGEMAGICK
26
		V4L         "Build zbarcam video scanner" off \
26
V4L_DESC=	Build zbarcam video scanner
27
		PYTHON      "Build PyGTK widget" off \
28
		GTK2        "Build GTK+2 widget" off \
29
		QT4         "Build Qt4 widget" off
30
27
31
.include <bsd.port.options.mk>
28
.include <bsd.port.options.mk>
32
29
33
.if exists(${LOCALBASE}/lib/libjpeg.so)
30
.if exists(${LOCALBASE}/lib/libjpeg.so)
34
CONFIGURE_ARGS+=	--with-jpeg=yes
31
CONFIGURE_ARGS+=	--with-jpeg=yes
35
LIB_DEPENDS+=	jpeg.11:${PORTSDIR}/graphics/jpeg
32
LIB_DEPENDS+=	jpeg:${PORTSDIR}/graphics/jpeg
36
.else
33
.else
37
CONFIGURE_ARGS+=	--with-jpeg=no
34
CONFIGURE_ARGS+=	--with-jpeg=no
38
.endif
35
.endif
39
36
40
.if defined(WITH_X11)
37
.if ${PORT_OPTIONS:MX11}
41
USE_XORG=	ice sm x11 xau xdmcp xext xv
38
USE_XORG=	ice sm x11 xau xdmcp xext xv
42
LIB_DEPENDS+=	xcb.2:${PORTSDIR}/x11/libxcb
39
LIB_DEPENDS+=	xcb:${PORTSDIR}/x11/libxcb
43
CONFIGURE_ARGS+=	--with-x=yes
40
CONFIGURE_ARGS+=	--with-x=yes
44
.else
41
.else
45
CONFIGURE_ARGS+=	--with-x=no --without-xshm --without-xv
42
CONFIGURE_ARGS+=	--with-x=no --without-xshm --without-xv
46
.endif
43
.endif
47
44
48
.if defined(WITH_IMAGEMAGICK)
45
.if ${PORT_OPTIONS:MIMAGEMAGICK}
49
LIB_DEPENDS+=	Magick++.5:${PORTSDIR}/graphics/ImageMagick
46
LIB_DEPENDS+=	Magick++:${PORTSDIR}/graphics/ImageMagick
50
CONFIGURE_ARGS+=	--with-imagemagick=yes
47
CONFIGURE_ARGS+=	--with-imagemagick=yes
51
PLIST_SUB+=	IMAGEMAGICK=""
48
PLIST_SUB+=	IMAGEMAGICK=""
52
MAN1=	zbarimg.1
49
MAN1=	zbarimg.1
Lines 55-61 Link Here
55
PLIST_SUB+=	IMAGEMAGICK="@comment "
52
PLIST_SUB+=	IMAGEMAGICK="@comment "
56
.endif
53
.endif
57
54
58
.if defined(WITH_V4L)
55
.if ${PORT_OPTIONS:MV4L}
59
BUILD_DEPENDS+=	v4l_compat>=1.0.20101027:${PORTSDIR}/multimedia/v4l_compat
56
BUILD_DEPENDS+=	v4l_compat>=1.0.20101027:${PORTSDIR}/multimedia/v4l_compat
60
CONFIGURE_ARGS+=	--enable-video=yes
57
CONFIGURE_ARGS+=	--enable-video=yes
61
PLIST_SUB+=	V4L=""
58
PLIST_SUB+=	V4L=""
Lines 65-71 Link Here
65
PLIST_SUB+=	V4L="@comment "
62
PLIST_SUB+=	V4L="@comment "
66
.endif
63
.endif
67
64
68
.if defined(WITH_PYTHON)
65
.if ${PORT_OPTIONS:MPYTHON}
69
USE_PYTHON=	2.5-2.7
66
USE_PYTHON=	2.5-2.7
70
USE_GNOME+=	pygtk2
67
USE_GNOME+=	pygtk2
71
CONFIGURE_ARGS+=	--with-python=yes
68
CONFIGURE_ARGS+=	--with-python=yes
Lines 75-81 Link Here
75
PLIST_SUB+=	PYTHON="@comment "
72
PLIST_SUB+=	PYTHON="@comment "
76
.endif
73
.endif
77
74
78
.if defined(WITH_GTK2)
75
.if ${PORT_OPTIONS:MGTK2}
79
USE_GNOME+=	gtk20
76
USE_GNOME+=	gtk20
80
CONFIGURE_ARGS+=	--with-gtk=yes
77
CONFIGURE_ARGS+=	--with-gtk=yes
81
PLIST_SUB+=	GTK2=""
78
PLIST_SUB+=	GTK2=""
Lines 84-90 Link Here
84
PLIST_SUB+=	GTK2="@comment "
81
PLIST_SUB+=	GTK2="@comment "
85
.endif
82
.endif
86
83
87
.if defined(WITH_QT4)
84
.if ${PORT_OPTIONS:MQT4}
88
USE_QT4=	gui moc_build
85
USE_QT4=	gui moc_build
89
CONFIGURE_ARGS+=	--with-qt=yes
86
CONFIGURE_ARGS+=	--with-qt=yes
90
PLIST_SUB+=	QT4=""
87
PLIST_SUB+=	QT4=""
Lines 97-105 Link Here
97
94
98
post-patch:
95
post-patch:
99
	@${REINPLACE_CMD} 's|-lpthread|${PTHREAD_LIBS}|' ${WRKSRC}/configure
96
	@${REINPLACE_CMD} 's|-lpthread|${PTHREAD_LIBS}|' ${WRKSRC}/configure
100
	@${REINPLACE_CMD} 's|^pkgconfigdir = .*|pkgconfigdir = $$(prefix)/libdata/pkgconfig|' \
97
	@${REINPLACE_CMD} 's|^pkgconfigdir = .*|pkgconfigdir = ${PREFIX}/libdata/pkgconfig|' \
101
		${WRKSRC}/Makefile.in
98
		${WRKSRC}/Makefile.in
102
.if defined(NOPORTDOCS)
99
.if !${PORT_OPTIONS:MDOCS}
103
	@${REINPLACE_CMD} '/^install-data-am: /s/install-dist_docDATA//' \
100
	@${REINPLACE_CMD} '/^install-data-am: /s/install-dist_docDATA//' \
104
		${WRKSRC}/Makefile.in
101
		${WRKSRC}/Makefile.in
105
.endif
102
.endif

Return to bug 172397