diff options
-rw-r--r-- | .SRCINFO | 21 | ||||
-rw-r--r-- | PKGBUILD | 50 |
2 files changed, 71 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..0a91e25f5543 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,21 @@ +# Generated by makepkg 4.2.1 +# Mon Apr 6 19:29:15 UTC 2015 +pkgbase = ejtagproxy-git + pkgdesc = GDB interface utility for MIPS processors, including PIC32 + pkgver = r33.bfc15e1 + pkgrel = 1 + url = https://github.com/sergev/ejtagproxy + arch = i686 + arch = x86_64 + license = GPL2 + makedepends = git + optdepends = pic32prog-git: Flash programming utility for PIC32 + optdepends = microchip-mplabxc32-bin: C/C++ compiler for PIC32 + provides = ejtagproxy + conflicts = ejtagproxy + replaces = ejtagproxy-svn + source = git://github.com/sergev/ejtagproxy.git#branch=master + sha512sums = SKIP + +pkgname = ejtagproxy-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..d6cac1dd49f3 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,50 @@ +# Maintainer: David Manouchehri <david@davidmanouchehri.com> +# Contributor: Paul Burton <paulburton89@gmail.com> + +pkgname=ejtagproxy-git +_gitname=$(printf ${pkgname%%-git}) +_gitbranch=master +_gitauthor=sergev +pkgver=r33.bfc15e1 +pkgrel=1 +pkgdesc="GDB interface utility for MIPS processors, including PIC32" +url="https://github.com/$_gitauthor/$_gitname" +license=('GPL2') +source=("git://github.com/$_gitauthor/$_gitname.git#branch=$_gitbranch") +validpgpkeys=('F0FE029614EA35BC9E4F9768A6ECFD0C40839755') # David Manouchehri +sha512sums=('SKIP') +arch=('i686' 'x86_64') +makedepends=('git') +optdepends=('pic32prog-git: Flash programming utility for PIC32' + 'microchip-mplabxc32-bin: C/C++ compiler for PIC32') +conflicts=("$_gitname") +provides=("$_gitname") +replaces=("$_gitname-svn") + +pkgver() { + cd "$srcdir/$_gitname" + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +build() { + cd "$srcdir/$_gitname" + sed -i 's|/lib/i386-linux-gnu|/|' make-unix + make -f make-unix +} + +package() { + cd "$srcdir/$_gitname" + # The makefile installs to a hardcoded path... + install -Dm755 ejtagproxy "${pkgdir}/usr/bin/ejtagproxy" + + # Extract the license + offsets=(`pcregrep -M --file-offsets 'Copyright \(C\)(\n|.)*?\*/' \ + target-ejtag.c | head -n 1 | tr ',' ' '`) + start=${offsets[0]} + len=${offsets[1]} + dd if=target-ejtag.c bs=1 skip=${start} count=${len} 2>/dev/null | \ + sed 's|/\*||' | sed 's|\*/||' | sed 's|^ \* ||g' | sed 's|^ \*$||g' \ + >LICENSE + install -dm755 "${pkgdir}/usr/share/licenses/${pkgname}" + install -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"}}}}}}}}} +} |