Patchwork [1/3] eGalax touchscreen offical xorg driver

login
register
mail settings
Submitter Zhai, Edwin
Date Sept. 27, 2011, 1:03 a.m.
Message ID <4f9d7fab604a93ebdc478178c82746e0e10f8cde.1317084972.git.edwin.zhai@intel.com>
Download mbox | patch
Permalink /patch/12173/
State New, archived
Headers show

Comments

Zhai, Edwin - Sept. 27, 2011, 1:03 a.m.
From: Zhai Edwin <edwin.zhai@intel.com>

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
---
 .../xf86-input-egalax/88eGalaxCalibrate.sh         |    5 ++
 .../xorg-driver/xf86-input-egalax_3.06.5605.bb     |   49 ++++++++++++++++++++
 2 files changed, 54 insertions(+), 0 deletions(-)
 create mode 100755 meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax/88eGalaxCalibrate.sh
 create mode 100644 meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax_3.06.5605.bb

Patch

diff --git a/meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax/88eGalaxCalibrate.sh b/meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax/88eGalaxCalibrate.sh
new file mode 100755
index 0000000..0cb075f
--- /dev/null
+++ b/meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax/88eGalaxCalibrate.sh
@@ -0,0 +1,5 @@ 
+#!/bin/sh
+# start egalax touch screen calibration tools for the 1st time boot
+if [ ! -s /var/lib/eeti.param ]; then
+     eGalaxTouch &
+fi
diff --git a/meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax_3.06.5605.bb b/meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax_3.06.5605.bb
new file mode 100644
index 0000000..b4ff5fa
--- /dev/null
+++ b/meta-pegasus/recipes-graphics/xorg-driver/xf86-input-egalax_3.06.5605.bb
@@ -0,0 +1,49 @@ 
+DESCRIPTION = "eGalax touscreen X driver"
+HOMEPAGE = "http://home.eeti.com.tw/web20/eGalaxTouchDriver/linuxDriver.htm"
+BUGTRACKER = "touch_fae@eeti.com"
+SECTION = "x11/drivers"
+LICENSE = "??"
+LIC_FILES_CHKSUM = "file://readme;endline=10;md5=afb35411768cea26b28e5b20a2a65c9b"
+
+SRC_URI = "http://home.eeti.com.tw/web20/drivers/touch_driver/Linux/20110810/eGalaxTouch-${PV}-32b-k26.tar.gz \
+           file://88eGalaxCalibrate.sh"
+
+PR = "r0"
+
+S = "${WORKDIR}/eGalaxTouch32"
+
+do_unpack_append() {
+	bb.build.exec_func('do_drv_unpack', d)
+}
+
+do_drv_unpack() {
+    tar xzf ${S}/eGalaxTouch.tar.gz
+
+    #make an empty touch screen parameter file
+    touch ${S}/eeti.param
+}
+
+do_install() {
+    install -d ${D}${libdir}/xorg/modules/input
+    install -m 0755 ${S}/eGalaxTouch32/Module/x110/egalax_drv.so ${D}${libdir}/xorg/modules/input/
+
+    install -d ${D}${bindir}
+    install -d ${D}/usr/local/eGalaxTouch32
+    install -m 0755 ${S}/eGalaxTouch32/eGalaxTouch ${D}/usr/local/eGalaxTouch32/
+    ln -s /usr/local/eGalaxTouch32/eGalaxTouch ${D}${bindir}/eGalaxTouch
+
+    install -m 0644 ${S}/eGalaxTouch32/Rule/eGalaxTouch48.png ${D}/usr/local/eGalaxTouch32/eGalaxTouch.png
+
+    install -d ${D}${datadir}/applications
+    install -m 0644  ${S}/eGalaxTouch32/Rule/eGalaxTouch.desktop ${D}${datadir}/applications
+
+    # calibration tools read/write /var/lib/eeti.param, so create one empty file with rw mode for all user
+    install -d ${D}${localstatedir}/lib
+    install -m 0666  ${S}/eeti.param ${D}${localstatedir}/lib/
+
+    install -d ${D}/${sysconfdir}/X11/Xsession.d
+    install -m 755 ${WORKDIR}/88eGalaxCalibrate.sh ${D}/${sysconfdir}/X11/Xsession.d/
+}
+
+FILES_${PN} += "${libdir}/xorg/modules/input/*.so \
+                /usr/local/eGalaxTouch32/*"