aboutsummaryrefslogtreecommitdiffstats
path: root/astro/gpscorrelate/Makefile
blob: 4e7225584a5b0eee0cdaf3347c0faab0ea8306e4 (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
# Created by: Lukas Maly
# $FreeBSD$

PORTNAME=   gpscorrelate
PORTVERSION=    1.6.1
PORTREVISION=   1
CATEGORIES= astro geography
MASTER_SITES=   GH
DIST_SUBDIR=    repacked

MAINTAINER= ports@FreeBSD.org
COMMENT=    Correlate digital camera photos with GPS data in GPX format

LICENSE=    GPLv2

LIB_DEPENDS=    libexiv2.so:${PORTSDIR}/graphics/exiv2 \
        libgtkmm-2.4.so:${PORTSDIR}/x11-toolkits/gtkmm24

OPTIONS_DEFINE= DOCS

USE_GITHUB= yes
GH_ACCOUNT= freefoote
GH_COMMIT=  a36646b

USES=       gmake pkgconfig
USE_GNOME=  libxml2

PORTDOCS=   *
PLIST_FILES=    bin/gpscorrelate bin/gpscorrelate-gui \
        man/man1/gpscorrelate.1.gz man/man1/gpscorrelate-gui.1.gz

.include <bsd.port.options.mk>

post-patch:
    @${REINPLACE_CMD} -e \
        's|^CFLAGS|#CFLAGS| ; \
         s|^override CFLAGS|override IFLAGS| ; \
         s|gtk+-2.0)|gtk+-2.0 exiv2)| ; \
         s|-I/usr/include/exiv2|| ; \
         s|-lexiv2|| ; \
         /^all:/s|gpscorrelate.1|| ; \
         s|g++ $$(OFLAGS)|$$(CXX) $$(OFLAGS)| ; \
         s|g++ $$(CFLAGS)|$$(CXX) $$(CXXFLAGS) $$(IFLAGS)| ; \
         s|gcc $$(CFLAGS)|$$(CC) $$(CFLAGS) $$(IFLAGS)|' \
        ${WRKSRC}/Makefile

do-install:
    ${INSTALL_PROGRAM} ${WRKSRC}/gpscorrelate ${STAGEDIR}${PREFIX}/bin
    ${INSTALL_PROGRAM} ${WRKSRC}/gpscorrelate-gui ${STAGEDIR}${PREFIX}/bin
    ${INSTALL_MAN} ${FILESDIR}/gpscorrelate.1 ${STAGEDIR}${MANPREFIX}/man/man1
    ${LN} -sf gpscorrelate.1 ${STAGEDIR}${MANPREFIX}/man/man1/gpscorrelate-gui.1
.if ${PORT_OPTIONS:MDOCS}
    @${MKDIR} ${STAGEDIR}${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/README.md ${STAGEDIR}${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/RELEASES ${STAGEDIR}${DOCSDIR}
    @${MKDIR} ${STAGEDIR}${DOCSDIR}/html
    ${INSTALL_DATA} ${WRKSRC}/doc/*.html ${STAGEDIR}${DOCSDIR}/html
    ${INSTALL_DATA} ${WRKSRC}/doc/*.png ${STAGEDIR}${DOCSDIR}/html
.endif

.include <bsd.port.mk>