summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas Truessel2018-12-23 20:16:33 +0100
committerNicolas Truessel2018-12-23 20:16:33 +0100
commitc682b24d0d88cbf4d9a137737e49ad5c685f6b51 (patch)
tree93732f6e9b6210c34c1571f36af29a637601c60f
downloadaur-c682b24d0d88cbf4d9a137737e49ad5c685f6b51.tar.gz
Initial commit
-rw-r--r--.SRCINFO15
-rw-r--r--.gitignore4
-rw-r--r--PKGBUILD25
-rw-r--r--cargo-binutils.install9
4 files changed, 53 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..76879bce527
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = cargo-binutils
+ pkgver = 0.1.6
+ pkgrel = 1
+ url = https://github.com/rust-embedded/cargo-binutils
+ install = cargo-binutils.install
+ arch = x86_64
+ license = Apache
+ license = MIT
+ makedepends = cargo
+ depends = rustup
+ source = https://github.com/rust-embedded/cargo-binutils/archive/v0.1.6.tar.gz
+ sha256sums = 5514aefc982944c9fb965881a533817a4faaad883c871daa6fd5c820ce91ef6f
+
+pkgname = cargo-binutils
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000000..0a2223f3641
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+*.tar.gz
+*.tar.xz
+src/
+pkg/
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..caedf622f2b
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,25 @@
+pkgname=cargo-binutils
+pkgver=0.1.6
+pkgrel=1
+pkgdesc=''
+url="https://github.com/rust-embedded/$pkgname"
+arch=('x86_64')
+license=('Apache' 'MIT')
+depends=('rustup')
+makedepends=('cargo')
+install="$pkgname.install"
+source=("$url/archive/v$pkgver.tar.gz")
+sha256sums=('5514aefc982944c9fb965881a533817a4faaad883c871daa6fd5c820ce91ef6f')
+
+build() {
+ cd "$pkgname-$pkgver"
+ cargo build --release
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+
+ for binary in 'nm' 'objcopy' 'objdump' 'profdata' 'readobj' 'size' 'strip'; do
+ install -Dm755 "target/release/cargo-$binary" "$pkgdir/usr/bin/cargo-$binary"
+ done
+}
diff --git a/cargo-binutils.install b/cargo-binutils.install
new file mode 100644
index 00000000000..4ec99ab52dc
--- /dev/null
+++ b/cargo-binutils.install
@@ -0,0 +1,9 @@
+post_install() {
+ echo ":: Make sure to also add the llvm tools component"
+ echo " using 'rustup component add llvm-tools-preview'"
+}
+
+post_remove() {
+ echo ":: If you no longer require the llvm tools from rustup, you can"
+ echo " remove it with 'rustup component remove llvm-tools-preview'"
+}