Ignore:
Timestamp:
Sep 19, 2014, 2:29:16 AM (5 years ago)
Author:
ryandesign@…
Message:

colorer: allow compiling with clang; use requested C++ library and revbump to rebuild with libc++ on applicable systems; move insertion of -arch flags to patch files; become maintainer

Location:
trunk/dports/textproc/colorer
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/textproc/colorer/Portfile

    r125101 r125503  
    66name            colorer
    77version         take5.be5
    8 revision        1
     8revision        2
    99license         MPL-1.1 GPL-2 LGPL-2.1
    1010categories      textproc devel
    1111platforms       darwin
    12 maintainers     nomaintainer
     12maintainers     ryandesign openmaintainer
    1313description     A library that provides source text syntax highlighting services
    1414
     
    3838
    3939patchfiles      patch-Makefile.in.diff \
     40                patch-src-colorer-makefile.gcc.diff \
    4041                patch-src-libcolorer-makefile.gcc.diff
    4142
    4243post-patch {
    43     # Use makefile.macos for colorer
    44     reinplace {/\/colorer/s/gcc/macos/} ${worksrcpath}/Makefile.in
    45 
    4644    # error: cast from 'int*' to 'int' loses precision
    4745    reinplace s/int(/bool(/ ${worksrcpath}/src/shared/unicode/BitArray.cpp
     
    4947    # Do not force installation as root
    5048    reinplace {s/-g 0 -o 0//} ${worksrcpath}/Makefile.in
    51 
    52     reinplace "/^CPPFLAGS/s:\$: [get_canonical_archflags cc]:" \
    53         ${worksrcpath}/src/shared/makefile.colorer.gcc
    54     reinplace -E "/^(LIB)?FLAGS/s:\$: [get_canonical_archflags ld]:" \
    55         ${worksrcpath}/src/colorer/makefile.macos \
    56         ${worksrcpath}/src/libcolorer/makefile.gcc
    5749}
    58 
    59 # error: taking the address of a temporary object of type 'DString'
    60 compiler.blacklist *clang*
    6150
    6251configure.cmd   sh src/libcolorer/linux/configure
     
    6554build.target colorer
    6655# Yes, this build system uses "CPP" for the C compiler and "LINK" for the C++ compiler.
    67 build.args          CPP=${configure.cc} \
     56build.args          ARCHFLAGS="[get_canonical_archflags]" \
     57                    CPP=${configure.cc} \
     58                    CPPFLAGS_CUSTOM="[get_canonical_archflags] -Wno-error=address-of-temporary" \
     59                    FLAGS= \
     60                    LIBINC="/usr/lib/${configure.cxx_stdlib}.dylib" \
    6861                    LINK=${configure.cxx} \
    6962                    prefix=${prefix}
  • trunk/dports/textproc/colorer/files/patch-src-libcolorer-makefile.gcc.diff

    r125101 r125503  
    22Create library with -dynamiclib
    33Use -install_name
     4Use -arch flags
    45--- src/libcolorer/makefile.gcc.orig    2006-11-24 17:14:40.000000000 -0600
    5 +++ src/libcolorer/makefile.gcc 2014-09-04 22:14:17.000000000 -0500
     6+++ src/libcolorer/makefile.gcc 2014-09-18 20:48:15.000000000 -0500
    67@@ -1,5 +1,5 @@
    78 
     
    1617 LIBINC = -lstdc++
    1718-LIBFLAGS = $(coreobjects) -shared -o $(TARGET) $(LIBINC)
    18 +LIBFLAGS = $(coreobjects) -dynamiclib -install_name $(prefix)/lib/$(TARGET) -o $(TARGET) $(LIBINC)
     19+LIBFLAGS = $(coreobjects) -dynamiclib -install_name $(prefix)/lib/$(TARGET) -o $(TARGET) $(LIBINC) $(ARCHFLAGS)
    1920 
    2021 
Note: See TracChangeset for help on using the changeset viewer.