Ticket #34636: Portfile

File Portfile, 2.0 KB (added by jose.exposito89@…, 12 years ago)
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 86838 2011-11-05 14:34:11Z devans@macports.org $
3
4PortSystem      1.0
5PortGroup       cmake 1.0
6
7name            podofo
8version         0.9.1
9license         GPL-2 LGPL-2
10categories      graphics
11maintainers     devans openmaintainer
12platforms       darwin
13homepage        http://podofo.sourceforge.net/
14master_sites    sourceforge
15
16description \
17    PoDoFo is a library to work with the PDF file format.
18
19long_description \
20    PoDoFo is a library to work with the PDF file format. The PoDoFo library \
21    is a free, portable C++ library which includes classes to parse PDF files and \
22    modify their contents into memory. The changes can be written back to disk easily. \
23    The parser can also be used to extract information from a PDF file.
24
25checksums       sha1    d04c26b93dcf5f82a8dd90e02df6de95fb98ef47 \
26                rmd160  4d65f78cf4929eda44b5f27d518d104380e58160
27
28depends_build   port:cmake
29
30depends_lib     port:fontconfig \
31                port:libpng \
32                port:tiff \
33                port:cppunit \
34                port:openssl \
35                port:lua
36
37configure.cmd   cmake
38configure.args-append -G \"Unix Makefiles\" -DWANT_FONTCONFIG:BOOL=TRUE -DPODOFO_BUILD_SHARED:BOOL=TRUE -DCMAKE_INSTALL_PREFIX=${prefix} -DCMAKE_INCLUDE_PATH=${prefix}/include -DCMAKE_LIBRARY_PATH=${prefix}/lib -DCMAKE_BUILD_TYPE=RELEASE
39
40build.target podofo_shared
41
42pre-build {
43    if {[file exists ${prefix}/lib/libpodofo.dylib]} {
44        ui_error "${name} cannot be built while a previous version is installed and active."
45        ui_error "Please deactivate the currently active version of ${name} first."
46        return -code error "previous ${name} version active"
47    }
48}
49
50destroot {
51    system "cd ${worksrcpath}/src ; make install DESTDIR=${destroot}"
52}
53
54livecheck.type  regex
55livecheck.url   http://podofo.sourceforge.net/download.html
56livecheck.regex "${name}-(\\d+(?:\\.\\d+)*)${extract.suffix}"