hal build fail issue while moving deve/libusb to libusb, with a patch

From: Daichi GOTO <daichi_at_ongs.co.jp>
Date: Wed, 11 Mar 2009 17:47:56 +0900
Hi hald and usb2 folks

Latest current including renamed libusb, and hal
(sysutils/hal) does not been suited.  If you try
to rebuild hal on that, you fail. So some
applications (like xorg) will not work right now.

I have included a patch to fix this issue.

That is not polished to merge to Ports Collection,
*just a hack*.  Read that patch and use it.

Thanks

-- 
   Daichi GOTO, http://people.freebsd.org/~daichi


diff -urBN hal.orig/Makefile hal/Makefile
--- hal.orig/Makefile	2009-03-03 12:30:20.000000000 +0900
+++ hal/Makefile	2009-03-10 21:28:10.000000000 +0900
_at__at_ -44,7 +44,7 @@
 		--with-deprecated-keys \
 		--localstatedir=/var
 CONFIGURE_ENV=	CPPFLAGS="-I${LOCALBASE}/include -DHAVE_CK_0_3" \
-		LDFLAGS="-L${LOCALBASE}/lib" \
+		LDFLAGS="-L/usr/lib -L${LOCALBASE}/lib" \
 		GTKDOC="false"
 
 #HALVERSION=	0.5.10
diff -urBN hal.orig/files/patch-configure hal/files/patch-configure
--- hal.orig/files/patch-configure	2009-02-24 06:44:23.000000000 +0900
+++ hal/files/patch-configure	2009-03-10 21:28:22.000000000 +0900
_at__at_ -189,13 +189,13 _at__at_
  
  
 +if test "x$HALD_BACKEND" = "xfreebsd"; then
-+    { echo "$as_me:$LINENO: checking for libusb20_dev_get_info in -lusb20" >&5
-+echo $ECHO_N "checking for libusb20_dev_get_info in -lusb20... $ECHO_C" >&6; }
++    { echo "$as_me:$LINENO: checking for libusb20_dev_get_info in -lusb" >&5
++echo $ECHO_N "checking for libusb20_dev_get_info in -lusb... $ECHO_C" >&6; }
 +if test "${ac_cv_lib_usb20_libusb20_dev_get_info+set}" = set; then
 +  echo $ECHO_N "(cached) $ECHO_C" >&6
 +else
 +  ac_check_lib_save_LIBS=$LIBS
-+LIBS="-lusb20  $LIBS"
++LIBS="-lusb  $LIBS"
 +cat >conftest.$ac_ext <<_ACEOF
 +/* confdefs.h.  */
 +_ACEOF
diff -urBN hal.orig/files/patch-configure.in hal/files/patch-configure.in
--- hal.orig/files/patch-configure.in	2009-02-24 06:44:23.000000000 +0900
+++ hal/files/patch-configure.in	2009-03-10 21:16:31.000000000 +0900
_at__at_ -13,11 +13,11 _at__at_
  AM_CONDITIONAL(HALD_COMPILE_SOLARIS, [test x$HALD_BACKEND = xsolaris], [Compiling for Solaris])
  AC_SUBST(HALD_BACKEND)
 +if test "x$HALD_BACKEND" = "xfreebsd"; then
-+    AC_CHECK_LIB([usb20], [libusb20_dev_get_info], [USE_LIBUSB20=yes], [USE_LIBUSB20=no])
++    AC_CHECK_LIB([usb], [libusb20_dev_get_info], [USE_LIBUSB20=yes], [USE_LIBUSB20=no])
 +fi
 +AM_CONDITIONAL([HAVE_LIBUSB20],[test "x$USE_LIBUSB20" = "xyes"])
 +if test "x$USE_LIBUSB20" = "xyes"; then
-+    AC_DEFINE(HAVE_LIBUSB20, 1, [Set if we need libusb20])
++    AC_DEFINE(HAVE_LIBUSB20, 1, [Set if we need libusb])
 +fi
 +
  
diff -urBN hal.orig/files/patch-hald_freebsd_Makefile.am hal/files/patch-hald_freebsd_Makefile.am
--- hal.orig/files/patch-hald_freebsd_Makefile.am	2009-02-24 06:44:23.000000000 +0900
+++ hal/files/patch-hald_freebsd_Makefile.am	2009-03-10 21:31:25.000000000 +0900
_at__at_ -8,7 +8,7 @@
 +libhald_freebsd_la_SOURCES += 	\
 +	hf-usb2.c		\
 +	hf-usb2.h
