summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Boocha2017-09-13 09:17:46 +0800
committerMarc Boocha2017-09-13 09:17:46 +0800
commita39ea9768c5eab05e2031f4252943cdeab6b4714 (patch)
tree4364d738640e84d6e545806992a19a0313809346
downloadaur-a39ea9768c5eab05e2031f4252943cdeab6b4714.tar.gz
initailize package
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD53
-rw-r--r--libiberty-ignore-cflags.patch16
3 files changed, 84 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..3fd51115d9ac
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = x86_64-elf-binutils
+ pkgdesc = A set of programs to assemble and manipulate binary and object files for the x86_64-elf target
+ pkgver = 2.29
+ pkgrel = 1
+ url = http://www.gnu.org/software/binutils/
+ arch = x86_64
+ license = GPL
+ depends = zlib
+ source = http://mirrors.kernel.org/gnu/binutils/binutils-2.29.tar.xz
+ source = libiberty-ignore-cflags.patch
+ sha256sums = 0b871e271c4c620444f8264f72143b4d224aa305306d85dd77ab8dce785b1e85
+ sha256sums = 8b2aea00e98f7c311b1d0fb14e4b435a03c65fde32bc992c924edb6fa7b83c9c
+
+pkgname = x86_64-elf-binutils
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..f8d78f2aa7ea
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,53 @@
+# Maintainer: Marc Boocha <marcboocha@gmail.com>
+
+_target=x86_64-elf
+pkgname=$_target-binutils
+pkgver=2.29
+pkgrel=1
+pkgdesc='A set of programs to assemble and manipulate binary and object files for the x86_64-elf target'
+arch=(x86_64)
+url='http://www.gnu.org/software/binutils/'
+license=(GPL)
+depends=(zlib)
+source=("http://mirrors.kernel.org/gnu/binutils/binutils-$pkgver.tar.xz"
+ "libiberty-ignore-cflags.patch")
+sha256sums=('0b871e271c4c620444f8264f72143b4d224aa305306d85dd77ab8dce785b1e85'
+ '8b2aea00e98f7c311b1d0fb14e4b435a03c65fde32bc992c924edb6fa7b83c9c')
+_basedir=binutils-$pkgver
+
+prepare() {
+ cd $_basedir
+
+ patch -p1 -i $srcdir/libiberty-ignore-cflags.patch
+
+ mkdir $srcdir/binutils-build
+}
+
+build() {
+ cd binutils-build
+
+ $srcdir/$_basedir/configure \
+ --target=$_target \
+ --with-sysroot=/usr/$_target \
+ --prefix=/usr \
+ --disable-nls \
+ --disable-werror
+
+ make
+}
+
+check() {
+ cd binutils-build
+
+ # do not abort on errors - manually check log files
+ make -k check
+}
+
+package() {
+ cd binutils-build
+
+ make DESTDIR="$pkgdir" install
+
+ # Remove info and make since it expected already present by host compiler
+ rm "$pkgdir"/usr/share/{info,gcc}
+}
diff --git a/libiberty-ignore-cflags.patch b/libiberty-ignore-cflags.patch
new file mode 100644
index 000000000000..ddef5a472478
--- /dev/null
+++ b/libiberty-ignore-cflags.patch
@@ -0,0 +1,16 @@
+diff -p1 -r a/libiberty/configure b/libiberty/configure
+*** a/libiberty/configure Tue Jul 4 20:43:21 2017
+--- b/libiberty/configure Fri Aug 25 01:41:25 2017
+***************
+*** 10,11 ****
+--- 10,19 ----
+ # gives unlimited permission to copy, distribute and modify it.
++
++ ## ---------------------------------------------------------- ##
++ ## PATCHED: Unset CFLAGS/CPPFLAGS so that libiberty compiles. ##
++ ## ---------------------------------------------------------- ##
++
++ CFLAGS=
++ CPPFLAGS=
++
+ ## -------------------- ##