[80381] trunk/dports/cross

jmr at macports.org jmr at macports.org
Mon Jul 11 00:49:40 PDT 2011


Revision: 80381
          http://trac.macports.org/changeset/80381
Author:   jmr at macports.org
Date:     2011-07-11 00:49:40 -0700 (Mon, 11 Jul 2011)
Log Message:
-----------
New port: arm-elf-gdb (#25747)

Added Paths:
-----------
    trunk/dports/cross/arm-elf-gdb/
    trunk/dports/cross/arm-elf-gdb/Portfile

Added: trunk/dports/cross/arm-elf-gdb/Portfile
===================================================================
--- trunk/dports/cross/arm-elf-gdb/Portfile	                        (rev 0)
+++ trunk/dports/cross/arm-elf-gdb/Portfile	2011-07-11 07:49:40 UTC (rev 80381)
@@ -0,0 +1,96 @@
+# $Id$
+
+PortSystem              1.0
+
+name                    arm-elf-gdb
+version                 7.1
+categories              cross devel
+maintainers             koostech.com:billy openmaintainer
+description             GDB for the ARM processors
+long_description        arm-elf-gdb is a version of the GNU Debugger \
+                        for the arm-elf toolchain.
+homepage                http://www.gnu.org/software/gdb/gdb.html
+platforms               darwin
+master_sites            gnu:gdb
+distname                gdb-${version}
+dist_subdir             gdb
+use_bzip2               yes
+checksums               md5 21dce610476c054687b52770d2ddc657 \
+                        sha1 417e2e637a296ea0e1cdddf56233311b8708fa19 \
+                        rmd160 800d224496240a360c996e588490f2d87367c4e3
+
+set crossgdb-target arm-elf
+
+# Build in a different directory, as advised in the README file.
+pre-configure   {
+        file mkdir "${workpath}/build"
+}
+configure.dir           ${workpath}/build
+configure.cmd           ${workpath}/gdb-${version}/configure
+
+configure.args          --mandir=${prefix}/share/man \
+                        --infodir=${prefix}/share/info \
+                        --target=${crossgdb-target} \
+                        --enable-interwork \
+                        --enable-multilib
+
+build.dir               ${workpath}/build
+
+post-patch {
+        namespace eval crossgdb {}
+
+        # Fix the info pages and related stuff.
+        #
+        # path: path to the doc directory (e.g. gas/doc/)
+        # makefile: path to Makefile.in (e.g. gas/doc/Makefile.in)
+        # name: name of the info page (e.g. as)
+        # suffix: suffix of the souce page (texinfo or texi)
+                proc crossgdb::fixinfo { path makefile name suffix } {
+                        global crossgdb-target worksrcpath
+
+                        # Fix the source
+                        reinplace "s|setfilename ${name}.info|setfilename ${crossgdb-target}-${name}.info|g" \
+                                ${worksrcpath}/${path}/${name}.${suffix}
+                        reinplace "s|(${name})|(${crossgdb-target}-${name})|g" \
+                                ${worksrcpath}/${path}/${name}.${suffix}
+                        reinplace "s|@file{${name}}|@file{${crossgdb-target}-${name}}|g" \
+                                ${worksrcpath}/${path}/${name}.${suffix}
+
+                        # Fix the Makefile
+                        reinplace "s| ${name}.info| ${crossgdb-target}-${name}.info|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s|/${name}.info|/${crossgdb-target}-${name}.info|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s|^${name}.info|${crossgdb-target}-${name}.info|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s| ${name}.pod| ${crossgdb-target}-${name}.pod|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s|/${name}.pod|/${crossgdb-target}-${name}.pod|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s|^${name}.pod|${crossgdb-target}-${name}.pod|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s| ${name}.${suffix}| ${crossgdb-target}-${name}.${suffix}|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s|/${name}.${suffix}|/${crossgdb-target}-${name}.${suffix}|g" \
+                                ${worksrcpath}/${makefile}
+                        reinplace "s|^${name}.${suffix}|${crossgdb-target}-${name}.${suffix}|g" \
+                                ${worksrcpath}/${makefile}
+
+                        # Rename the source
+                        file rename ${worksrcpath}/${path}/${name}.${suffix} \
+                                ${worksrcpath}/${path}/${crossgdb-target}-${name}.${suffix}
+
+                        # Fix install-info's dir.
+                        # (note: this may be effectless if there was no info dir to be fixed)
+                        reinplace "s|--info-dir=\$(DESTDIR)\$(infodir)|--dir-file=\$(DESTDIR)\$(infodir)/${crossgdb-target}-gdb-dir|g" \
+                                "${worksrcpath}/${makefile}"
+                }
+        # etc/standards.info
+        crossgdb::fixinfo etc/ etc/Makefile.in standards info
+
+}
+
+post-destroot {
+        # Don't overwrite libiberty installed by gcc.
+        file delete "${destroot}/${prefix}/lib/${build_arch}/libiberty.a"
+}


Property changes on: trunk/dports/cross/arm-elf-gdb/Portfile
___________________________________________________________________
Added: svn:keywords
   + Id
Added: svn:eol-style
   + native
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110711/7ee8c5e4/attachment-0001.html>


More information about the macports-changes mailing list