build: Fix up some conditional code

Avahi and Ogg/Vorbis library conditional enablement wasn't working as
intended.
This commit is contained in:
Justin Maggard
2017-05-01 15:04:44 -07:00
parent cee5cfc04e
commit da7d868c4b
3 changed files with 38 additions and 25 deletions

View File

@@ -454,12 +454,11 @@ AC_CHECK_LIB(pthread, pthread_create)
# prior versions had ov_open_callbacks in libvorbis, test that, too.
AC_CHECK_LIB(vorbisfile, ov_open_callbacks,
[AC_CHECK_HEADERS([vorbis/vorbisfile.h],
AM_CONDITIONAL(HAVE_VORBISFILE, true)
AC_DEFINE(HAVE_VORBISFILE,1,[Have vorbisfile]),
AM_CONDITIONAL(HAVE_VORBISFILE, false)
AC_DEFINE(HAVE_VORBISFILE,0,[lacking vorbisfile]))],
AM_CONDITIONAL(HAVE_VORBISFILE, false),
-lvorbis -logg)
AM_CONDITIONAL(HAVE_VORBISFILE, true)
AC_DEFINE(HAVE_VORBISFILE,1,[Have vorbisfile]),
AM_CONDITIONAL(HAVE_VORBISFILE, false))],
AM_CONDITIONAL(HAVE_VORBISFILE, false),
-lvorbis -logg)
AC_CHECK_LIB(FLAC, FLAC__stream_decoder_init_stream,
[AC_CHECK_HEADERS([FLAC/all.h],
AM_CONDITIONAL(HAVE_FLAC, true)
@@ -548,11 +547,14 @@ AC_ARG_ENABLE(tivo,
[ --enable-tivo enable TiVo support],[
if test "$enableval" = "yes"; then
AC_DEFINE(TIVO_SUPPORT, 1, [Define to 1 if you want to enable TiVo support])
AM_CONDITIONAL(TIVO_SUPPORT, true)
AC_MSG_RESULT([yes])
else
AM_CONDITIONAL(TIVO_SUPPORT, false)
AC_MSG_RESULT([no])
fi
],[
AM_CONDITIONAL(TIVO_SUPPORT, false)
AC_MSG_RESULT([no])
]
)
@@ -588,13 +590,14 @@ AC_ARG_ENABLE(readynas,
AC_DEFINE_UNQUOTED([ROOTDEV_MANUFACTURER],"NETGEAR")
AC_DEFINE_UNQUOTED([ROOTDEV_MODELNAME],"Windows Media Connect compatible (ReadyDLNA)")
AC_DEFINE_UNQUOTED([ROOTDEV_MODELDESCRIPTION],"ReadyDLNA")
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
],[
AC_MSG_RESULT([no])
]
AM_CONDITIONAL(TIVO_SUPPORT, true)
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
],[
AC_MSG_RESULT([no])
]
)
AC_MSG_CHECKING([whether to build a static binary executable])