aboutsummaryrefslogtreecommitdiffstats
path: root/graphics/leptonica/Makefile
blob: 92e1f339899be49c165cde3358ed1d5a52b0e5ca (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
# Created by: Hiroto Kagotani <hiroto.kagotani@gmail.com>
# $FreeBSD$

PORTNAME=   leptonica
PORTVERSION=    1.70
PORTREVISION=   3
CATEGORIES= graphics
MASTER_SITES=   http://www.leptonica.com/source/

MAINTAINER= hiroto.kagotani@gmail.com
COMMENT=    C library for efficient image processing and image analysis operations

LIB_DEPENDS=    libgif.so:${PORTSDIR}/graphics/giflib \
        libpng.so:${PORTSDIR}/graphics/png \
        libtiff.so:${PORTSDIR}/graphics/tiff \
        libwebp.so:${PORTSDIR}/graphics/webp

CONFLICTS=  leptonlib-[0-9]*

USES=       jpeg libtool
GNU_CONFIGURE=  yes
USE_LDCONFIG=   yes
CPPFLAGS+=  -I${LOCALBASE}/include
LDFLAGS+=   -L${LOCALBASE}/lib
INSTALL_TARGET= install-strip

TESTS?= generate compare
.if defined(MAINTAINER_MODE) || defined(PACKAGE_BUILDING)
BUILD_DEPENDS+= ${LOCALBASE}/bin/gnuplot:${PORTSDIR}/math/gnuplot
.endif
#the display portion of the regression tests is interactive,
#and requires the use of xv, xli or xzgv as an image viewer
.if defined(MAINTAINER_MODE) && !defined(BATCH)
TESTS+= display
.endif

check regression-test test: build
.for c in ${TESTS}
    @cd ${WRKSRC}/prog; ${SETENV} \
    LD_LIBRARY_PATH="${WRKSRC}/src/.libs:${LOCALBASE}/lib" \
    ${WRKSRC}/prog/alltests_reg ${c}
.endfor

.include <bsd.port.mk>