summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Dawson <spdawson@gmail.com>2013-04-23 04:52:39 (GMT)
committer Peter Korsgaard <jacmet@sunsite.dk>2013-04-23 18:37:42 (GMT)
commit85ffab574935ae07c090e05b5d720e1fb76569c7 (patch)
treee2946cb45486a88633104034d63bf37ff05be9ae
parentadc231d6a15dd3d2cdc18190c9befaa655bba7ad (diff)
downloadbuildroot-85ffab574935ae07c090e05b5d720e1fb76569c7.tar.gz
buildroot-85ffab574935ae07c090e05b5d720e1fb76569c7.tar.bz2
libserial: new package
Note that the Python binding is disabled; we can't build this in Buildroot without the sipconfig Python module for the host. Signed-off-by: Simon Dawson <spdawson@gmail.com> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
-rw-r--r--package/Config.in1
-rw-r--r--package/libserial/Config.in11
-rw-r--r--package/libserial/libserial-0001-disable-python-bindings.patch25
-rw-r--r--package/libserial/libserial-0002-add-missing-header-include.patch15
-rw-r--r--package/libserial/libserial.mk13
5 files changed, 65 insertions, 0 deletions
diff --git a/package/Config.in b/package/Config.in
index 06bcdef..ad070f4 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -464,6 +464,7 @@ source "package/libhid/Config.in"
source "package/libiqrf/Config.in"
source "package/libnfc/Config.in"
source "package/libnfc-llcp/Config.in"
+source "package/libserial/Config.in"
source "package/libusb/Config.in"
source "package/libusb-compat/Config.in"
source "package/libv4l/Config.in"
diff --git a/package/libserial/Config.in b/package/libserial/Config.in
new file mode 100644
index 0000000..f098e28
--- /dev/null
+++ b/package/libserial/Config.in
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_LIBSERIAL
+ bool "libserial"
+ depends on BR2_INSTALL_LIBSTDCPP
+ help
+ Simplified serial port programming in C++ under POSIX operating
+ systems.
+
+ http://libserial.sourceforge.net/
+
+comment "libserial requires a toolchain with C++ support enabled"
+ depends on !BR2_INSTALL_LIBSTDCPP
diff --git a/package/libserial/libserial-0001-disable-python-bindings.patch b/package/libserial/libserial-0001-disable-python-bindings.patch
new file mode 100644
index 0000000..54b5cb6
--- /dev/null
+++ b/package/libserial/libserial-0001-disable-python-bindings.patch
@@ -0,0 +1,25 @@
+Disable build of Python bindings, which requires the sipconfig module.
+
+Signed-off-by: Simon Dawson <spdawson@gmail.com>
+
+diff -Nurp a/Makefile.am b/Makefile.am
+--- a/Makefile.am 2008-11-12 01:27:31.000000000 +0000
++++ b/Makefile.am 2013-04-16 09:41:13.476002178 +0100
+@@ -1,4 +1,4 @@
+-SUBDIRS=src doc examples sip
++SUBDIRS=src doc examples
+
+ EXTRA_DIST = doxygen.conf.in Makefile.dist libserial.spec libserial.pc
+
+diff -Nurp a/Makefile.in b/Makefile.in
+--- a/Makefile.in 2008-11-12 01:28:14.000000000 +0000
++++ b/Makefile.in 2013-04-16 09:41:05.628013626 +0100
+@@ -197,7 +197,7 @@ sysconfdir = @sysconfdir@
+ target_alias = @target_alias@
+ top_builddir = @top_builddir@
+ top_srcdir = @top_srcdir@
+-SUBDIRS = src doc examples sip
++SUBDIRS = src doc examples
+ EXTRA_DIST = doxygen.conf.in Makefile.dist libserial.spec libserial.pc
+ pkgconfigdir = $(libdir)/pkgconfig
+ pkgconfig_DATA = libserial.pc
diff --git a/package/libserial/libserial-0002-add-missing-header-include.patch b/package/libserial/libserial-0002-add-missing-header-include.patch
new file mode 100644
index 0000000..a022637
--- /dev/null
+++ b/package/libserial/libserial-0002-add-missing-header-include.patch
@@ -0,0 +1,15 @@
+Add a missing header include, to fix a build error.
+
+Signed-off-by: Simon Dawson <spdawson@gmail.com>
+
+diff -Nurp a/src/SerialPort.cpp b/src/SerialPort.cpp
+--- a/src/SerialPort.cpp 2008-11-12 01:27:30.000000000 +0000
++++ b/src/SerialPort.cpp 2013-04-23 15:43:41.537495852 +0100
+@@ -27,6 +27,7 @@
+ #include <cassert>
+ #include <termios.h>
+ #include <fcntl.h>
++#include <unistd.h>
+ #include <sys/ioctl.h>
+ #include <sys/time.h>
+ #include <signal.h>
diff --git a/package/libserial/libserial.mk b/package/libserial/libserial.mk
new file mode 100644
index 0000000..a835439
--- /dev/null
+++ b/package/libserial/libserial.mk
@@ -0,0 +1,13 @@
+#############################################################
+#
+# libserial
+#
+#############################################################
+
+LIBSERIAL_VERSION = 0.6.0rc1
+LIBSERIAL_SITE = http://downloads.sourceforge.net/libserial
+LIBSERIAL_INSTALL_STAGING = YES
+LIBSERIAL_LICENSE = GPLv2+
+LIBSERIAL_LICENSE_FILES = COPYING
+
+$(eval $(autotools-package))