summaryrefslogtreecommitdiff
path: root/meta/packages/hal
diff options
context:
space:
mode:
authorVivian Zhang <vivian.zhang@intel.com>2008-11-12 14:15:50 +0800
committerRichard Purdie <rpurdie@linux.intel.com>2008-12-01 20:42:56 +0000
commitfdc825062564e5145fdd1ebe6c7bd416429dfd82 (patch)
tree803d41440ca647ab39867d3ea78e71c5abbea475 /meta/packages/hal
parent1eb027228092b73e90bc3281ba050148f641d817 (diff)
downloadopenembedded-core-fdc825062564e5145fdd1ebe6c7bd416429dfd82.tar.gz
openembedded-core-fdc825062564e5145fdd1ebe6c7bd416429dfd82.tar.bz2
openembedded-core-fdc825062564e5145fdd1ebe6c7bd416429dfd82.tar.xz
openembedded-core-fdc825062564e5145fdd1ebe6c7bd416429dfd82.zip
upgrade hal to 0.5.11 and hal-info to 20080508(from OE)
Diffstat (limited to 'meta/packages/hal')
-rw-r--r--meta/packages/hal/files/hal-right-input-h.patch29
-rw-r--r--meta/packages/hal/hal-0.5.11/fix-configure.diff22
-rw-r--r--meta/packages/hal/hal-info.inc20
-rw-r--r--meta/packages/hal/hal-info_20080508.bb1
-rw-r--r--meta/packages/hal/hal.inc94
-rw-r--r--meta/packages/hal/hal_0.5.11.bb16
6 files changed, 182 insertions, 0 deletions
diff --git a/meta/packages/hal/files/hal-right-input-h.patch b/meta/packages/hal/files/hal-right-input-h.patch
new file mode 100644
index 000000000..f820b7790
--- /dev/null
+++ b/meta/packages/hal/files/hal-right-input-h.patch
@@ -0,0 +1,29 @@
+diff --git a/configure.in b/configure.in
+index e76ff51..5e8cc21 100644
+--- a/configure.in
++++ b/configure.in
+@@ -983,6 +983,11 @@ AC_ARG_WITH([linux-input-header],
+ [Use an given Linux input.h rather than that installed on the system (<linux/input.h>)]))
+ if test "x$with_linux_input_header" != "x"; then
+ AC_DEFINE_UNQUOTED(HAL_LINUX_INPUT_HEADER_H, "$with_linux_input_header", [If set, the header to use instead of <linux/input.h>])
++ LINUX_INPUT_H=$with_linux_input_header
++ AC_SUBST(LINUX_INPUT_H)
++else
++ LINUX_INPUT_H=/usr/include/linux/input.h
++ AC_SUBST(LINUX_INPUT_H)
+ fi
+
+ dnl
+diff --git a/tools/Makefile.am b/tools/Makefile.am
+index ae03edd..7d1cbab 100644
+--- a/tools/Makefile.am
++++ b/tools/Makefile.am
+@@ -79,7 +79,7 @@ endif
+ if BUILD_KEYMAPS
+
+ if HAVE_GPERF
+-hal-setup-keymap-keys.txt: /usr/include/linux/input.h
++hal-setup-keymap-keys.txt: @LINUX_INPUT_H@
+ awk '/^#define.*KEY_/ { if ($$2 != "KEY_MAX") { print substr($$2, 5) } }' < $< > $@
+
+ hal-setup-keymap-hash-name.gperf: hal-setup-keymap-keys.txt
diff --git a/meta/packages/hal/hal-0.5.11/fix-configure.diff b/meta/packages/hal/hal-0.5.11/fix-configure.diff
new file mode 100644
index 000000000..7d9d42d69
--- /dev/null
+++ b/meta/packages/hal/hal-0.5.11/fix-configure.diff
@@ -0,0 +1,22 @@
+From: Rémi Cardona <remi@gentoo.org>
+Date: Sat, 9 Aug 2008 15:04:07 +0000 (+0200)
+Subject: add libtool-2.2 support
+X-Git-Url: http://gitweb.freedesktop.org/?p=hal.git;a=commitdiff;h=c8a1aedf87bbb200fc5daa0ec8559a2d84fbb61d
+
+add libtool-2.2 support
+
+Fix for aclocal to work properly with libtool 2.2 which no longer
+checks for C++ automatically (this patch is of course backwards
+compatible with libtool 1.5.x)
+---
+
+--- a/configure.in
++++ b/configure.in
+@@ -29,6 +29,7 @@ AC_SUBST(LT_AGE)
+
+ AC_ISC_POSIX
+ AC_PROG_CC
++AC_PROG_CXX
+ AM_PROG_CC_C_O
+ AC_HEADER_STDC
+ AC_PROG_LIBTOOL
diff --git a/meta/packages/hal/hal-info.inc b/meta/packages/hal/hal-info.inc
new file mode 100644
index 000000000..635fd0aa4
--- /dev/null
+++ b/meta/packages/hal/hal-info.inc
@@ -0,0 +1,20 @@
+DESCRIPTION = "Hardware Abstraction Layer device information"
+HOMEPAGE = "http://hal.freedesktop.org/"
+SECTION = "unknown"
+LICENSE = "GPL AFL"
+
+SRC_URI = "http://hal.freedesktop.org/releases/${PN}-${PV}.tar.gz"
+S = "${WORKDIR}/${PN}-${PV}"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-recall --disable-video"
+
+do_configure() {
+ gnu-configize
+ libtoolize --force
+ oe_runconf
+}
+
+PACKAGE_ARCH = "all"
+FILES_${PN} += "${datadir}/hal/"
diff --git a/meta/packages/hal/hal-info_20080508.bb b/meta/packages/hal/hal-info_20080508.bb
new file mode 100644
index 000000000..e6d50e398
--- /dev/null
+++ b/meta/packages/hal/hal-info_20080508.bb
@@ -0,0 +1 @@
+require hal-info.inc
diff --git a/meta/packages/hal/hal.inc b/meta/packages/hal/hal.inc
new file mode 100644
index 000000000..d0c74e84a
--- /dev/null
+++ b/meta/packages/hal/hal.inc
@@ -0,0 +1,94 @@
+DESCRIPTION = "Hardware Abstraction Layer"
+HOMEPAGE = "http://freedesktop.org/Software/hal"
+SECTION = "unknown"
+LICENSE = "GPL LGPL AFL"
+
+SRC_URI = "http://hal.freedesktop.org/releases/hal-${PV}.tar.gz"
+
+S = "${WORKDIR}/hal-${PV}"
+
+inherit autotools pkgconfig
+
+DEPENDS = "virtual/kernel dbus-glib udev intltool intltool-native expat libusb gperf-native"
+RDEPENDS += "udev hal-info"
+RRECOMMENDS = "udev-utils"
+
+SRC_URI += "file://99_hal \
+ file://20hal \
+ "
+
+LEAD_SONAME = "libhal.so"
+
+# machines with pci and acpi get a machine dependant hal
+EXTRA_OECONF = "--with-hwdata=${datadir}/hwdata \
+ --with-expat=${STAGING_LIBDIR}/.. \
+ --with-dbus-sys=${sysconfdir}/dbus-1/system.d \
+ --with-hotplug=${sysconfdir}/hotplug.d \
+ --disable-docbook-docs \
+ --disable-policy-kit \
+ --disable-pmu \
+ --disable-pnp-ids \
+ ${@base_contains('COMBINED_FEATURES', 'pci', '--enable-pci --enable-pci-ids', '--disable-pci --disable-pci-ids',d)} \
+ ${@base_contains('MACHINE_FEATURES', 'acpi', '--enable-acpi', '--disable-acpi',d)} \
+ "
+
+MY_ARCH := "${PACKAGE_ARCH}"
+PACKAGE_ARCH = "${@base_contains('MACHINE_FEATURES', 'acpi', '${MACHINE_ARCH}', '${MY_ARCH}',d)}"
+PACKAGE_ARCH = "${@base_contains('MACHINE_FEATURES', 'pci', '${MACHINE_ARCH}', '${MY_ARCH}',d)}"
+
+do_install_append() {
+ install -d ${D}/etc/default/volatiles
+ install -m 0644 ${WORKDIR}/99_hal ${D}/etc/default/volatiles
+ install -d ${D}/etc/dbus-1/event.d
+ install -m 0755 ${WORKDIR}/20hal ${D}/etc/dbus-1/event.d
+}
+
+do_stage() {
+ oe_libinstall -C libhal -a -so libhal ${STAGING_LIBDIR}
+ oe_libinstall -C libhal-storage -a -so libhal-storage ${STAGING_LIBDIR}
+
+ install -d ${STAGING_INCDIR}/hal
+ install -m 0644 libhal/libhal.h ${STAGING_INCDIR}/hal
+ install -m 0644 libhal-storage/libhal-storage.h ${STAGING_INCDIR}/hal
+}
+
+# At the time the postinst runs, dbus might not be setup so only restart if running
+pkg_postinst_hal () {
+ # can't do this offline
+ if [ "x$D" != "x" ]; then
+ exit 1
+ fi
+
+ grep haldaemon /etc/group || addgroup haldaemon
+ grep haldaemon /etc/passwd || adduser --disabled-password --system --home /var/run/hald --no-create-home haldaemon --ingroup haldaemon -g HAL
+
+ /etc/init.d/populate-volatile.sh update
+
+ DBUSPID=`pidof dbus-daemon`
+
+ if [ "x$DBUSPID" != "x" ]; then
+ /etc/init.d/dbus-1 force-reload
+ fi
+}
+
+pkg_postrm_hal () {
+ deluser haldaemon || true
+ delgroup haldaemon || true
+}
+
+FILES_${PN} = "${sysconfdir} \
+ ${bindir}/lshal \
+ ${bindir}/hal-find-by-capability \
+ ${bindir}/hal-find-by-property \
+ ${bindir}/hal-device \
+ ${bindir}/hal-get-property \
+ ${bindir}/hal-set-property \
+ ${bindir}/hal-lock \
+ ${bindir}/hal-is-caller-locked-out \
+ ${sbindir} \
+ ${libdir}/libhal.so.* \
+ ${libdir}/libhal-storage.so.* \
+ ${libdir}/hal \
+ ${libexecdir} \
+ ${datadir}/hal/fdi \
+ ${datadir}/hal/scripts"
diff --git a/meta/packages/hal/hal_0.5.11.bb b/meta/packages/hal/hal_0.5.11.bb
new file mode 100644
index 000000000..f13a3213e
--- /dev/null
+++ b/meta/packages/hal/hal_0.5.11.bb
@@ -0,0 +1,16 @@
+require hal.inc
+
+PR = "r1"
+
+SRC_URI += " file://hal-right-input-h.patch;patch=1 \
+ file://fix-configure.diff;patch=1"
+
+EXTRA_OECONF += "--with-linux-input-header=${STAGING_INCDIR}/linux/input.h"
+
+PACKAGES =+ "libhal libhal-storage"
+
+FILES_libhal = "${libdir}/libhal.so.*"
+FILES_libhal-storage = "${libdir}/libhal-storage.so.*"
+
+FILES_${PN} =+ "${bindir}/hal-disable-polling \
+ ${bindir}/hal-setup-keymap"