Changeset 75349 for trunk/dports/cross


Ignore:
Timestamp:
Jan 23, 2011, 1:56:35 AM (9 years ago)
Author:
landonf@…
Message:

Install the target-specific libbfd and libiberty in ${prefix}/avr/host.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/cross/avr-binutils/Portfile

    r72086 r75349  
    44name                            avr-binutils
    55version                         2.20
     6revision                        1
    67
    78# Parameters for this port.
     
    4445                                        --infodir='${prefix}/share/info' \
    4546                                        --disable-nls \
    46                                         --disable-install-libiberty \
    4747                                        --target=${crossgcc-target} \
    4848                                        --program-prefix=${crossgcc-target}- \
    49                                         --mandir='${prefix}/share/man'
     49                                        --mandir='${prefix}/share/man' \
     50                                        --enable-install-libiberty \
     51                                        --enable-install-libbfd
     52
    5053
    5154if {$build_arch != "" && ${os.platform} == "darwin"} {
     
    6366post-patch {
    6467        namespace eval crossgcc {}
     68
     69    # Install avr-compatible libbfd/libiberty in the avr directory
     70    reinplace "s|bfdlibdir=.*|bfdlibdir='${prefix}/avr/host/lib'|g" \
     71        ${worksrcpath}/bfd/configure \
     72        ${worksrcpath}/opcodes/configure
     73    reinplace "s|bfdincludedir=.*|bfdincludedir='${prefix}/avr/host/include'|g"  \
     74        ${worksrcpath}/bfd/configure \
     75        ${worksrcpath}/opcodes/configure
     76
     77    reinplace "s|libdir = .*|libdir = \"${prefix}/avr/host/lib\"|g"  \
     78        ${worksrcpath}/libiberty/Makefile.in
     79    reinplace "s|MULTIOSDIR = .*|MULTIOSDIR = |g"  \
     80        ${worksrcpath}/libiberty/Makefile.in
    6581
    6682        # Fix the info pages and related stuff.
     
    142158
    143159post-destroot {
    144         # Installing (host) libiberty was a mistake.
    145     foreach f [glob -directory "${destroot}${prefix}/lib" libiberty.a */libiberty.a] {
    146         file delete $f
    147     }
     160    file rename "${destroot}/${prefix}/lib/libiberty.a" "${destroot}/${prefix}/avr/host/lib/"
    148161}
    149 
Note: See TracChangeset for help on using the changeset viewer.