cannam@85: dnl -*- m4 -*- cannam@85: dnl cannam@85: dnl libid3tag - ID3 tag manipulation library cannam@85: dnl Copyright (C) 2000-2004 Underbit Technologies, Inc. cannam@85: dnl cannam@85: dnl This program is free software; you can redistribute it and/or modify cannam@85: dnl it under the terms of the GNU General Public License as published by cannam@85: dnl the Free Software Foundation; either version 2 of the License, or cannam@85: dnl (at your option) any later version. cannam@85: dnl cannam@85: dnl This program is distributed in the hope that it will be useful, cannam@85: dnl but WITHOUT ANY WARRANTY; without even the implied warranty of cannam@85: dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the cannam@85: dnl GNU General Public License for more details. cannam@85: dnl cannam@85: dnl You should have received a copy of the GNU General Public License cannam@85: dnl along with this program; if not, write to the Free Software cannam@85: dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA cannam@85: dnl cannam@85: AC_REVISION([$Id: configure.ac,v 1.12 2004/01/23 23:22:46 rob Exp $])dnl cannam@85: cannam@85: dnl Process this file with autoconf to produce a configure script. cannam@85: cannam@85: AC_INIT([ID3 Tag], [0.15.1b], [support@underbit.com], [libid3tag]) cannam@85: AC_PREREQ(2.53) cannam@85: cannam@85: AC_CONFIG_SRCDIR([id3tag.h]) cannam@85: cannam@85: AM_INIT_AUTOMAKE cannam@85: cannam@85: AM_CONFIG_HEADER([config.h]) cannam@85: cannam@85: dnl System type. cannam@85: cannam@85: AC_CANONICAL_HOST cannam@85: cannam@85: dnl Checks for programs. cannam@85: cannam@85: AC_PROG_CC cannam@85: cannam@85: if test "$GCC" = yes cannam@85: then cannam@85: case "$host" in cannam@85: *-*-mingw*) cannam@85: case "$build" in cannam@85: *-*-cygwin*) cannam@85: CPPFLAGS="$CPPFLAGS -mno-cygwin" cannam@85: LDFLAGS="$LDFLAGS -mno-cygwin" cannam@85: ;; cannam@85: esac cannam@85: esac cannam@85: cannam@85: dnl case "$host" in cannam@85: dnl *-*-cygwin* | *-*-mingw*) cannam@85: dnl LDFLAGS="$LDFLAGS -no-undefined -mdll" cannam@85: dnl ;; cannam@85: dnl esac cannam@85: fi cannam@85: cannam@85: dnl Support for libtool. cannam@85: cannam@85: dnl AC_DISABLE_SHARED cannam@85: dnl AC_LIBTOOL_WIN32_DLL cannam@85: AC_PROG_LIBTOOL cannam@85: cannam@85: AC_SUBST(LIBTOOL_DEPS) cannam@85: cannam@85: dnl Compiler options. cannam@85: cannam@85: arch="" cannam@85: debug="" cannam@85: optimize="" cannam@85: profile="" cannam@85: cannam@85: set -- $CFLAGS cannam@85: CFLAGS="" cannam@85: cannam@85: if test "$GCC" = yes cannam@85: then cannam@85: CFLAGS="-Wall" cannam@85: fi cannam@85: cannam@85: while test $# -gt 0 cannam@85: do cannam@85: case "$1" in cannam@85: -Wall) cannam@85: if test "$GCC" = yes cannam@85: then cannam@85: : cannam@85: else cannam@85: CFLAGS="$CFLAGS $1" cannam@85: fi cannam@85: shift cannam@85: ;; cannam@85: -g) cannam@85: debug="-g" cannam@85: shift cannam@85: ;; cannam@85: -mno-cygwin) cannam@85: shift cannam@85: ;; cannam@85: -m*) cannam@85: arch="$arch $1" cannam@85: shift cannam@85: ;; cannam@85: -fomit-frame-pointer) cannam@85: shift cannam@85: ;; cannam@85: -O*|-f*) cannam@85: optimize="$1" cannam@85: shift cannam@85: ;; cannam@85: *) cannam@85: CFLAGS="$CFLAGS $1" cannam@85: shift cannam@85: ;; cannam@85: esac cannam@85: done cannam@85: cannam@85: dnl Checks for header files. cannam@85: cannam@85: AC_HEADER_STDC cannam@85: AC_CHECK_HEADERS(assert.h unistd.h) cannam@85: cannam@85: AC_CHECK_HEADER(zlib.h, [], [ cannam@85: AC_MSG_ERROR([zlib.h was not found cannam@85: *** You must first install zlib (libz) before you can build this package. cannam@85: *** If zlib is already installed, you may need to use the CPPFLAGS cannam@85: *** environment variable to specify its installed location, e.g. -I