Search for an header file in different paths

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have this configure.ac file:

AC_PREREQ([2.67])
AC_INIT([myapp], [0.2], [candini@xxxxxxx])
AM_INIT_AUTOMAKE([-Wall -Werror foreign])
LT_PREREQ([2.2])
LT_INIT([dlopen])
AC_CONFIG_SRCDIR([src/ESM.cpp])
AC_CONFIG_HEADERS([config.h])
AC_DEFINE([ESM_VERSION], ["1.3.2"], [Soil Mapper version])
AC_DEFINE([_EXP], [], [Soil Mapper expiring date macro])
AC_PROG_CXX
AC_CHECK_PROG([bash_shell],[bash -x],[bash -x],,,[/usr/sbin/bash])
AC_PROG_INSTALL
AC_PROG_CXX_C_O
AC_SEARCH_LIBS([pthread_create, pthread_join], [pthread])
AC_SEARCH_LIBS([GDALOpen], [gdal])
PKG_CHECK_MODULES([ESM_GUI], [glibmm-2.4 giomm-2.4 gtkmm-2.4 >= 2.12.2 gtk+-2.0 cairo gthread-2.0 >= 2.0]) AC_CHECK_HEADERS([stdlib.h string.h unistd.h pthread.h gdal.h ogr_srs_api.h])
AC_HEADER_STDBOOL
AC_FUNC_MALLOC
AC_FUNC_MKTIME
AC_FUNC_REALLOC
AC_CONFIG_FILES([Makefile
         src/Makefile])
AC_OUTPUT

Before upgrading my Ubuntu linux to 11.10 version, I had gdal.h under /usr/local/include: configure and make succeed without errors. Now I have it under /usr/include/gdal and I get that gdal.h cannot be found (in my source files there is a simple "#include <gdal.h>").

How can I manage the two cases in the same configure.ac: system in which gdal.h is in /usr/include and others in which it is in /usr/local/include?

Thanks in advance,

Caneta


_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
https://lists.gnu.org/mailman/listinfo/autoconf


[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux