Index: head/sysutils/hal/Makefile =================================================================== --- head/sysutils/hal/Makefile (revision 422641) +++ head/sysutils/hal/Makefile (revision 422642) @@ -1,107 +1,107 @@ # Created by: Joe Marcus Clarke # $FreeBSD$ # $MCom: ports/sysutils/hal/Makefile,v 1.81 2010/04/13 02:49:07 mezz Exp $ PORTNAME= hal DISTVERSION= 0.5.14 -PORTREVISION= 30 +PORTREVISION= 31 CATEGORIES= sysutils MASTER_SITES= http://hal.freedesktop.org/releases/ MAINTAINER= gnome@FreeBSD.org COMMENT= Hardware Abstraction Layer for simplifying device access BUILD_DEPENDS= ${LOCALBASE}/include/linux/videodev2.h:multimedia/v4l_compat # keep shlib version, to prevent confusion with polkit-* from sysutils/polkit LIB_DEPENDS= libpolkit.so.2:sysutils/policykit \ libvolume_id.so:devel/libvolume_id \ libck-connector.so:sysutils/consolekit RUN_DEPENDS= ${LOCALBASE}/share/pciids/pci.ids:misc/pciids USES= gettext gmake libtool:keepla pathfix pkgconfig python shebangfix USE_GNOME= intlhack GNU_CONFIGURE= yes USE_LDCONFIG= yes CONFIGURE_ARGS= --disable-gtk-doc \ --with-backend=freebsd \ --disable-docbook-docs \ --with-pci-ids=${LOCALBASE}/share/pciids \ --disable-usb-ids \ --without-libpci \ --disable-usb \ --disable-smbios \ --disable-apm \ --disable-pmu \ --enable-policy-kit \ --enable-console-kit \ --with-socket-dir=/var/run/hald \ --with-eject=/usr/sbin/cdcontrol \ --with-pid-file=/var/run/hald/hald.pid \ --with-deprecated-keys \ --localstatedir=/var CONFIGURE_ENV= GTKDOC="false" CPPFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -L${LOCALBASE}/lib bash_CMD= ${SH} SHEBANG_FILES= tools/hal-* #HALVERSION= 0.5.10 #SNAPVERSION= 20080218 USERS= haldaemon GROUPS= haldaemon USE_RC_SUBR= hald USE_GNOME_SUBR= yes DOCSDIR= ${PREFIX}/share/doc/${PORTNAME}-${DISTVERSION} PLIST_SUB= VERSION=${DISTVERSION} RC_FILES= hal.conf:${PREFIX}/etc/dbus-1/system.d PLIST_FILES= ${PRIV_FILES:S|^|%%DATADIR%%/dist/|} SUB_FILES= pkg-install pkg-deinstall SUB_LIST= RC_FILES="${RC_FILES}" INSTALL_TARGET= install-strip OPTIONS_DEFINE= FIXED_MOUNTPOINTS DOCS FIXED_MOUNTPOINTS_DESC= use fixed mountpoints FIXED_MOUNTPOINTS_EXTRA_PATCHES= ${FILESDIR}/extra-patch-tools_hal-storage-mount.c .include .if (${ARCH}=="i386" || ${ARCH}=="amd64" || ${ARCH}=="ia64") RUN_DEPENDS+= dmidecode:sysutils/dmidecode .endif post-patch: @${REINPLACE_CMD} -e 's/==/=/g' ${WRKSRC}/tools/hal-luks* @${REINPLACE_CMD} -e '/^scriptdir = /s|[(]libexecdir[)]/scripts|(libexecdir)/hal/scripts|' \ ${WRKSRC}/tools/Makefile.in \ ${WRKSRC}/tools/freebsd/Makefile.in @${REINPLACE_CMD} -e 's|[(]libexecdir[)]/scripts|(libexecdir)/hal/scripts|' \ ${WRKSRC}/hald/Makefile.in \ ${WRKSRC}/tools/Makefile.in @${REINPLACE_CMD} -e 's|user="0"|group="operator"|g' \ ${WRKSRC}/hal.conf.in @${SED} -e 's|%%LOCALBASE%%|${LOCALBASE}|' \ < ${FILESDIR}/README.fuse > ${WRKDIR}/README.fuse post-install: @${MKDIR} ${STAGEDIR}${DATADIR}/dist ${INSTALL_DATA} ${WRKSRC}/hal.conf ${STAGEDIR}${DATADIR}/dist @${MKDIR} ${STAGEDIR}${PREFIX}/share/hal/fdi/policy/10osvendor ${INSTALL_DATA} ${FILESDIR}/10-mouse-sysmouse.fdi \ ${STAGEDIR}${PREFIX}/share/hal/fdi/policy/10osvendor ${INSTALL_SCRIPT} ${FILESDIR}/mount-fuse \ ${STAGEDIR}${PREFIX}/share/hal/mount-fuse @${MKDIR} ${STAGEDIR}/var/lib/hal post-install-DOCS-on: @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/hald/freebsd/README \ ${STAGEDIR}${DOCSDIR}/README.freebsd ${INSTALL_DATA} ${WRKDIR}/README.fuse \ ${STAGEDIR}${DOCSDIR}/README.fuse .include Index: head/sysutils/hal/files/patch-hald_freebsd_hf-scsi.c =================================================================== --- head/sysutils/hal/files/patch-hald_freebsd_hf-scsi.c (revision 422641) +++ head/sysutils/hal/files/patch-hald_freebsd_hf-scsi.c (revision 422642) @@ -1,28 +1,37 @@ --- ./hald/freebsd/hf-scsi.c.orig 2009-08-24 14:42:29.000000000 +0200 +++ ./hald/freebsd/hf-scsi.c 2013-10-23 13:11:08.979758920 +0200 @@ -223,7 +223,7 @@ hal_device_copy_property(parent, "scsi.lun", device, "storage.lun"); /* do not stop here, in case it's an umass device */ } - else if (! strcmp(bus, "usb")) + else if (hal_device_has_property(parent, "scsi_host.freebsd.driver") && ! strcmp(hal_device_property_get_string(parent, "scsi_host.freebsd.driver"), "umass")) { hal_device_property_set_string(device, "storage.bus", "usb"); hal_device_property_set_string(device, "storage.originating_device", hal_device_get_udi(parent)); +@@ -301,7 +301,7 @@ + + driver = hal_device_property_get_string(child, "freebsd.driver"); + /* ATAPI devices: CD-ROM (acd), tape (ast) or floppy (afd) */ +- if (! driver || (strcmp(driver, "acd") && strcmp(driver, "ast") && strcmp(driver, "afd"))) ++ if (! driver || (strcmp(driver, "acd") && strcmp(driver, "ast") && strcmp(driver, "afd") && strcmp(driver, "cd"))) + continue; + + phys_device = hal_device_property_get_string(child, "storage.originating_device"); @@ -508,6 +508,16 @@ if (! parent || ! hal_device_property_get_bool(parent, "info.ignore")) { device = hf_scsi_bus_device_new(parent, match); + /* + * Due to synchronization problems, the SCSI bus could be + * created before the USB interface. Mark it as a USB mass + * storage device to ensure it is detected as such. + */ + if (! strcmp(match->dev_name, "umass-sim")) + { + hal_device_property_set_string(device, "scsi_host.freebsd.driver", "umass"); + hal_device_property_set_int(device, "scsi_host.freebsd.unit", match->unit_number); + } hf_device_preprobe_and_add(device); } }