summaryrefslogtreecommitdiff
path: root/sysutils/hal/files/patch-configure
blob: 65173c754872f659fb4d849357461fb3ad9d7e01 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
--- configure.orig	2009-03-14 00:22:20.000000000 -0400
+++ configure	2009-03-14 00:22:44.000000000 -0400
@@ -930,6 +930,9 @@ HALD_COMPILE_FREEBSD_FALSE
 HALD_COMPILE_SOLARIS_TRUE
 HALD_COMPILE_SOLARIS_FALSE
 HALD_BACKEND
+HAVE_LIBUSB20_TRUE
+HAVE_LIBUSB20_FALSE
+LIBUSB20_LIBS
 HAVE_CONKIT_TRUE
 HAVE_CONKIT_FALSE
 GPERF
@@ -5944,7 +5947,7 @@ ia64-*-hpux*)
   ;;
 *-*-irix6*)
   # Find out which ABI we are using.
-  echo '#line 5947 "configure"' > conftest.$ac_ext
+  echo '#line 5950 "configure"' > conftest.$ac_ext
   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
@@ -8596,11 +8599,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:8599: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:8602: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:8603: \$? = $ac_status" >&5
+   echo "$as_me:8606: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -8886,11 +8889,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:8889: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:8892: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:8893: \$? = $ac_status" >&5
+   echo "$as_me:8896: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -8990,11 +8993,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:8993: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:8996: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:8997: \$? = $ac_status" >&5
+   echo "$as_me:9000: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -11354,7 +11357,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 11357 "configure"
+#line 11360 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -11454,7 +11457,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 11457 "configure"
+#line 11460 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -13855,11 +13858,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:13858: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:13861: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:13862: \$? = $ac_status" >&5
+   echo "$as_me:13865: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -13959,11 +13962,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:13962: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:13965: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:13966: \$? = $ac_status" >&5
+   echo "$as_me:13969: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -15542,11 +15545,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:15545: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15548: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:15549: \$? = $ac_status" >&5
+   echo "$as_me:15552: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -15646,11 +15649,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:15649: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15652: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:15653: \$? = $ac_status" >&5
+   echo "$as_me:15656: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -17853,11 +17856,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:17856: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:17859: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:17860: \$? = $ac_status" >&5
+   echo "$as_me:17863: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -18143,11 +18146,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:18146: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:18149: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:18150: \$? = $ac_status" >&5
+   echo "$as_me:18153: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -18247,11 +18250,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:18250: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:18253: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:18254: \$? = $ac_status" >&5
+   echo "$as_me:18257: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -23420,6 +23423,9 @@ else
 fi
 
 
+USE_LIBUSB20=no
+USE_LIBUSB=no
+LIBUSB20_LIBS=""
 
 # Check whether --with-backend was given.
 if test "${with_backend+set}" = set; then
@@ -23477,6 +23483,176 @@ else
 fi
 
 
+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; }
+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"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+/* Override any GCC internal prototype to avoid an error.
+   Use char because int might match the return type of a GCC
+   builtin and then its argument prototype would still apply.  */
+#ifdef __cplusplus
+extern "C"
+#endif
+char libusb20_dev_get_info ();
+int
+main ()
+{
+return libusb20_dev_get_info ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+	 test -z "$ac_c_werror_flag" ||
+	 test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_usb20_libusb20_dev_get_info=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+	ac_cv_lib_usb20_libusb20_dev_get_info=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_usb20_libusb20_dev_get_info" >&5
+echo "${ECHO_T}$ac_cv_lib_usb20_libusb20_dev_get_info" >&6; }
+if test $ac_cv_lib_usb20_libusb20_dev_get_info = yes; then
+  USE_LIBUSB20=yes
+else
+  USE_LIBUSB20=no
+fi
+
+fi
+if test "x$USE_LIBUSB20" = "xno"; then
+    { 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_usb_libusb20_dev_get_info+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lusb  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+/* Override any GCC internal prototype to avoid an error.
+   Use char because int might match the return type of a GCC
+   builtin and then its argument prototype would still apply.  */
+#ifdef __cplusplus
+extern "C"
+#endif
+char libusb20_dev_get_info ();
+int
+main ()
+{
+return libusb20_dev_get_info ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+	 test -z "$ac_c_werror_flag" ||
+	 test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_usb_libusb20_dev_get_info=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+	ac_cv_lib_usb_libusb20_dev_get_info=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_usb_libusb20_dev_get_info" >&5
+echo "${ECHO_T}$ac_cv_lib_usb_libusb20_dev_get_info" >&6; }
+if test $ac_cv_lib_usb_libusb20_dev_get_info = yes; then
+  USE_LIBUSB=yes
+else
+  USE_LIBUSB=np
+fi
+
+fi
+ if test "x$USE_LIBUSB20" = "xyes"; then
+  HAVE_LIBUSB20_TRUE=
+  HAVE_LIBUSB20_FALSE='#'
+else
+  HAVE_LIBUSB20_TRUE='#'
+  HAVE_LIBUSB20_FALSE=
+fi
+
+ if test "x$USE_LIBUSB" = "xyes"; then
+  HAVE_LIBUSB20_TRUE=
+  HAVE_LIBUSB20_FALSE='#'
+else
+  HAVE_LIBUSB20_TRUE='#'
+  HAVE_LIBUSB20_FALSE=
+fi
+
+if test "x$USE_LIBUSB20" = "xyes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBUSB20 1
+_ACEOF
+
+    LIBUSB20_LIBS="-lusb20"
+elif test "x$USE_LIBUSB" = "xyes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBUSB20 1
+_ACEOF
+
+    LIBUSB20_LIBS="-lusb"
+fi
+
 
 
 cat >>confdefs.h <<_ACEOF
@@ -25602,6 +25778,20 @@ echo "$as_me: error: conditional \"HALD_
 Usually this means the macro was only invoked conditionally." >&2;}
    { (exit 1); exit 1; }; }
 fi
