3045 |
3045 |
3046 |
3046 |
3047 # |
3047 # |
3048 # Libraries for mbsePi-apps |
3048 # Libraries for mbsePi-apps |
3049 # |
3049 # |
3050 |
3050 WIRINGPI=No |
3051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mosquitto_lib_init in -lmosquitto" >&5 |
3051 |
3052 $as_echo_n "checking for mosquitto_lib_init in -lmosquitto... " >&6; } |
3052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wiringPiSetup in -lwiringPi" >&5 |
3053 if ${ac_cv_lib_mosquitto_mosquitto_lib_init+:} false; then : |
3053 $as_echo_n "checking for wiringPiSetup in -lwiringPi... " >&6; } |
|
3054 if ${ac_cv_lib_wiringPi_wiringPiSetup+:} false; then : |
3054 $as_echo_n "(cached) " >&6 |
3055 $as_echo_n "(cached) " >&6 |
3055 else |
3056 else |
3056 ac_check_lib_save_LIBS=$LIBS |
3057 ac_check_lib_save_LIBS=$LIBS |
3057 LIBS="-lmosquitto $LIBS" |
3058 LIBS="-lwiringPi $LIBS" |
3058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3059 /* end confdefs.h. */ |
3060 /* end confdefs.h. */ |
3060 |
3061 |
3061 /* Override any GCC internal prototype to avoid an error. |
3062 /* Override any GCC internal prototype to avoid an error. |
3062 Use char because int might match the return type of a GCC |
3063 Use char because int might match the return type of a GCC |
3063 builtin and then its argument prototype would still apply. */ |
3064 builtin and then its argument prototype would still apply. */ |
3064 #ifdef __cplusplus |
3065 #ifdef __cplusplus |
3065 extern "C" |
3066 extern "C" |
3066 #endif |
3067 #endif |
3067 char mosquitto_lib_init (); |
3068 char wiringPiSetup (); |
3068 int |
3069 int |
3069 main () |
3070 main () |
3070 { |
3071 { |
3071 return mosquitto_lib_init (); |
3072 return wiringPiSetup (); |
3072 ; |
3073 ; |
3073 return 0; |
3074 return 0; |
3074 } |
3075 } |
3075 _ACEOF |
3076 _ACEOF |
3076 if ac_fn_c_try_link "$LINENO"; then : |
3077 if ac_fn_c_try_link "$LINENO"; then : |
3077 ac_cv_lib_mosquitto_mosquitto_lib_init=yes |
3078 ac_cv_lib_wiringPi_wiringPiSetup=yes |
3078 else |
3079 else |
3079 ac_cv_lib_mosquitto_mosquitto_lib_init=no |
3080 ac_cv_lib_wiringPi_wiringPiSetup=no |
3080 fi |
3081 fi |
3081 rm -f core conftest.err conftest.$ac_objext \ |
3082 rm -f core conftest.err conftest.$ac_objext \ |
3082 conftest$ac_exeext conftest.$ac_ext |
3083 conftest$ac_exeext conftest.$ac_ext |
3083 LIBS=$ac_check_lib_save_LIBS |
3084 LIBS=$ac_check_lib_save_LIBS |
3084 fi |
3085 fi |
3085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mosquitto_mosquitto_lib_init" >&5 |
3086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_wiringPi_wiringPiSetup" >&5 |
3086 $as_echo "$ac_cv_lib_mosquitto_mosquitto_lib_init" >&6; } |
3087 $as_echo "$ac_cv_lib_wiringPi_wiringPiSetup" >&6; } |
3087 if test "x$ac_cv_lib_mosquitto_mosquitto_lib_init" = xyes; then : |
3088 if test "x$ac_cv_lib_wiringPi_wiringPiSetup" = xyes; then : |
3088 result=yes |
3089 result=yes |
3089 else |
3090 else |
3090 result=no |
3091 result=no |
3091 fi |
3092 fi |
3092 |
3093 |
3093 if test "$result" = "yes"; then |
3094 if test "$result" = "yes"; then |
|
3095 LIBS="$LIBS -lwiringPi -lwiringPiDev" |
3094 ac_ext=c |
3096 ac_ext=c |
3095 ac_cpp='$CPP $CPPFLAGS' |
3097 ac_cpp='$CPP $CPPFLAGS' |
3096 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3098 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3097 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3099 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3098 ac_compiler_gnu=$ac_cv_c_compiler_gnu |
3100 ac_compiler_gnu=$ac_cv_c_compiler_gnu |
3486 fi |
3488 fi |
3487 |
3489 |
3488 done |
3490 done |
3489 |
3491 |
3490 |
3492 |
3491 for ac_header in mosquitto.h |
3493 for ac_header in wiringPi.h |
3492 do : |
|
3493 ac_fn_c_check_header_mongrel "$LINENO" "mosquitto.h" "ac_cv_header_mosquitto_h" "$ac_includes_default" |
|
3494 if test "x$ac_cv_header_mosquitto_h" = xyes; then : |
|
3495 cat >>confdefs.h <<_ACEOF |
|
3496 #define HAVE_MOSQUITTO_H 1 |
|
3497 _ACEOF |
|
3498 MOSQUITTO=Yes |
|
3499 else |
|
3500 MOSQUITTO=No |
|
3501 fi |
|
3502 |
|
3503 done |
|
3504 |
|
3505 else |
|
3506 as_fn_error $? "libmosquitto not found" "$LINENO" 5 |
|
3507 fi |
|
3508 |
|
3509 WIRINGPI=No |
|
3510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wiringPiSetup in -lwiringPi" >&5 |
|
3511 $as_echo_n "checking for wiringPiSetup in -lwiringPi... " >&6; } |
|
3512 if ${ac_cv_lib_wiringPi_wiringPiSetup+:} false; then : |
|
3513 $as_echo_n "(cached) " >&6 |
|
3514 else |
|
3515 ac_check_lib_save_LIBS=$LIBS |
|
3516 LIBS="-lwiringPi $LIBS" |
|
3517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
|
3518 /* end confdefs.h. */ |
|
3519 |
|
3520 /* Override any GCC internal prototype to avoid an error. |
|
3521 Use char because int might match the return type of a GCC |
|
3522 builtin and then its argument prototype would still apply. */ |
|
3523 #ifdef __cplusplus |
|
3524 extern "C" |
|
3525 #endif |
|
3526 char wiringPiSetup (); |
|
3527 int |
|
3528 main () |
|
3529 { |
|
3530 return wiringPiSetup (); |
|
3531 ; |
|
3532 return 0; |
|
3533 } |
|
3534 _ACEOF |
|
3535 if ac_fn_c_try_link "$LINENO"; then : |
|
3536 ac_cv_lib_wiringPi_wiringPiSetup=yes |
|
3537 else |
|
3538 ac_cv_lib_wiringPi_wiringPiSetup=no |
|
3539 fi |
|
3540 rm -f core conftest.err conftest.$ac_objext \ |
|
3541 conftest$ac_exeext conftest.$ac_ext |
|
3542 LIBS=$ac_check_lib_save_LIBS |
|
3543 fi |
|
3544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_wiringPi_wiringPiSetup" >&5 |
|
3545 $as_echo "$ac_cv_lib_wiringPi_wiringPiSetup" >&6; } |
|
3546 if test "x$ac_cv_lib_wiringPi_wiringPiSetup" = xyes; then : |
|
3547 result=yes |
|
3548 else |
|
3549 result=no |
|
3550 fi |
|
3551 |
|
3552 if test "$result" = "yes"; then |
|
3553 LIBS="$LIBS -lwiringPi -lwiringPiDev" |
|
3554 for ac_header in wiringPi.h |
|
3555 do : |
3494 do : |
3556 ac_fn_c_check_header_mongrel "$LINENO" "wiringPi.h" "ac_cv_header_wiringPi_h" "$ac_includes_default" |
3495 ac_fn_c_check_header_mongrel "$LINENO" "wiringPi.h" "ac_cv_header_wiringPi_h" "$ac_includes_default" |
3557 if test "x$ac_cv_header_wiringPi_h" = xyes; then : |
3496 if test "x$ac_cv_header_wiringPi_h" = xyes; then : |
3558 cat >>confdefs.h <<_ACEOF |
3497 cat >>confdefs.h <<_ACEOF |
3559 #define HAVE_WIRINGPI_H 1 |
3498 #define HAVE_WIRINGPI_H 1 |
3564 fi |
3503 fi |
3565 |
3504 |
3566 done |
3505 done |
3567 |
3506 |
3568 fi |
3507 fi |
3569 |
|
3570 OWSERVER=No |
|
3571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OWNET_init in -lownet" >&5 |
|
3572 $as_echo_n "checking for OWNET_init in -lownet... " >&6; } |
|
3573 if ${ac_cv_lib_ownet_OWNET_init+:} false; then : |
|
3574 $as_echo_n "(cached) " >&6 |
|
3575 else |
|
3576 ac_check_lib_save_LIBS=$LIBS |
|
3577 LIBS="-lownet $LIBS" |
|
3578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
|
3579 /* end confdefs.h. */ |
|
3580 |
|
3581 /* Override any GCC internal prototype to avoid an error. |
|
3582 Use char because int might match the return type of a GCC |
|
3583 builtin and then its argument prototype would still apply. */ |
|
3584 #ifdef __cplusplus |
|
3585 extern "C" |
|
3586 #endif |
|
3587 char OWNET_init (); |
|
3588 int |
|
3589 main () |
|
3590 { |
|
3591 return OWNET_init (); |
|
3592 ; |
|
3593 return 0; |
|
3594 } |
|
3595 _ACEOF |
|
3596 if ac_fn_c_try_link "$LINENO"; then : |
|
3597 ac_cv_lib_ownet_OWNET_init=yes |
|
3598 else |
|
3599 ac_cv_lib_ownet_OWNET_init=no |
|
3600 fi |
|
3601 rm -f core conftest.err conftest.$ac_objext \ |
|
3602 conftest$ac_exeext conftest.$ac_ext |
|
3603 LIBS=$ac_check_lib_save_LIBS |
|
3604 fi |
|
3605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ownet_OWNET_init" >&5 |
|
3606 $as_echo "$ac_cv_lib_ownet_OWNET_init" >&6; } |
|
3607 if test "x$ac_cv_lib_ownet_OWNET_init" = xyes; then : |
|
3608 result=yes |
|
3609 else |
|
3610 result=no |
|
3611 fi |
|
3612 |
|
3613 if test "$result" = "yes"; then |
|
3614 LIBS="$LIBS -lownet" |
|
3615 for ac_header in ownetapi.h |
|
3616 do : |
|
3617 ac_fn_c_check_header_mongrel "$LINENO" "ownetapi.h" "ac_cv_header_ownetapi_h" "$ac_includes_default" |
|
3618 if test "x$ac_cv_header_ownetapi_h" = xyes; then : |
|
3619 cat >>confdefs.h <<_ACEOF |
|
3620 #define HAVE_OWNETAPI_H 1 |
|
3621 _ACEOF |
|
3622 OWSERVER=Yes |
|
3623 else |
|
3624 OWSERVER=No |
|
3625 fi |
|
3626 |
|
3627 done |
|
3628 |
|
3629 fi |
|
3630 |
|
3631 |
3508 |
3632 # |
3509 # |
3633 # Additional commandline switches |
3510 # Additional commandline switches |
3634 # |
3511 # |
3635 # Check whether --enable-experiment was given. |
3512 # Check whether --enable-experiment was given. |
5178 Configuration summary : |
5055 Configuration summary : |
5179 |
5056 |
5180 Version : ............ ${VERSION} |
5057 Version : ............ ${VERSION} |
5181 Main directory : ..... ${prefix} |
5058 Main directory : ..... ${prefix} |
5182 WiringPi : ........... ${WIRINGPI} |
5059 WiringPi : ........... ${WIRINGPI} |
5183 OWserver : ........... ${OWSERVER} |
|
5184 |
5060 |
5185 Now type 'make' and 'sudo make install' |
5061 Now type 'make' and 'sudo make install' |
5186 " >&5 |
5062 " >&5 |
5187 $as_echo " |
5063 $as_echo " |
5188 -=-=-=-=-=-=-=-=-=-= Configuration Complete =-=-=-=-=-=-=-=-=-=- |
5064 -=-=-=-=-=-=-=-=-=-= Configuration Complete =-=-=-=-=-=-=-=-=-=- |