mirror of
https://git.yoctoproject.org/poky
synced 2026-05-31 00:39:46 +00:00
packages: Separate out most of the remaining packages into recipes
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
This commit is contained in:
Executable
+58
@@ -0,0 +1,58 @@
|
||||
#! /bin/sh
|
||||
#
|
||||
# hal Start the Daemon that stores device informations
|
||||
# for the Hardware abstraction layer
|
||||
#
|
||||
# Written by Martin Waitz based on skeleton code
|
||||
# written by Miquel van Smoorenburg <miquels@cistron.nl>.
|
||||
# Modified for Debian
|
||||
# by Ian Murdock <imurdock@gnu.ai.mit.edu>.
|
||||
#
|
||||
|
||||
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
|
||||
DAEMON=/usr/sbin/hald
|
||||
PIDDIR=/var/run/hald
|
||||
PIDFILE=$PIDDIR/hald.pid
|
||||
NAME=hald
|
||||
DAEMONUSER=haldaemon
|
||||
DESC="Hardware abstraction layer"
|
||||
|
||||
test -x $DAEMON || exit 0
|
||||
|
||||
set -e
|
||||
|
||||
do_start() {
|
||||
if [ ! -d $PIDDIR ]; then
|
||||
mkdir -p $PIDDIR
|
||||
chown $DAEMONUSER:$DAEMONUSER $PIDDIR
|
||||
fi
|
||||
echo "Starting $DESC" "$NAME"
|
||||
start-stop-daemon --start --pidfile $PIDFILE \
|
||||
--exec $DAEMON -- $DAEMON_OPTS
|
||||
}
|
||||
|
||||
do_stop() {
|
||||
echo "Stopping $DESC" "$NAME"
|
||||
start-stop-daemon --stop --quiet --pidfile $PIDFILE \
|
||||
--exec $DAEMON
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
do_start
|
||||
;;
|
||||
stop)
|
||||
do_stop
|
||||
;;
|
||||
restart|force-reload)
|
||||
do_stop
|
||||
sleep 5
|
||||
do_start
|
||||
;;
|
||||
*)
|
||||
echo "Usage: $0 {start|stop|restart|force-reload}" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
exit 0
|
||||
@@ -0,0 +1,11 @@
|
||||
--- hal-0.5.9/configure.in~ 2007-04-03 05:36:44.000000000 +0100
|
||||
+++ hal-0.5.9/configure.in 2007-04-03 10:29:39.000000000 +0100
|
||||
@@ -6,7 +6,7 @@
|
||||
# Patches for that is welcome.
|
||||
#
|
||||
|
||||
-AC_PREREQ(2.59c)
|
||||
+AC_PREREQ(2.59)
|
||||
AC_INIT(hal, 0.5.9, david@fubar.dk)
|
||||
AM_INIT_AUTOMAKE(hal, 0.5.9)
|
||||
AM_CONFIG_HEADER(config.h)
|
||||
@@ -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
|
||||
@@ -0,0 +1,24 @@
|
||||
--- hal-0.5.9.1/hald/linux/probing/linux_dvd_rw_utils.c.old 2007-08-03 17:24:12.000000000 +0100
|
||||
+++ hal-0.5.9.1/hald/linux/probing/linux_dvd_rw_utils.c 2007-08-03 17:25:06.000000000 +0100
|
||||
@@ -58,6 +58,10 @@
|
||||
|
||||
#include "linux_dvd_rw_utils.h"
|
||||
|
||||
+#if defined(SG_FLAG_UNUSED_LUN_INHIBIT)
|
||||
+# define SG_FLAG_LUN_INHIBIT SG_FLAG_UNUSED_LUN_INHIBIT
|
||||
+#endif
|
||||
+
|
||||
typedef enum {
|
||||
NONE = CGC_DATA_NONE, // 3
|
||||
READ = CGC_DATA_READ, // 2
|
||||
@@ -153,8 +153,8 @@
|
||||
errno = EIO;
|
||||
ret = -1;
|
||||
if (cmd->sg_io.masked_status & CHECK_CONDITION) {
|
||||
- CREAM_ON_ERRNO (cmd->sg_io.sbp);
|
||||
- ret = ERRCODE (cmd->sg_io.sbp);
|
||||
+ CREAM_ON_ERRNO ((char*)cmd->sg_io.sbp);
|
||||
+ ret = ERRCODE ((char*)cmd->sg_io.sbp);
|
||||
if (ret == 0)
|
||||
ret = -1;
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
DESCRIPTION = "Hardware Abstraction Layer device information"
|
||||
HOMEPAGE = "http://hal.freedesktop.org/"
|
||||
BUGTRACKER = "http://bugs.freedesktop.org/buglist.cgi?product=hal"
|
||||
SECTION = "unknown"
|
||||
|
||||
LICENSE = "GPLv2 | AFL"
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=ae484909bad0cf11c8e2071cee6bd4dc"
|
||||
|
||||
SRC_URI = "http://hal.freedesktop.org/releases/${PN}-${PV}.tar.gz"
|
||||
|
||||
inherit autotools pkgconfig
|
||||
|
||||
EXTRA_OECONF = "--disable-recall --disable-video"
|
||||
|
||||
do_configure() {
|
||||
gnu-configize
|
||||
libtoolize --force
|
||||
oe_runconf
|
||||
}
|
||||
|
||||
PACKAGE_ARCH = "all"
|
||||
FILES_${PN} += "${datadir}/hal/"
|
||||
@@ -0,0 +1 @@
|
||||
require hal-info.inc
|
||||
@@ -0,0 +1,9 @@
|
||||
require hal-info.inc
|
||||
|
||||
PV = "${SRCDATE}+git"
|
||||
PR = "r0"
|
||||
|
||||
SRC_URI = "git://anongit.freedesktop.org/hal-info/;protocol=git;rev=HAL_INFO_20091130"
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
DEFAULT_PREFERENCE = "-1"
|
||||
@@ -0,0 +1,85 @@
|
||||
DESCRIPTION = "Hardware Abstraction Layer"
|
||||
HOMEPAGE = "http://freedesktop.org/Software/hal"
|
||||
BUGTRACKER = "http://bugs.freedesktop.org/buglist.cgi?product=hal"
|
||||
SECTION = "unknown"
|
||||
|
||||
LICENSE = "GPLv2+ | AFL"
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=5b5ffd59fbb7c2fff6de76c94177af31"
|
||||
|
||||
DEPENDS = "virtual/kernel dbus-glib udev util-linux intltool intltool-native expat libusb gperf-native"
|
||||
RDEPENDS += "udev hal-info"
|
||||
|
||||
SRC_URI = "http://hal.freedesktop.org/releases/hal-${PV}.tar.gz \
|
||||
file://20hal"
|
||||
|
||||
inherit autotools pkgconfig
|
||||
|
||||
|
||||
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)}"
|
||||
PACKAGE_ARCH_emenlow := "${PACKAGE_ARCH}"
|
||||
|
||||
do_install_append() {
|
||||
install -d ${D}/etc/dbus-1/event.d
|
||||
install -m 0755 ${WORKDIR}/20hal ${D}/etc/dbus-1/event.d
|
||||
}
|
||||
|
||||
# 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
|
||||
|
||||
# add volatile after new user/grp are created
|
||||
echo "d root root 0700 /var/run/hald none" > /etc/default/volatiles/99_hal
|
||||
echo "d haldaemon haldaemon 0755 /var/cache/hald none" >> /etc/default/volatiles/99_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"
|
||||
@@ -0,0 +1,60 @@
|
||||
The AC_LANG sections upset libtool 2.2.2, as do .cpp files without a call
|
||||
to AC_PROG_CXX. Easiest solution is to patch this out for now.
|
||||
|
||||
RP - 14/4/08
|
||||
|
||||
Index: hal-0.5.9.1/configure.in
|
||||
===================================================================
|
||||
--- hal-0.5.9.1.orig/configure.in 2008-04-14 22:41:49.000000000 +0100
|
||||
+++ hal-0.5.9.1/configure.in 2008-04-14 22:43:13.000000000 +0100
|
||||
@@ -345,32 +345,8 @@
|
||||
fi
|
||||
|
||||
dnl Check for libsmbios
|
||||
-AC_LANG_PUSH([C++])
|
||||
-AC_CHECK_LIB(smbios, SMBIOSFreeMemory, LIB_SMBIOS=yes , LIB_SMBIOS=no )
|
||||
-AC_LANG_POP([C++])
|
||||
-if test "$LIB_SMBIOS" = "yes" ; then
|
||||
- AC_MSG_CHECKING([for libsmbios >= 0.13.4])
|
||||
- AC_TRY_RUN(
|
||||
- #include <smbios/version.h>
|
||||
- int main ()
|
||||
- {
|
||||
- int major ;
|
||||
- int minor ;
|
||||
- int micro ;
|
||||
-
|
||||
- if ( sscanf( LIBSMBIOS_RELEASE_VERSION , "%d.%d.%d", &major, &minor, µ ) == 3 ) {
|
||||
- if ((major == 0 && minor == 13 && micro >= 4) ||
|
||||
- (major >= 0 && minor > 13)) {
|
||||
- return 0;
|
||||
- }
|
||||
- }
|
||||
- return 1;
|
||||
- } , [USE_SMBIOS=yes; AC_MSG_RESULT(yes); AM_CONDITIONAL(HAVE_SMBIOS,true)],
|
||||
- [USE_SMBIOS=no; AC_MSG_RESULT(failed); AM_CONDITIONAL(HAVE_SMBIOS,false)])
|
||||
-else
|
||||
- USE_SMBIOS=no
|
||||
- AM_CONDITIONAL(HAVE_SMBIOS,false)
|
||||
-fi
|
||||
+USE_SMBIOS=no
|
||||
+AM_CONDITIONAL(HAVE_SMBIOS,false)
|
||||
|
||||
AC_ARG_WITH([libpci],
|
||||
[AS_HELP_STRING([--without-libpci],
|
||||
Index: hal-0.5.9.1/hald/linux/addons/Makefile.am
|
||||
===================================================================
|
||||
--- hal-0.5.9.1.orig/hald/linux/addons/Makefile.am 2008-04-14 22:45:18.000000000 +0100
|
||||
+++ hal-0.5.9.1/hald/linux/addons/Makefile.am 2008-04-14 22:46:05.000000000 +0100
|
||||
@@ -60,11 +60,6 @@
|
||||
hald_addon_usb_csr_LDADD = $(top_builddir)/libhal/libhal.la -lusb @GLIB_LIBS@
|
||||
endif
|
||||
|
||||
-if BUILD_DELL
|
||||
-libexec_PROGRAMS += hald-addon-dell-backlight
|
||||
-hald_addon_dell_backlight_SOURCES = addon-dell-backlight.cpp ../../logger.c
|
||||
-hald_addon_dell_backlight_LDADD = $(top_builddir)/libhal/libhal.la -lsmbios @GLIB_LIBS@
|
||||
-endif
|
||||
endif
|
||||
|
||||
hald_addon_acpi_SOURCES = addon-acpi.c ../../logger.c ../../util_helper.c
|
||||
@@ -0,0 +1,14 @@
|
||||
require hal.inc
|
||||
|
||||
PR = "r2"
|
||||
|
||||
EXTRA_OECONF += "--with-linux-input-header=${STAGING_INCDIR}/linux/input.h"
|
||||
EXTRA_OEMAKE += "-e 'udevrulesdir=$(sysconfdir)/udev/rules.d'"
|
||||
|
||||
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"
|
||||
@@ -0,0 +1,12 @@
|
||||
require hal.inc
|
||||
|
||||
PV = "0.5.9.1+git${SRCDATE}"
|
||||
PR = "r7"
|
||||
|
||||
SRC_URI = "git://anongit.freedesktop.org/hal/;protocol=git \
|
||||
file://20hal \
|
||||
file://99_hal"
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
DEFAULT_PREFERENCE = "-1"
|
||||
Reference in New Issue
Block a user