# configure.in for GNUstep GUI library # Process this file with autoconf to produce a configure script. # # Copyright (C) 1996 Free Software Foundation, Inc. # # Author: Adam Fedor # # This file is part of the GNUstep GUI frontend (AppKit). # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Library General Public # License as published by the Free Software Foundation; either # version 2 of the License, or (at your option) any later version. # # This library is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # Library General Public License for more details. # # You should have received a copy of the GNU Library General Public # License along with this library; see the file COPYING.LIB. # If not, write to the Free Software Foundation, # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # AC_INIT(Source/NSApplication.m) AC_CONFIG_HEADER(Headers/gnustep/gui/config.h) #-------------------------------------------------------------------- # Determine the host, build, and target systems #-------------------------------------------------------------------- AC_CANONICAL_SYSTEM AC_CHECK_LIB(m, main) AC_CHECK_FUNCS(rintf) #-------------------------------------------------------------------- # Find for TIFF # Do a superficial find only - The tiff library is actually linked with # the backend, and typically in conjunction with other graphic libraries. #-------------------------------------------------------------------- AC_ARG_WITH(tiff_library, [ --with-tiff-library=DIR TIFF library file are in DIR], , with_tiff_library=) AC_ARG_WITH(tiff_include, [ --with-tiff-include=DIR TIFF include files are in DIR], , with_tiff_include=) case "$target_os" in freebsd*) CPPFLAGS="$CPPFLAGS -I/usr/local/include" LDFLAGS="$LDFLAGS -L/usr/local/lib" ADDITIONAL_INCLUDE_DIRS="-I/usr/local/include" ADDITIONAL_LIB_DIRS="-L/usr/local/lib";; esac save_cpp=${CPPFLAGS} save_ldf=${LDFLAGS} if test "$with_tiff_include" != ""; then CPPFLAGS="-I$with_tiff_include ${CPPFLAGS}" ADDITIONAL_INCLUDE_DIRS="-I$with_tiff_include" fi if test -n "$with_tiff_library"; then LDFLAGS="-L$with_tiff_library $LDFLAGS" ADDITIONAL_LIB_DIRS="-L$with_tiff_library" fi AC_CHECK_HEADER(tiffio.h) if test $ac_cv_header_tiffio_h = no; then AC_MSG_WARN(Cannot find libtiff header tiffio) echo "* The GUI library requres the TIFF library" echo "* Use --with-tiff-include to specify the tiff header directory" echo "* and --with-tiff-library to specify the tiff library directory" echo "* if it is not in the usual place(s)" AC_MSG_ERROR(gnustep-gui will not compile without tiff includes) fi AC_CHECK_LIB(tiff, main) CPPFLAGS="$save_cpp" LDFLAGS="$save_ldf" #-------------------------------------------------------------------- # Record the version #-------------------------------------------------------------------- AC_MSG_CHECKING(for the version of gnustep-gui we are compiling) if test -f "Version"; then . ./Version fi AC_MSG_RESULT($GNUSTEP_GUI_VERSION) AC_SUBST(GNUSTEP_GUI_VERSION) AC_SUBST(GNUSTEP_GUI_MAJOR_VERSION) AC_SUBST(GNUSTEP_GUI_MINOR_VERSION) AC_SUBST(GNUSTEP_GUI_SUBMINOR_VERSION) AC_SUBST(ADDITIONAL_LIB_DIRS) AC_SUBST(ADDITIONAL_INCLUDE_DIRS) AC_OUTPUT(config.make gui.make Headers/gnustep/gui/GSVersion.h)