summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorlks2015-08-24 10:23:16 +0200
committerlks2015-08-24 10:23:16 +0200
commitfc4ef040fa5373af56d174e8b16067107c49c426 (patch)
treeb1bf4764488a180aac6a10e517ed9051860309b7
downloadaur-fc4ef040fa5373af56d174e8b16067107c49c426.tar.gz
Initial import
-rw-r--r--.SRCINFO16
-rw-r--r--PKGBUILD33
-rw-r--r--nxtrc-fix-looping.patch13
3 files changed, 62 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..177547d81dff
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,16 @@
+pkgbase = nxtrc
+ pkgdesc = A tool for communicating with lego nxt brick over bluetooth
+ pkgver = 2.3
+ pkgrel = 4
+ url = http://www.scienzaludica.it/index.php?page=88
+ arch = i686
+ arch = x86_64
+ license = GPL2
+ depends = bluez-libs
+ source = http://www.scienzaludica.it/files/nxtrc-2.3.tar.gz
+ source = nxtrc-fix-looping.patch
+ md5sums = d4be8bafe65e6336363a515ed5199ccc
+ md5sums = 37316df0b601c1c87009757b7c92dd80
+
+pkgname = nxtrc
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..7ab6807e5484
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,33 @@
+# Maintainer: lukas (lukas <dot> graetz <at> web <dot> de)
+pkgname=nxtrc
+pkgver=2.3
+pkgrel=4
+pkgdesc="A tool for communicating with lego nxt brick over bluetooth"
+arch=('i686' 'x86_64')
+license=('GPL2')
+url="http://www.scienzaludica.it/index.php?page=88"
+depends=('bluez-libs')
+source=("http://www.scienzaludica.it/files/${pkgname}-${pkgver}.tar.gz"
+ "nxtrc-fix-looping.patch")
+md5sums=('d4be8bafe65e6336363a515ed5199ccc'
+ '37316df0b601c1c87009757b7c92dd80')
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i "${srcdir}/nxtrc-fix-looping.patch"
+ ./configure --prefix=/usr
+ make
+ # FIXME: Howto put that stuff in the Makefile?
+ echo gcc -Wall -shared -fPIC -dPIC -c nxtrc_func.c -o libnxtrc.so -lbluietooth ${CFLAGS}
+ gcc -Wall -shared -fPIC -dPIC -c nxtrc_func.c -o libnxtrc.so -lbluietooth ${CFLAGS}
+}
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR=${pkgdir} install
+ mkdir -p ${pkgdir}/usr/lib
+ echo install libnxtrc.so ${pkgdir}/usr/lib
+ install libnxtrc.so ${pkgdir}/usr/lib
+ mkdir -p ${pkgdir}/usr/include
+ echo install -m 644 nxtrc_func.h ${pkgdir}/usr/include
+ install -m 644 nxtrc_func.h ${pkgdir}/usr/include
+}
+
diff --git a/nxtrc-fix-looping.patch b/nxtrc-fix-looping.patch
new file mode 100644
index 000000000000..af84b9db1e3d
--- /dev/null
+++ b/nxtrc-fix-looping.patch
@@ -0,0 +1,13 @@
+diff -upr nxtrc-2.3.orig/nxtrc.c nxtrc-2.3/nxtrc.c
+--- nxtrc-2.3.orig/nxtrc.c 2013-03-27 10:37:23.120000008 +0100
++++ nxtrc-2.3/nxtrc.c 2013-03-27 10:37:58.370000007 +0100
+@@ -24,7 +24,8 @@ void print_usage(void);
+ int main(int argc, char **argv)
+ {
+ int s,i,verb=0,loop=0;
+-char c,rsp;
++int c;
++char rsp;
+ extern char *optarg;
+ extern int optind, opterr, optopt;
+ char name[20]={0x0};