~ubuntu-branches/ubuntu/precise/flac/precise-updates

« back to all changes in this revision

Viewing changes to src/libFLAC++/libFLAC++.m4

  • Committer: Bazaar Package Importer
  • Author(s): Joshua Kwan
  • Date: 2007-05-29 22:56:36 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070529225636-ljeff8xxip09qaap
Tags: 1.1.4-1
* New upstream release. closes: #405167, #411311
  - libOggFLAC and libOggFLAC++ have been merged into libFLAC, so
    remove their corresponding packages.
  - Because of the API changes required to effect the above, there has
    been yet another soname bump. libflac7 -> libflac8 and
    libflac++5 -> libflac++6. Emails have been dispatched to the
    maintainers of dependent packages.
* Some notes on patches that were removed:
  - 02_stdin_stdout, 06_manpage_mention_utf8_convert: merged upstream
  - 08_manpage_warnings: Upstream has changed the manpage so it defintely
    can't fit in in 80 cols, so just forget about it. We'll live.
  - 05_eof_warnings_are_errors: Upstream decided to add a -w option to
    flac to treat all warnings as errors. I am going to defer to that
    for now, but if people think it's stupid let me know and I'll port
    the patch forward.
  - 04_stack_smasher: was a backport from 1.1.3, so it's obsolete.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
# Caller must first run AM_PATH_LIBFLAC
4
4
 
5
5
dnl AM_PATH_LIBFLACPP([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
6
 
dnl Test for libFLAC++, and define LIBFLACPP_CFLAGS and LIBFLACPP_LIBS
 
6
dnl Test for libFLAC++, and define LIBFLACPP_CFLAGS, LIBFLACPP_LIBS, LIBFLACPP_LIBDIR
7
7
dnl
8
8
AC_DEFUN([AM_PATH_LIBFLACPP],
9
9
[dnl 
15
15
AC_ARG_ENABLE(libFLACPPtest, [  --disable-libFLACPPtest       Do not try to compile and run a test libFLAC++ program],, enable_libFLACPPtest=yes)
16
16
 
17
17
  if test "x$libFLACPP_libraries" != "x" ; then
18
 
    LIBFLACPP_LIBS="-L$libFLACPP_libraries"
 
18
    LIBFLACPP_LIBDIR="$libFLACPP_libraries"
19
19
  elif test "x$libFLACPP_prefix" != "x" ; then
20
 
    LIBFLACPP_LIBS="-L$libFLACPP_prefix/lib"
 
20
    LIBFLACPP_LIBDIR="$libFLACPP_prefix/lib"
21
21
  elif test "x$prefix" != "xNONE" ; then
22
 
    LIBFLACPP_LIBS="-L$libdir"
 
22
    LIBFLACPP_LIBDIR="$libdir"
23
23
  fi
24
24
 
25
 
  LIBFLACPP_LIBS="$LIBFLACPP_LIBS -lFLAC++ $LIBFLAC_LIBS"
 
25
  LIBFLACPP_LIBS="-L$LIBFLACPP_LIBDIR -lFLAC++ $LIBFLAC_LIBS"
26
26
 
27
27
  if test "x$libFLACPP_includes" != "x" ; then
28
28
    LIBFLACPP_CFLAGS="-I$libFLACPP_includes"
29
29
  elif test "x$libFLACPP_prefix" != "x" ; then
30
30
    LIBFLACPP_CFLAGS="-I$libFLACPP_prefix/include"
31
31
  elif test "$prefix" != "xNONE"; then
32
 
    LIBFLACPP_CFLAGS="-I$prefix/include"
 
32
    LIBFLACPP_CFLAGS=""
33
33
  fi
34
34
 
35
35
  LIBFLACPP_CFLAGS="$LIBFLACPP_CFLAGS $LIBFLAC_CFLAGS"
42
42
    ac_save_CFLAGS="$CFLAGS"
43
43
    ac_save_CXXFLAGS="$CXXFLAGS"
44
44
    ac_save_LIBS="$LIBS"
 
45
    ac_save_LDPATH="$LD_LIBRARY_PATH"
45
46
    CFLAGS="$CFLAGS $LIBFLACPP_CFLAGS"
46
47
    CXXFLAGS="$CXXFLAGS $LIBFLACPP_CFLAGS"
47
48
    LIBS="$LIBS $LIBFLACPP_LIBS"
 
49
    LD_LIBRARY_PATH="$LIBFLACPP_LIBDIR:$LIBFLAC_LIBDIR:$LD_LIBRARY_PATH"
48
50
dnl
49
51
dnl Now check if the installed libFLAC++ is sufficiently new.
50
52
dnl
63
65
 
64
66
],, no_libFLACPP=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
65
67
       CFLAGS="$ac_save_CFLAGS"
 
68
       CXXFLAGS="$ac_save_CXXFLAGS"
66
69
       LIBS="$ac_save_LIBS"
 
70
       LD_LIBRARY_PATH="$ac_save_LD_LIBRARY_PATH"
67
71
  fi
68
72
 
69
73
  if test "x$no_libFLACPP" = "x" ; then
76
80
     else
77
81
       echo "*** Could not run libFLAC++ test program, checking why..."
78
82
       CFLAGS="$CFLAGS $LIBFLACPP_CFLAGS"
 
83
       CXXFLAGS="$CXXFLAGS $LIBFLACPP_CFLAGS"
79
84
       LIBS="$LIBS $LIBFLACPP_LIBS"
 
85
       LD_LIBRARY_PATH="$LIBFLACPP_LIBDIR:$LIBFLAC_LIBDIR:$LD_LIBRARY_PATH"
80
86
       AC_TRY_LINK([
81
87
#include <stdio.h>
82
88
#include <FLAC++/decoder.h>
95
101
       echo "*** or that you have moved libFLAC++ since it was installed. In the latter case, you"
96
102
       echo "*** may want to edit the libFLAC++-config script: $LIBFLACPP_CONFIG" ])
97
103
       CFLAGS="$ac_save_CFLAGS"
 
104
       CXXFLAGS="$ac_save_CXXFLAGS"
98
105
       LIBS="$ac_save_LIBS"
 
106
       LD_LIBRARY_PATH="$ac_save_LD_LIBRARY_PATH"
99
107
     fi
100
108
     LIBFLACPP_CFLAGS=""
 
109
     LIBFLACPP_LIBDIR=""
101
110
     LIBFLACPP_LIBS=""
102
111
     ifelse([$2], , :, [$2])
103
112
  fi
104
113
  AC_SUBST(LIBFLACPP_CFLAGS)
 
114
  AC_SUBST(LIBFLACPP_LIBDIR)
105
115
  AC_SUBST(LIBFLACPP_LIBS)
106
116
  rm -f conf.libFLAC++test
107
117
])