hal build fail issue while moving deve/libusb to libusb,
with a patch
Daichi GOTO
daichi at ongs.co.jp
Wed Mar 11 01:47:58 PDT 2009
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
-------------- next part --------------
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
@@ -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
@@ -189,13 +189,13 @@
+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
@@ -13,11 +13,11 @@
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
@@ -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
@@ -8,7 +8,7 @@
+ at HAVE_LIBUSB20_TRUE@ hf-usb2.c \
+ at HAVE_LIBUSB20_TRUE@ hf-usb2.h
+
-+ at HAVE_LIBUSB20_TRUE@am__append_2 = -lusb20
++ at HAVE_LIBUSB20_TRUE@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
@@ -31,12 +31,12 @@
+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
@@ -90,12 +90,12 @@
+ at HAVE_LIBUSB20_TRUE@hald_probe_usb2_device_SOURCES = probe-usb2-device.c
+ at HAVE_LIBUSB20_TRUE@hald_probe_usb2_device_LDADD = \
+ at HAVE_LIBUSB20_TRUE@ $(top_builddir)/hald/freebsd/libprobe/libhald_freebsd_probe.la \
-+ at HAVE_LIBUSB20_TRUE@ -lusb20
++ at HAVE_LIBUSB20_TRUE@ -lusb
+
+ at HAVE_LIBUSB20_TRUE@hald_probe_usb2_interface_SOURCES = probe-usb2-interface.c
+ at HAVE_LIBUSB20_TRUE@hald_probe_usb2_interface_LDADD = \
+ at HAVE_LIBUSB20_TRUE@ $(top_builddir)/hald/freebsd/libprobe/libhald_freebsd_probe.la \
-+ at HAVE_LIBUSB20_TRUE@ -lusb20
++ at HAVE_LIBUSB20_TRUE@ -lusb
+
+hald_probe_mouse_SOURCES = probe-mouse.c
+hald_probe_mouse_CPPFLAGS = $(AM_CPPFLAGS) @GLIB_CFLAGS@
More information about the freebsd-current
mailing list