aboutsummaryrefslogtreecommitdiffstats
path: root/graphics/lensfun/Makefile
blob: 5e8c95f4caebc1fcd5b76573f036fe4761f8cfe3 (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
# New ports collection makefile for:    lensfun
# Date created:             Mon 25 May 2009 04:45:47 MSD
# Whom:                 dindin@dindin.ru
#
# $FreeBSD$
#

PORTNAME=   lensfun
PORTVERSION=    0.2.5
PORTREVISION=   1
CATEGORIES= graphics
MASTER_SITES=   BERLIOS

MAINTAINER= dindin@dindin.ru
COMMENT=    Library for fixing lens geometry distortion

LIB_DEPENDS=    png:${PORTSDIR}/graphics/png

USE_LDCONFIG=   yes
USE_GMAKE=  yes
USE_PYTHON= yes
USE_BZIP2=  yes
USE_GNOME=  glib20
MAKEFILE=   GNUmakefile
LIBVERSION= 2

LDFLAGS+=   -L${LOCALBASE}/lib ${PTHREAD_LIBS}
CXXFLAGS+=  -I${LOCALBASE}/include

HAS_CONFIGURE=  yes
CONFIGURE_ENV=  LDFLAGS="${LDFLAGS}" CPPFLAGS="${CPPFLAGS}"
CONFIGURE_ARGS= --prefix=${PREFIX} --target=${TARGET} --vectorization=SSE

PLIST_SUB+= PORTVERSION=${PORTVERSION} LIBVERSION=${LIBVERSION}

post-patch:
    @${REINPLACE_CMD} -e '1s|#!/usr/bin/python|#!/usr/bin/env python|' \
        -e 's|make --version|gmake --version|' \
        -e '/add_config_mak.*DOXYGEN/ d' \
        ${WRKSRC}/configure
    @${REINPLACE_CMD} -e 's|{_libdir}/pkgconfig|{_libdir}/../libdata/pkgconfig|' \
        ${WRKSRC}/build/lensfun.spec.in
    @${REINPLACE_CMD} -e 's|CONF_LIBDIR)pkgconfig|CONF_LIBDIR)../libdata/pkgconfig|g' \
        ${WRKSRC}/build/tibs/compiler/pkgconfig.mak

post-install:
    @${LN} -sf ${PREFIX}/lib/lib${PORTNAME}.so ${PREFIX}/lib/lib${PORTNAME}.so.${LIBVERSION}

.include <bsd.port.mk>