+if test -z "${HAVE_LIBUSB20_TRUE}" && test -z "${HAVE_LIBUSB20_FALSE}"; then
+  { { echo "$as_me:$LINENO: error: conditional \"HAVE_LIBUSB20\" was never defined.
+Usually this means the macro was only invoked conditionally." >&5
+echo "$as_me: error: conditional \"HAVE_LIBUSB20\" was never defined.
+Usually this means the macro was only invoked conditionally." >&2;}
+   { (exit 1); exit 1; }; }
+fi
+if test -z "${HAVE_LIBUSB20_TRUE}" && test -z "${HAVE_LIBUSB20_FALSE}"; then
+  { { echo "$as_me:$LINENO: error: conditional \"HAVE_LIBUSB20\" was never defined.
+Usually this means the macro was only invoked conditionally." >&5
+echo "$as_me: error: conditional \"HAVE_LIBUSB20\" was never defined.
+Usually this means the macro was only invoked conditionally." >&2;}
+   { (exit 1); exit 1; }; }
+fi
 if test -z "${HAVE_CONKIT_TRUE}" && test -z "${HAVE_CONKIT_FALSE}"; then
   { { echo "$as_me:$LINENO: error: conditional \"HAVE_CONKIT\" was never defined.
 Usually this means the macro was only invoked conditionally." >&5
@@ -26568,6 +26758,9 @@ HALD_COMPILE_FREEBSD_FALSE!$HALD_COMPILE
 HALD_COMPILE_SOLARIS_TRUE!$HALD_COMPILE_SOLARIS_TRUE$ac_delim
 HALD_COMPILE_SOLARIS_FALSE!$HALD_COMPILE_SOLARIS_FALSE$ac_delim
 HALD_BACKEND!$HALD_BACKEND$ac_delim
+HAVE_LIBUSB20_TRUE!$HAVE_LIBUSB20_TRUE$ac_delim
+HAVE_LIBUSB20_FALSE!$HAVE_LIBUSB20_FALSE$ac_delim
+LIBUSB20_LIBS!$LIBUSB20_LIBS$ac_delim
 HAVE_CONKIT_TRUE!$HAVE_CONKIT_TRUE$ac_delim
 HAVE_CONKIT_FALSE!$HAVE_CONKIT_FALSE$ac_delim
 GPERF!$GPERF$ac_delim
@@ -26597,9 +26790,6 @@ DBUS_CFLAGS!$DBUS_CFLAGS$ac_delim
 DBUS_LIBS!$DBUS_LIBS$ac_delim
 GLIB_CFLAGS!$GLIB_CFLAGS$ac_delim
 GLIB_LIBS!$GLIB_LIBS$ac_delim
-VOLUME_ID_CFLAGS!$VOLUME_ID_CFLAGS$ac_delim
-VOLUME_ID_LIBS!$VOLUME_ID_LIBS$ac_delim
-HALD_OS_LIBS!$HALD_OS_LIBS$ac_delim
 _ACEOF
 
   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
@@ -26641,6 +26831,9 @@ _ACEOF
 ac_delim='%!_!# '
 for ac_last_try in false false false false false :; do
   cat >conf$$subs.sed <<_ACEOF
+VOLUME_ID_CFLAGS!$VOLUME_ID_CFLAGS$ac_delim
+VOLUME_ID_LIBS!$VOLUME_ID_LIBS$ac_delim
+HALD_OS_LIBS!$HALD_OS_LIBS$ac_delim
 XMLTO!$XMLTO$ac_delim
 XMLLINT!$XMLLINT$ac_delim
 DOCBOOK_DOCS_ENABLED_TRUE!$DOCBOOK_DOCS_ENABLED_TRUE$ac_delim
@@ -26672,7 +26865,7 @@ LIBOBJS!$LIBOBJS$ac_delim
 LTLIBOBJS!$LTLIBOBJS$ac_delim
 _ACEOF
 
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 29; then
+  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 32; then
     break
   elif $ac_last_try; then
     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5