source: trunk/dports/textproc/colorer/Portfile @ 125088

Last change on this file since 125088 was 125088, checked in by ryandesign@…, 5 years ago

colorer: add modeline

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.1 KB
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 125088 2014-09-05 03:12:37Z ryandesign@macports.org $
3
4PortSystem      1.0
5
6name            colorer
7version         take5.be5
8revision        1
9license         MPL-1.1 GPL-2 LGPL-2.1
10categories      textproc devel
11platforms       darwin
12maintainers     nomaintainer
13description     A library that provides source text syntax highlighting services
14
15long_description \
16    Colorer take5 is a syntax highlighting and text parsing library, that \
17    provides services of text parsing in host editor systems in real-time and \
18    transforming results into colored text. Result information allows to \
19    search and build outlined lists of functions, structures, and to search \
20    and indent programming language constructions (brackets, paired tags).
21
22homepage        http://colorer.sourceforge.net/
23master_sites    sourceforge:project/colorer/Library%20sources/Colorer-${version}
24distname        Colorer-${version}
25use_zip         yes
26
27checksums       md5     075ede3afc260766fe13c71850a5e6c0 \
28                sha1    53cd454779621c09954ce70b6d06a4e1903ed6af \
29                rmd160  87c9ad2b99343c19e74211e658eb73ebcf0bcea9
30
31post-extract {
32    copy \
33        ${worksrcpath}/src/libcolorer/linux/Makefile.in \
34        ${worksrcpath}
35}
36
37variant universal {}
38
39patchfiles      patch-Makefile.in.diff
40
41post-patch {
42    # Use makefile.macos for colorer
43    reinplace {/\/colorer/s/gcc/macos/} ${worksrcpath}/Makefile.in
44
45    # error: cast from 'int*' to 'int' loses precision
46    reinplace s/int(/bool(/ ${worksrcpath}/src/shared/unicode/BitArray.cpp
47
48    # Libraries extension is ".dylib" on Darwin, not ".so"
49    reinplace {s/\.so/.dylib/} \
50        ${worksrcpath}/Makefile.in \
51        ${worksrcpath}/src/libcolorer/makefile.gcc
52
53    # The flag to build dynamic libraries on Darwin is -dynamiclib
54    # Furthermore we need to write down libcolorer install name
55    reinplace \
56        "s:-shared:-dynamiclib -install_name ${prefix}/lib/\$(TARGET):" \
57        ${worksrcpath}/src/libcolorer/makefile.gcc
58
59    # Do not force installation as root
60    reinplace {s/-g 0 -o 0//} ${worksrcpath}/Makefile.in
61
62    # Install documentation in an unversioned directory
63    reinplace s:doc/colorer-take5:doc/colorer: ${worksrcpath}/Makefile.in
64
65    reinplace "/^CPPFLAGS/s:\$: [get_canonical_archflags cc]:" \
66        ${worksrcpath}/src/shared/makefile.colorer.gcc
67    reinplace -E "/^(LIB)?FLAGS/s:\$: [get_canonical_archflags ld]:" \
68        ${worksrcpath}/src/colorer/makefile.macos \
69        ${worksrcpath}/src/libcolorer/makefile.gcc
70}
71
72# error: taking the address of a temporary object of type 'DString'
73compiler.blacklist *clang*
74
75configure.cmd   sh src/libcolorer/linux/configure
76configure.args  --srcdir=.
77
78build.target colorer
79# Yes, this build system uses "CPP" for the C compiler and "LINK" for the C++ compiler.
80build.args          CPP=${configure.cc} \
81                    LINK=${configure.cxx}
82use_parallel_build yes
83
84destroot.destdir    prefix=${destroot}${prefix}
85destroot.args       -B
86
87livecheck.type  regex
88livecheck.url   ${homepage}whatsnew/history.html
89livecheck.regex {<h2>([^,]*), Latest}
Note: See TracBrowser for help on using the repository browser.