annotate configure.ac @ 17:3cbd40805795 tip

Remove obsolete stuff from README
author Chris Cannam
date Tue, 03 Dec 2013 16:33:08 +0000
parents df33703ace3b
children
rev   line source
Chris@15 1
Chris@15 2 AC_INIT([vamp-live-host], [0.1], cannam@all-day-breakfast.com)
Chris@15 3
Chris@15 4 AC_CONFIG_SRCDIR(host/host.cpp)
Chris@15 5
Chris@15 6 # Autoconf will set CXXFLAGS; we don't usually want it to, because we
Chris@15 7 # either define our own flags (at least if GCC is in use) or else use
Chris@15 8 # the user's preferences. We need to ensure CXXFLAGS is only set if
Chris@15 9 # the user has expressly set it. So, save the user's (or empty)
Chris@15 10 # setting now and restore it after Autoconf has done its bit of
Chris@15 11 # piddling about.
Chris@15 12 USER_CXXFLAGS="$CXXFLAGS"
Chris@15 13
Chris@15 14 # If the user supplied CFLAGS but not CXXFLAGS, use CFLAGS instead
Chris@15 15 if test x"$USER_CXXFLAGS" = x; then
Chris@15 16 if test x"$CFLAGS" != x; then
Chris@15 17 USER_CXXFLAGS="$CFLAGS"
Chris@15 18 fi
Chris@15 19 fi
Chris@15 20
Chris@15 21 AC_LANG_CPLUSPLUS
Chris@15 22
Chris@15 23 AC_PROG_CC
Chris@15 24 AC_PROG_CXX
Chris@15 25 AC_PROG_INSTALL
Chris@15 26 AC_PROG_MKDIR_P
Chris@15 27
Chris@15 28 AC_HEADER_STDC
Chris@15 29
Chris@15 30 # These are the flags Autoconf guesses for us; we use them later if
Chris@15 31 # the user has set none and we are not using GCC (so lack our own
Chris@15 32 # preferred flags)
Chris@15 33 AUTOCONF_CXXFLAGS="$CXXFLAGS"
Chris@15 34
Chris@15 35 PKG_PROG_PKG_CONFIG
Chris@15 36
Chris@15 37 SV_CHECK_QT
Chris@15 38
Chris@15 39 SV_DEFINES_DEBUG="-DDEBUG -DBUILD_DEBUG -DWANT_TIMING"
Chris@15 40 SV_DEFINES_RELEASE="-DNDEBUG -DBUILD_RELEASE -DNO_TIMING"
Chris@15 41 SV_DEFINES_MINIMAL="$SV_DEFINES_RELEASE"
Chris@15 42
Chris@15 43 # Now we have: USER_CXXFLAGS contains any flags the user set
Chris@15 44 # explicitly; AUTOCONF_CXXFLAGS contains flags that Autoconf thought
Chris@15 45 # we should use. If we have GCC, we override the latter but then
Chris@15 46 # allow ourselves to be overridden (later) by the former
Chris@15 47
Chris@15 48 CXXFLAGS_DEBUG="$AUTOCONF_CXXFLAGS"
Chris@15 49 CXXFLAGS_RELEASE="$AUTOCONF_CXXFLAGS"
Chris@15 50 CXXFLAGS_MINIMAL="$AUTOCONF_CXXFLAGS"
Chris@15 51
Chris@15 52 if test "x$GCC" = "xyes"; then
Chris@15 53 CXXFLAGS_DEBUG="-Wall -Woverloaded-virtual -Wextra -Wformat-nonliteral -Wformat-security -Winit-self -Wswitch-enum -g -pipe"
Chris@15 54 CXXFLAGS_RELEASE="-g0 -O2 -Wall -pipe"
Chris@15 55 CXXFLAGS_MINIMAL="-g0 -O0"
Chris@15 56 fi
Chris@15 57
Chris@15 58 CXXFLAGS_BUILD="$CXXFLAGS_RELEASE"
Chris@15 59 SV_DEFINES_BUILD="$SV_DEFINES_RELEASE"
Chris@15 60
Chris@15 61 QMAKE_CONFIG="release"
Chris@15 62
Chris@15 63 AC_ARG_ENABLE(debug, [AS_HELP_STRING([--enable-debug],[enable debug support [default=no]])],[AC_MSG_NOTICE([enabling debug build])
Chris@15 64 QMAKE_CONFIG="debug"
Chris@15 65 CXXFLAGS_BUILD="$CXXFLAGS_DEBUG"
Chris@15 66 SV_DEFINES_BUILD="$SV_DEFINES_DEBUG"])
Chris@15 67
Chris@15 68 if test x"$USER_CXXFLAGS" != x; then
Chris@15 69 AC_MSG_NOTICE([The CXXFLAGS environment variable is set to "$USER_CXXFLAGS".])
Chris@15 70 AC_MSG_NOTICE(Overriding default compiler flags with the above user setting.)
Chris@15 71 CXXFLAGS_BUILD="$USER_CXXFLAGS"
Chris@15 72 CXXFLAGS_MINIMAL="$USER_CXXFLAGS"
Chris@15 73 fi
Chris@15 74
Chris@15 75 CXXFLAGS="$CXXFLAGS_BUILD $SV_DEFINES_BUILD"
Chris@15 76
Chris@15 77 SV_MODULE_REQUIRED([bz2],[],[bzlib.h],[bz2],[BZ2_bzReadOpen])
Chris@15 78 SV_MODULE_REQUIRED([fftw3],[fftw3 >= 3.0.0],[fftw3.h],[fftw3],[fftw_execute])
Chris@15 79 SV_MODULE_REQUIRED([fftw3f],[fftw3f >= 3.0.0],[fftw3.h],[fftw3f],[fftwf_execute])
Chris@15 80 SV_MODULE_REQUIRED([sndfile],[sndfile >= 1.0.16],[sndfile.h],[sndfile],[sf_open])
Chris@15 81 SV_MODULE_REQUIRED([samplerate],[samplerate >= 0.1.2],[samplerate.h],[samplerate],[src_new])
Chris@15 82 SV_MODULE_REQUIRED([vamp],[vamp >= 2.1],[vamp/vamp.h],[],[])
Chris@15 83 SV_MODULE_REQUIRED([vamphostsdk],[vamp-hostsdk >= 2.5],[vamp-hostsdk/PluginLoader.h],[vamp-hostsdk],[libvamphostsdk_v_2_5_present])
Chris@15 84 SV_MODULE_REQUIRED([sord],[sord-0 >= 0.5],[sord/sord.h],[sord-0],[sord_world_new])
Chris@15 85 SV_MODULE_REQUIRED([serd],[serd-0 >= 0.5],[serd/serd.h],[serd-0],[serd_reader_read_file])
Chris@15 86
Chris@15 87 SV_MODULE_OPTIONAL([liblo],[],[lo/lo.h],[lo],[lo_address_new])
Chris@15 88 SV_MODULE_OPTIONAL([portaudio_2_0],[portaudio-2.0 >= 19],[portaudio.h],[portaudio],[Pa_IsFormatSupported])
Chris@15 89 SV_MODULE_OPTIONAL([JACK],[jack >= 0.100],[jack/jack.h],[jack],[jack_client_open])
Chris@15 90 SV_MODULE_OPTIONAL([libpulse],[libpulse >= 0.9],[pulse/pulseaudio.h],[pulse],[pa_stream_new])
Chris@15 91 SV_MODULE_OPTIONAL([lrdf],[lrdf >= 0.2],[lrdf.h],[lrdf],[lrdf_init])
Chris@15 92 SV_MODULE_OPTIONAL([oggz],[oggz >= 1.0.0],[oggz/oggz.h],[oggz],[oggz_run])
Chris@15 93 SV_MODULE_OPTIONAL([fishsound],[fishsound >= 1.0.0],[fishsound/fishsound.h],[fishsound],[fish_sound_new])
Chris@15 94 SV_MODULE_OPTIONAL([mad],[mad >= 0.15.0],[mad.h],[mad],[mad_decoder_init])
Chris@15 95 SV_MODULE_OPTIONAL([id3tag],[id3tag >= 0.15.0],[id3tag.h],[id3tag],[id3_tag_new])
Chris@15 96
Chris@15 97 AC_SUBST(PERL)
Chris@15 98 AC_SUBST(XARGS)
Chris@15 99 AC_SUBST(MAKEDEPEND)
Chris@15 100 AC_SUBST(SHA1SUM)
Chris@15 101 AC_SUBST(CUT)
Chris@15 102
Chris@15 103 AC_SUBST(CFLAGS)
Chris@15 104 AC_SUBST(CXXFLAGS)
Chris@15 105 AC_SUBST(CXXFLAGS_MINIMAL)
Chris@15 106 AC_SUBST(LDFLAGS)
Chris@15 107 AC_SUBST(HAVES)
Chris@15 108 AC_SUBST(LIBS)
Chris@15 109
Chris@15 110 AC_SUBST(CC)
Chris@15 111 AC_SUBST(CXX)
Chris@15 112
Chris@15 113 AC_SUBST(QMAKE_CONFIG)
Chris@15 114
Chris@15 115 AC_CONFIG_SUBDIRS([svcore])
Chris@15 116 AC_CONFIG_FILES([config.pri version.h])
Chris@15 117
Chris@15 118 AC_OUTPUT
Chris@15 119
Chris@15 120 if ! $QMAKE -r vamp-live-host.pro; then
Chris@15 121 AC_MSG_ERROR([qmake failed: Command was "$QMAKE -r"])
Chris@15 122 fi
Chris@15 123
Chris@15 124 AC_MSG_NOTICE([
Chris@15 125
Chris@15 126 Configuration complete.
Chris@15 127 Please check the above messages for any warnings that you
Chris@15 128 might care about, and then run "make".
Chris@15 129
Chris@15 130 The file config.pri contains the configuration settings for
Chris@15 131 qmake. If you want to adjust these by hand, edit config.pri
Chris@15 132 and run "qmake -r" again to regenerate the Makefile.
Chris@15 133 ])