summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-oe/recipes-qt/qcanobserver/qcanobserver/0001-messagebufferinterface.cpp-add-sys-socket.h-as-inclu.patch41
-rw-r--r--meta-oe/recipes-qt/qcanobserver/qcanobserver/0002-qconsole-writethread-gcc-4.5-fixes.patch40
-rwxr-xr-xmeta-oe/recipes-qt/qcanobserver/qcanobserver/candemo.xml40
-rw-r--r--meta-oe/recipes-qt/qcanobserver/qcanobserver_svn.bb41
4 files changed, 162 insertions, 0 deletions
diff --git a/meta-oe/recipes-qt/qcanobserver/qcanobserver/0001-messagebufferinterface.cpp-add-sys-socket.h-as-inclu.patch b/meta-oe/recipes-qt/qcanobserver/qcanobserver/0001-messagebufferinterface.cpp-add-sys-socket.h-as-inclu.patch
new file mode 100644
index 000000000..1b3da3bab
--- /dev/null
+++ b/meta-oe/recipes-qt/qcanobserver/qcanobserver/0001-messagebufferinterface.cpp-add-sys-socket.h-as-inclu.patch
@@ -0,0 +1,41 @@
1From ebb464e3dfa2d59d65c3aa8ee652cb7607481f61 Mon Sep 17 00:00:00 2001
2From: Koen Kooi <koen@dominion.thruhere.net>
3Date: Thu, 10 Nov 2011 19:38:27 +0100
4Subject: [PATCH] messagebufferinterface.cpp: move sys/socket.h include
5
6This prevents the following error during cross-compiling:
7
8| In file included from messagebufferinterface.cpp:30:
9| /OE/angstrom-dev/sysroots/armv7a-angstrom-linux-gnueabi/usr/include/linux/can.h:81: error: 'sa_family_t' does not name a type
10
11Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
12---
13 messagebufferinterface.cpp | 7 ++++---
14 1 files changed, 4 insertions(+), 3 deletions(-)
15
16diff --git a/messagebufferinterface.cpp b/messagebufferinterface.cpp
17index 116564c..3e9a535 100644
18--- a/messagebufferinterface.cpp
19+++ b/messagebufferinterface.cpp
20@@ -25,14 +25,15 @@
21 #include <sys/time.h>
22 #include <QFile>
23
24+#include <sys/types.h>
25+#include <sys/socket.h>
26+#include <sys/stat.h>
27+
28 //#include <linux/can.h>
29 //#include <linux/can/raw.h>
30 #include <syscall.h>
31
32 #include "configdialog.h"
33-#include <sys/types.h>
34-#include <sys/socket.h>
35-#include <sys/stat.h>
36 #include <linux/can.h>
37 #include <linux/can/raw.h>
38
39--
401.7.2.5
41
diff --git a/meta-oe/recipes-qt/qcanobserver/qcanobserver/0002-qconsole-writethread-gcc-4.5-fixes.patch b/meta-oe/recipes-qt/qcanobserver/qcanobserver/0002-qconsole-writethread-gcc-4.5-fixes.patch
new file mode 100644
index 000000000..45619237d
--- /dev/null
+++ b/meta-oe/recipes-qt/qcanobserver/qcanobserver/0002-qconsole-writethread-gcc-4.5-fixes.patch
@@ -0,0 +1,40 @@
1From 3b3cb5212b5dbf182beed171045e5d179b2e9000 Mon Sep 17 00:00:00 2001
2From: Koen Kooi <koen@dominion.thruhere.net>
3Date: Fri, 11 Nov 2011 09:32:14 +0100
4Subject: [PATCH 2/2] qconsole, writethread: gcc 4.5 fixes
5
6Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
7---
8 qconsole.cpp | 2 +-
9 writethread.cpp | 2 +-
10 2 files changed, 2 insertions(+), 2 deletions(-)
11
12diff --git a/qconsole.cpp b/qconsole.cpp
13index ea86957..b5a4687 100644
14--- a/qconsole.cpp
15+++ b/qconsole.cpp
16@@ -22,7 +22,7 @@ QConsole::QConsole()
17
18 {
19 this->setReadOnly(true);
20- QTextEdit::QTextEdit(NULL);
21+ QTextEdit(NULL);
22 }
23
24
25diff --git a/writethread.cpp b/writethread.cpp
26index ef7bc13..ff19560 100755
27--- a/writethread.cpp
28+++ b/writethread.cpp
29@@ -69,7 +69,7 @@ void WriteThread::setDev(void *ConfData, QString InterfaceLib, bool shareDevLib)
30 if(!handle)
31 {
32 QString *ErrStr = new QString(" ");
33- ErrStr->sprintf("%s %s","Could not load Device Mapper: ", InterfaceLib);
34+ ErrStr->sprintf("%s %s","Could not load Device Mapper: ", (char*)InterfaceLib.constData());
35 ErrorDialog *ed = new ErrorDialog;
36 ed->SetErrorMessage(*ErrStr);
37 delete ErrStr;
38--
391.7.2.5
40
diff --git a/meta-oe/recipes-qt/qcanobserver/qcanobserver/candemo.xml b/meta-oe/recipes-qt/qcanobserver/qcanobserver/candemo.xml
new file mode 100755
index 000000000..304713fdd
--- /dev/null
+++ b/meta-oe/recipes-qt/qcanobserver/qcanobserver/candemo.xml
@@ -0,0 +1,40 @@
1<?xml version="1.0" encoding="ISO-8859-1"?>
2
3<Database Name="EW-demo">
4 <ID Id="180">
5 <Item0>
6 <interpret Multiplier="0.010986328125" Name="MotorPos" Offset="-180" Datamask="00120000">
7 </interpret>
8 </Item0>
9 </ID>
10 <ID Id="280">
11 <Item0>
12 <interpret Multiplier="1.0" Name="Fanstatus" Offset="0" Datamask="10000000">
13 </interpret>
14 </Item0>
15 </ID>
16 <ID Id="380">
17 <Item0>
18 <interpret Multiplier="0.00390625" Name="temp1" Offset="0" Datamask="00120000">
19 </interpret>
20 </Item0>
21 </ID>
22 <ID Id="480">
23 <Item0>
24 <interpret Multiplier="1.0" Name="fanstatus" Offset="0" Datamask="10000000">
25 </interpret>
26 </Item0>
27 </ID>
28 <ID Id="580">
29 <Item0>
30 <interpret Multiplier="1.0" Name="lampstatus" Offset="0" Datamask="10000000">
31 </interpret>
32 </Item0>
33 </ID>
34 <ID Id="680">
35 <Item0>
36 <interpret Multiplier="0.00390625" Name="Lightsensor" Offset="0" Datamask="00120000">
37 </interpret>
38 </Item0>
39 </ID>
40</Database>
diff --git a/meta-oe/recipes-qt/qcanobserver/qcanobserver_svn.bb b/meta-oe/recipes-qt/qcanobserver/qcanobserver_svn.bb
new file mode 100644
index 000000000..9d8f4a31b
--- /dev/null
+++ b/meta-oe/recipes-qt/qcanobserver/qcanobserver_svn.bb
@@ -0,0 +1,41 @@
1DESCRIPTION = "The Linux CAN Sniffer"
2
3LICENSE = "GPLv3+"
4LIC_FILES_CHKSUM = "file://modeltest/LICENSE.GPL;md5=34337af480a8c452bfafe22a78fa20cb"
5
6inherit qt4x11
7
8DEPENDS += "qwt"
9
10PV = "0.5+svnr${SRCPV}"
11SRCREV = "48"
12SRC_URI = "svn://qcanobserver.svn.sourceforge.net/svnroot;module=qcanobserver;proto=https \
13 file://0001-messagebufferinterface.cpp-add-sys-socket.h-as-inclu.patch \
14 file://0002-qconsole-writethread-gcc-4.5-fixes.patch \
15 file://candemo.xml"
16
17S = "${WORKDIR}/qcanobserver/"
18
19CXXFLAGS += " -DPF_CAN=29 -DAF_CAN=PF_CAN"
20
21do_configure_prepend() {
22 sed -i -e s:/usr/include/qwt5/:${STAGING_INCDIR}:g -e 's:-L/usr/lib/:-L${STAGING_DIR_TARGET}/lib -ldl:g' *.pro
23}
24
25do_configure_append() {
26 sed -i -e s:-L/usr/lib::g Makefile
27}
28
29do_install() {
30 install -d ${D}${datadir}/qcanobserver
31 install -d ${D}${datadir}/qcanobserver/cfg
32 install -d ${D}${datadir}/qcanobserver/lib
33 install -d ${D}${datadir}/qcanobserver/db
34
35 install -m 0755 ${S}/QCanObserver ${D}${datadir}/qcanobserver
36
37 install -m 0644 ${WORKDIR}/candemo.xml ${D}${datadir}/qcanobserver/db
38 install -m 0644 ${S}/db/*.xml ${D}${datadir}/qcanobserver/db
39}
40
41FILES_${PN}-dbg += "${datadir}/qcanobserver/.debug"