diff options
author | Eole | 2015-10-23 13:48:10 +0200 |
---|---|---|
committer | Eole | 2015-10-23 13:48:10 +0200 |
commit | 946463180e32e84893a03950a014fd06c0ab37ea (patch) | |
tree | e3b3ad2cd74ce72df6977fcb054ab26859fea67b | |
download | aur-946463180e32e84893a03950a014fd06c0ab37ea.tar.gz |
init
-rw-r--r-- | .SRCINFO | 23 | ||||
-rw-r--r-- | PKGBUILD | 54 |
2 files changed, 77 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..c32bc97df627 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,23 @@ +pkgbase = cross-mips-elf-gcc + pkgdesc = The GNU Compiler Collection for the MIPS-elf architecture + pkgver = 5.2.0 + pkgrel = 1 + url = http://www.gnu.org/software/gcc/ + arch = i686 + arch = x86_64 + license = GPL + depends = mpfr + depends = gmp + depends = libmpc + depends = sh + depends = cross-mips-elf-binutils + options = !ccache + options = !distcc + options = !emptydirs + options = !libtool + options = !strip + source = ftp://ftp.gnu.org/gnu/gcc/gcc-5.2.0/gcc-5.2.0.tar.bz2 + md5sums = a51bcfeb3da7dd4c623e27207ed43467 + +pkgname = cross-mips-elf-gcc + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..36f80af8cd30 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,54 @@ +# Contributor: Eole Dev < Eole Dev at-symbol outlook . fr> +pkgname=cross-mips-elf-gcc +_pkgname=gcc +_target="mips-elf" +pkgver=5.2.0 +pkgrel=1 +pkgdesc="The GNU Compiler Collection for the MIPS-elf architecture" +url="http://www.gnu.org/software/gcc/" +arch=('i686' 'x86_64') +license=('GPL') +depends=('mpfr' 'gmp' 'libmpc' 'sh' "cross-${_target}-binutils") +options=('!ccache' '!distcc' '!emptydirs' '!libtool' '!strip') +source=("ftp://ftp.gnu.org/gnu/gcc/gcc-${pkgver}/${_pkgname}-${pkgver}.tar.bz2") +md5sums=('a51bcfeb3da7dd4c623e27207ed43467') +_sysroot="/usr/lib/cross-${_target}" + +prepare() { + cd ${srcdir}/${_pkgname}-${pkgver} +} + +build() { + cd ${srcdir}/${_pkgname}-${pkgver} + + ./configure \ + --prefix=${_sysroot} \ + --bindir=/usr/bin --program-prefix=${_target}- \ + --with-sysroot=${_sysroot} \ + --target=${_target} \ + --with-gnu-as --with-gnu-ld + + make all-gcc +} + +package() { + cd ${srcdir}/${_pkgname}-${pkgver} + + make DESTDIR=${pkgdir} install-gcc + + msg "Removing duplicit files..." + # remove these files as they are already in the system + # (with native gcc) + rm -Rf ${pkgdir}${_sysroot}/{man,info} + # remove conflicting binaries + find ${pkgdir}/usr/bin/ -type f -not -name "${_target}-*" -delete + + msg "Creating out-of-path executables..." + # symlink executables to single directory with no-arch-prefix name + mkdir -p ${pkgdir}/usr/bin/cross/${_target}/; + cd ${pkgdir}/usr/bin/cross/${_target}/; + for bin in ${pkgdir}/usr/bin/${_target}-*; do + bbin=`basename "$bin"`; + ln -s "/usr/bin/${bbin}" `echo "$bbin" | sed "s#^${_target}-##"`; + done +} |