From a045919f3b97735b6678888d27aa89e75ff19226 Mon Sep 17 00:00:00 2001 From: Francesco Circhetta Date: Tue, 12 Sep 2017 12:03:45 +0200 Subject: [PATCH] New package: onboard-1.4.1 --- .../patches/00-Fix-build-with-musl.patch | 67 +++++++++++++++++++ srcpkgs/onboard/template | 18 +++++ 2 files changed, 85 insertions(+) create mode 100644 srcpkgs/onboard/patches/00-Fix-build-with-musl.patch create mode 100644 srcpkgs/onboard/template diff --git a/srcpkgs/onboard/patches/00-Fix-build-with-musl.patch b/srcpkgs/onboard/patches/00-Fix-build-with-musl.patch new file mode 100644 index 00000000000..fda37895c96 --- /dev/null +++ b/srcpkgs/onboard/patches/00-Fix-build-with-musl.patch @@ -0,0 +1,67 @@ +From 1c95f64aa342147387ce4b1b7269a5c8b34bd898 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Thu, 13 Jul 2017 09:01:04 -0700 +Subject: [PATCH] pypredict/lm: Define error API if platform does not have it + +error() API is not implemented across all libcs on linux +e.g. musl does not provide it. + +Signed-off-by: Khem Raj +--- + Onboard/pypredict/lm/lm.cpp | 1 - + Onboard/pypredict/lm/lm.h | 13 +++++++++++++ + Onboard/pypredict/lm/lm_dynamic.cpp | 2 -- + 3 files changed, 13 insertions(+), 3 deletions(-) + +diff --git a/Onboard/pypredict/lm/lm.cpp b/Onboard/pypredict/lm/lm.cpp +index 2e64296..37ae241 100644 +--- a/Onboard/pypredict/lm/lm.cpp ++++ b/Onboard/pypredict/lm/lm.cpp +@@ -19,7 +19,6 @@ + + #include + #include +-#include + #include + #include + #include +diff --git a/Onboard/pypredict/lm/lm.h b/Onboard/pypredict/lm/lm.h +index ed4164a..b8b63ee 100644 +--- a/Onboard/pypredict/lm/lm.h ++++ b/Onboard/pypredict/lm/lm.h +@@ -32,6 +32,19 @@ + #include + #include + ++#if defined(HAVE_ERROR_H) ++#include ++#else ++#include ++#define _onboard_error(S, E, F, ...) do { \ ++ if (E) \ ++ err(S, F ": %s", ##__VA_ARGS__, strerror(E)); \ ++ else \ ++ err(S, F, ##__VA_ARGS__); \ ++} while(0) ++ ++#define error _onboard_error ++#endif + + // break into debugger + // step twice to come back out of the raise() call into known code +diff --git a/Onboard/pypredict/lm/lm_dynamic.cpp b/Onboard/pypredict/lm/lm_dynamic.cpp +index 7c62824..e7c7f40 100644 +--- a/Onboard/pypredict/lm/lm_dynamic.cpp ++++ b/Onboard/pypredict/lm/lm_dynamic.cpp +@@ -17,8 +17,6 @@ + * along with this program. If not, see . + */ + +-#include +- + #include "lm_dynamic.h" + + using namespace std; +-- +2.13.2 + diff --git a/srcpkgs/onboard/template b/srcpkgs/onboard/template new file mode 100644 index 00000000000..5bfe144324c --- /dev/null +++ b/srcpkgs/onboard/template @@ -0,0 +1,18 @@ +# Template file for 'onboard' +pkgname=onboard +version=1.4.1 +revision=1 +build_style=python3-module +pycompile_module="Onboard" +patch_args="-Np1" +hostmakedepends="intltool pkg-config python3-distutils-extra" +makedepends="dconf-devel eudev-libudev-devel gtk+3-devel hunspell-devel + libcanberra-devel libX11-devel libXi-devel libXtst-devel libxkbfile-devel + python3-devel" +depends="iso-codes python3-cairo python3-gobject" +short_desc="On-screen keyboard useful on tablet PCs or for mobility impaired users" +maintainer="Francesco Circhetta " +license="GPL-3" +homepage="https://launchpad.net/onboard" +distfiles="https://launchpad.net/${pkgname}/${version%.*}/${version}/+download/${pkgname}-${version}.tar.gz" +checksum=01cae1ac5b1ef1ab985bd2d2d79ded6fc99ee04b1535cc1bb191e43a231a3865