Ignore:
Timestamp:
Jul 17, 2013, 10:55:36 PM (6 years ago)
Author:
cal@…
Message:

HexFiend: Provide separate subport for HexFiend.framework, closes #39213

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/editors/hexfiend/Portfile

    r95755 r108291  
    1818license         BSD
    1919
    20 description     HexFiend is a fast and clever hex editor
     20# required to build on < Lion
     21patchfiles      framework-sources-HFByteArrayEditScript.m.patch
     22platform darwin 11 {
     23    patchfiles-delete \
     24                framework-sources-HFByteArrayEditScript.m.patch
     25}
    2126
    2227long_description \n\
     
    3237    * Smooth scrolling. No separate pages - scroll like any text document.
    3338
    34 # required to build on < Lion
    35 patchfiles      framework-sources-HFByteArrayEditScript.m.patch
    36 platform darwin 11 {
    37     patchfiles-delete \
    38                 framework-sources-HFByteArrayEditScript.m.patch
     39if {${subport} eq ${name}} {
     40    description     HexFiend is a fast and clever hex editor
     41
     42    post-patch {
     43        # this is required for builds on 32 bit systems, because NSTag is
     44        # a signed integer and these values (NSUTF16BigEndianStringEncoding and
     45        # NSUTF16LittleEndianStringEncoding) both have the MSB set making them
     46        # not representable in signed 32 bit integers.
     47        # Applying these on 64 bit systems is safe, too, because the leading
     48        # 4 bytes will be cut off by a cast.
     49        reinplace "s/2415919360/-1879047936/g" ${worksrcpath}/English.lproj/MainMenu.xib
     50        reinplace "s/2483028224/-1811939072/g" ${worksrcpath}/English.lproj/MainMenu.xib
     51    }
     52
     53    xcode.target        HexFiend_2
     54    xcode.configuration Release
     55
     56    destroot {
     57        copy "${worksrcpath}/build/Release/Hex Fiend.app" ${destroot}${applications_dir}
     58        xinstall -d ${destroot}${prefix}/share/doc/${name}
     59        xinstall -m 644 ${worksrcpath}/License.txt ${destroot}${prefix}/share/doc/${name}
     60    }
    3961}
    4062
    41 post-patch {
    42     # this is required for builds on 32 bit systems, because NSTag is a signed
    43     # integer and these values (NSUTF16BigEndianStringEncoding and
    44     # NSUTF16LittleEndianStringEncoding) both have the MSB set making them not
    45     # representable in signed 32 bit integers.
    46     # Applying these on 64 bit systems is safe, too, because the leading 4 bytes
    47     # will be cut off by a cast.
    48     reinplace "s/2415919360/-1879047936/g" ${worksrcpath}/English.lproj/MainMenu.xib
    49     reinplace "s/2483028224/-1811939072/g" ${worksrcpath}/English.lproj/MainMenu.xib
     63subport HexFiend-framework {
     64    description         The HexFiend Framework is an embeddable Cocoa hex editor component from the HexFiend editor
     65
     66    xcode.target        HexFiend_Framework
     67    xcode.configuration Release
     68
     69    destroot {
     70        copy "${worksrcpath}/build/Release/HexFiend.framework" ${destroot}${frameworks_dir}
     71        set framework_lib ${frameworks_dir}/HexFiend.framework/Versions/A/HexFiend
     72        system "install_name_tool -id ${framework_lib} ${destroot}${framework_lib}"
     73    }
    5074}
    51 
    52 xcode.target        HexFiend_2
    53 xcode.configuration Release
    54 
    55 destroot {
    56     copy "${worksrcpath}/build/Release/Hex Fiend.app" ${destroot}${applications_dir}
    57     xinstall -d ${destroot}${prefix}/share/doc/${name}
    58     xinstall -m 644 ${worksrcpath}/License.txt ${destroot}${prefix}/share/doc/${name}
    59 }
    60 
Note: See TracChangeset for help on using the changeset viewer.