-+libhald_freebsd_la_LDFLAGS += -lusb20
++libhald_freebsd_la_LDFLAGS += -lusb
 +endif
 +
  EXTRA_DIST = README TODO
diff -urBN hal.orig/files/patch-hald_freebsd_Makefile.in hal/files/patch-hald_freebsd_Makefile.in
--- hal.orig/files/patch-hald_freebsd_Makefile.in	2009-02-24 06:44:23.000000000 +0900
+++ hal/files/patch-hald_freebsd_Makefile.in	2009-03-10 21:31:32.000000000 +0900
_at__at_ -8,7 +8,7 _at__at_
 +_at_HAVE_LIBUSB20_TRUE@	hf-usb2.c		\
 +_at_HAVE_LIBUSB20_TRUE_at_	hf-usb2.h
 +
-+_at_HAVE_LIBUSB20_TRUE_at_am__append_2 = -lusb20
++_at_HAVE_LIBUSB20_TRUE_at_am__append_2 = -lusb
  subdir = hald/freebsd
  DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in TODO
  ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
diff -urBN hal.orig/files/patch-hald_freebsd_probing_Makefile.am hal/files/patch-hald_freebsd_probing_Makefile.am
--- hal.orig/files/patch-hald_freebsd_probing_Makefile.am	2009-02-24 06:44:23.000000000 +0900
+++ hal/files/patch-hald_freebsd_probing_Makefile.am	2009-03-10 21:30:02.000000000 +0900
_at__at_ -31,12 +31,12 _at__at_
 +hald_probe_usb2_device_SOURCES = probe-usb2-device.c
 +hald_probe_usb2_device_LDADD = \
 +	$(top_builddir)/hald/freebsd/libprobe/libhald_freebsd_probe.la  \
-+	-lusb20
++	-lusb
 +
 +hald_probe_usb2_interface_SOURCES = probe-usb2-interface.c
 +hald_probe_usb2_interface_LDADD = \
 +	$(top_builddir)/hald/freebsd/libprobe/libhald_freebsd_probe.la  \
-+	-lusb20
++	-lusb
 +endif
 +
 +hald_probe_mouse_SOURCES = probe-mouse.c
diff -urBN hal.orig/files/patch-hald_freebsd_probing_Makefile.in hal/files/patch-hald_freebsd_probing_Makefile.in
--- hal.orig/files/patch-hald_freebsd_probing_Makefile.in	2009-02-24 06:44:23.000000000 +0900
+++ hal/files/patch-hald_freebsd_probing_Makefile.in	2009-03-10 21:30:10.000000000 +0900
_at__at_ -90,12 +90,12 _at__at_
 +_at_HAVE_LIBUSB20_TRUE_at_hald_probe_usb2_device_SOURCES = probe-usb2-device.c
 +_at_HAVE_LIBUSB20_TRUE_at_hald_probe_usb2_device_LDADD = \
 +_at_HAVE_LIBUSB20_TRUE_at_	$(top_builddir)/hald/freebsd/libprobe/libhald_freebsd_probe.la  \
-+_at_HAVE_LIBUSB20_TRUE@	-lusb20
++_at_HAVE_LIBUSB20_TRUE_at_	-lusb
 +
 +_at_HAVE_LIBUSB20_TRUE_at_hald_probe_usb2_interface_SOURCES = probe-usb2-interface.c
 +_at_HAVE_LIBUSB20_TRUE_at_hald_probe_usb2_interface_LDADD = \
 +_at_HAVE_LIBUSB20_TRUE_at_	$(top_builddir)/hald/freebsd/libprobe/libhald_freebsd_probe.la  \
-+_at_HAVE_LIBUSB20_TRUE_at_	-lusb20
++_at_HAVE_LIBUSB20_TRUE@	-lusb
 +
 +hald_probe_mouse_SOURCES = probe-mouse.c
 +hald_probe_mouse_CPPFLAGS = $(AM_CPPFLAGS) _at_GLIB_CFLAGS@
Received on Wed Mar 11 2009 - 07:47:58 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:43 UTC