Changeset 100730


Ignore:
Timestamp:
Dec 21, 2012, 10:36:18 AM (6 years ago)
Author:
raimue@…
Message:

cross/i386-elf-binutils:
Switch to crossbinutils port group, update to version 2.23.1,
closes #37259 (maintainer timeout)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/cross/i386-elf-binutils/Portfile

    r90738 r100730  
    11# $Id$
    22
    3 PortSystem                      1.0
     3PortSystem      1.0
     4PortGroup       crossbinutils 1.0
    45
    5 name                            i386-elf-binutils
    6 version                         2.20
     6crossbinutils.setup i386-elf 2.23.1
     7revision        1
     8maintainers     gmail.com:jinksys
    79
    8 # Parameters for this port.
    9 set crossgcc-target i386-elf
     10checksums       rmd160  7ccebcdd634ba795fbcd5d7033d1b96db6edecc2 \
     11                sha256  2ab2e5b03e086d12c6295f831adad46b3e1410a3a234933a2e8fac66cb2e7a19
    1012
    11 description                     FSF Binutils for i386-elf cross development
    12 long_description        Free Software Foundation development toolchain ("binutils") for \
    13                                         i386-elf cross development.
    14 platforms                       darwin
    15 categories                      cross devel
    16 license                         GPL-3+
    17 maintainers                     gmail.com:jinksys
    18 homepage                        http://www.gnu.org/software/binutils/binutils.html
    19 master_sites            ftp://ftp.kernel.org/pub/linux/devel/binutils/ \
    20                                         http://ftp.kernel.org/pub/linux/devel/binutils/
    21 distname                        binutils-${version}
    22 use_bzip2                       yes
    23 checksums                       md5    ee2d3e996e9a2d669808713360fa96f8 \
    24                                         sha1   747e7b4d94bce46587236dc5f428e5b412a590dc \
    25                                         rmd160 284074e2453e517d036ffce2c0f3d56439e2e5c0
    26 
    27 depends_lib                     port:gettext
    28 
    29 # All cross ports violate the mtree layout.
    30 destroot.violate_mtree  yes
    31 
    32 # Download everything to binutils/
    33 dist_subdir                     binutils
    34 
    35 if {${os.platform} == "darwin" && ${os.major} >= 10} {
    36         patchfiles-append       patch-binutils__strings.c
    37 }
    38 # i386-dis.c:6670:21: fatal error: parser recursion limit reached, program too complex
    39 if {${configure.compiler} == "clang"} {
    40     configure.compiler llvm-gcc-4.2
    41 }
    42 
    43 # Build in a different directory, as advised in the README file.
    44 pre-configure           { system "cd ${workpath} && mkdir -p build"}
    45 configure.dir           ${workpath}/build
    46 configure.cmd           ${worksrcpath}/configure
    47 configure.args          --infodir='${prefix}/share/info' --target=${crossgcc-target} \
    48                                         --program-prefix=${crossgcc-target}- --mandir='${prefix}/share/man' \
    49                                         --disable-werror
    50 if {${os.platform} == "darwin" && ($build_arch == "x86_64" || $build_arch == "ppc64")} {
    51     configure.args-append --build=${build_arch}-apple-${os.platform}${os.version}
    52 }
    53 build.dir               ${workpath}/build
    54                                        
    55 # We don't want the etc module.
    56 post-extract {
    57         system "rm -rf ${worksrcpath}/etc"
    58 }
    59 
    60 post-patch {
    61         namespace eval crossgcc {}
    62 
    63         # Fix the info pages and related stuff.
    64         #
    65         # path: path to the doc directory (e.g. gas/doc/)
    66         # makefile: path to Makefile.in (e.g. gas/doc/Makefile.in)
    67         # name: name of the info page (e.g. as)
    68         # suffix: suffix of the souce page (texinfo or texi)
    69         proc crossgcc::fixinfo { path makefile name suffix } {
    70                 global crossgcc-target worksrcpath
    71 
    72                 # Fix the source
    73                 reinplace "s|setfilename ${name}.info|setfilename ${crossgcc-target}-${name}.info|g" \
    74                         ${worksrcpath}/${path}/${name}.${suffix}
    75                 reinplace "s|(${name})|(${crossgcc-target}-${name})|g" \
    76                         ${worksrcpath}/${path}/${name}.${suffix}
    77                 reinplace "s|@file{${name}}|@file{${crossgcc-target}-${name}}|g" \
    78                         ${worksrcpath}/${path}/${name}.${suffix}
    79                
    80                 # Fix the Makefile
    81                 reinplace "s|${name}.info|${crossgcc-target}-${name}.info|g" \
    82                         ${worksrcpath}/${makefile}
    83                 reinplace "s|${name}.${suffix}|${crossgcc-target}-${name}.${suffix}|g" \
    84                         ${worksrcpath}/${makefile}
    85                
    86                 # Rename the source
    87                 file rename ${worksrcpath}/${path}/${name}.${suffix} \
    88                         ${worksrcpath}/${path}/${crossgcc-target}-${name}.${suffix}
    89                
    90                 # Fix install-info's dir.
    91                 # (note: this may be effectless if there was no info dir to be fixed)
    92                 reinplace "s|--info-dir=\$(DESTDIR)\$(infodir)|--dir-file=\$(DESTDIR)\$(infodir)/${crossgcc-target}-dir|g" \
    93                         "${worksrcpath}/${makefile}"
    94         }
    95 
    96         # Fix the gettext files and related stuff.
    97         #
    98         # module: name of the module (e.g. gas)
    99         proc crossgcc::fixgettext { module } {
    100                 global crossgcc-target worksrcpath
    101 
    102                 if { [ file exists "${worksrcpath}/${module}/Makefile.in" ] } {
    103                         reinplace "s|@PACKAGE@|${crossgcc-target}-@PACKAGE@|g" \
    104                                 "${worksrcpath}/${module}/Makefile.in"
    105                 }
    106                 if { [ file exists "${worksrcpath}/${module}/doc/Makefile.in" ] } {
    107                         reinplace "s|@PACKAGE@|${crossgcc-target}-@PACKAGE@|g" \
    108                                 "${worksrcpath}/${module}/doc/Makefile.in"
    109                 }
    110                 if { [ file exists "${worksrcpath}/${module}/po/Make-in" ] } {
    111                         reinplace "s|@PACKAGE@|${crossgcc-target}-@PACKAGE@|g" \
    112                                 "${worksrcpath}/${module}/po/Make-in"
    113                 }
    114         }
    115 
    116         # gas/doc/as.texinfo
    117         crossgcc::fixinfo gas/doc/ gas/doc/Makefile.in as texinfo
    118 
    119         # bfd/doc/bfd.texinfo
    120         crossgcc::fixinfo bfd/doc/ bfd/doc/Makefile.in bfd texinfo
    121 
    122         # binutils/doc/binutils.texi
    123         crossgcc::fixinfo binutils/doc/ binutils/doc/Makefile.in binutils texi
    124 
    125         # gprof/gprof.texi
    126         crossgcc::fixinfo gprof/ gprof/Makefile.in gprof texi
    127 
    128         # ld/ld.texinfo
    129         crossgcc::fixinfo ld/ ld/Makefile.in ld texinfo
    130        
    131         # gettext stuff.
    132         crossgcc::fixgettext bfd
    133         crossgcc::fixgettext binutils
    134         crossgcc::fixgettext gas
    135         crossgcc::fixgettext gprof
    136         crossgcc::fixgettext ld
    137         crossgcc::fixgettext opcodes
    138 }
    139 
    140 post-destroot {
    141         # Installing (host) libiberty was a mistake.
    142         foreach f [glob -directory "${destroot}${prefix}/lib" libiberty.a */libiberty.a] {
    143         file delete $f
    144     }
    145 }
    146 
    147 livecheck.type  freecode
    148 livecheck.name  binutils
     13configure.args-append --disable-werror
Note: See TracChangeset for help on using the changeset viewer.