diff --git a/cross/powerpc-binutils/Portfile b/cross/powerpc-binutils/Portfile new file mode 100644 index 00000000000..f5c425f962a --- /dev/null +++ b/cross/powerpc-binutils/Portfile @@ -0,0 +1,74 @@ +# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 + +PortSystem 1.0 +PortGroup crossbinutils 1.0 + +name powerpc-binutils +version 2.45 +revision 0 +maintainers {@kamischi web.de:karl-michael.schindler} \ + openmaintainer + +if {$subport eq $name} { + # Download sources and install docs for all subports + crossbinutils.setup powerpc ${version} + depends_build + depends_lib + platforms any + supported_archs noarch + use_configure no + build {} + destroot {} +} + +# tried, but not working targets: amigaos aros morphos +foreach ostarget {linux aix eabi elf darwin freebsd netbsd openbsd} { + subport powerpc-${ostarget}-binutils { + crossbinutils.setup powerpc-${ostarget} ${version} + # Depend on base package for installing the docs + depends_lib port:$name + configure.args-append --disable-werror + if {${ostarget} eq "linux"} { + depends_build-append port:bison + } + # Delete docs since already installed by the base package + # Resolves clash about identical docs from each subport + post-destroot { + delete ${destroot}${prefix}/share/doc/powerpc-binutils + } + } +} + +subport powerpc-embedded-binutils { + crossbinutils.setup powerpc-embedded ${version} + configure.args-append \ + --target=powerpc-unknown-elf \ + --disable-werror + + post-destroot { + # See comment above about deleting docs + delete ${destroot}${prefix}/share/doc/powerpc-binutils + file rename ${destroot}${prefix}/powerpc-unknown-elf/bin \ + ${destroot}${prefix}/powerpc-embedded + file rename ${destroot}${prefix}/powerpc-unknown-elf/lib \ + ${destroot}${prefix}/powerpc-embedded + file delete ${destroot}${prefix}/powerpc-unknown-elf + } +} + +subport powerpc-wii-binutils { + crossbinutils.setup powerpc-wii ${version} + configure.args-append \ + --target=powerpc-eabi \ + --disable-werror + + post-destroot { + # See comment above about deleting docs + delete ${destroot}${prefix}/share/doc/powerpc-binutils + file rename ${destroot}${prefix}/powerpc-eabi/bin \ + ${destroot}${prefix}/powerpc-wii + file rename ${destroot}${prefix}/powerpc-eabi/lib \ + ${destroot}${prefix}/powerpc-wii + file delete ${destroot}${prefix}/powerpc-eabi + } +} diff --git a/cross/ppc-linux-binutils/Portfile b/cross/ppc-linux-binutils/Portfile index abb28b44943..4b816f5bf4f 100644 --- a/cross/ppc-linux-binutils/Portfile +++ b/cross/ppc-linux-binutils/Portfile @@ -2,7 +2,10 @@ PortSystem 1.0 PortGroup crossbinutils 1.0 +PortGroup obsolete 1.0 +replaced_by powerpc-linux-binutils crossbinutils.setup ppc-linux 2.34 -revision 1 -maintainers nomaintainer +revision 2 +maintainers {@kamischi web.de:karl-michael.schindler} \ + openmaintainer