e16/configure.ac

414 lines
14 KiB
Plaintext
Raw Normal View History

2008-08-14 11:41:55 -07:00
m4_define([pkg_version], [0.16.8.15])
m4_define([pkg_revision], [001])
m4_define([pkg_version], m4_ifdef([pkg_revision], [pkg_version.pkg_revision], [pkg_version]))
m4_define([rpm_revision], m4_ifdef([pkg_revision], [0.`date '+%y%m%d'`], [1]))
2009-01-02 23:52:43 -08:00
AC_INIT(e16, [pkg_version], [enlightenment-devel@lists.sourceforge.net])
AM_INIT_AUTOMAKE([foreign])
AC_SUBST(E_RPM_REVISION, [rpm_revision])
# reasonable guesses for where stuff is installed
if test "x$prefix" = "xNONE"; then
prefix=$ac_default_prefix
fi
if test "x$exec_prefix" = "xNONE"; then
exec_prefix=$prefix
fi
AM_MAINTAINER_MODE
AC_PROG_CC
AM_PROG_CC_C_O
AC_PROG_MAKE_SET
AC_PROG_INSTALL
PKG_PROG_PKG_CONFIG
AC_HEADER_STDC
define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])dnl
define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl
define([AC_LIBTOOL_LANG_GCJ_CONFIG], [:])dnl
AC_ENABLE_SHARED
AC_DISABLE_STATIC
AC_LIBTOOL_DLOPEN
AC_PROG_LIBTOOL
AC_PATH_X
AC_PATH_XTRA
AC_CHECK_HEADERS(alloca.h locale.h stdarg.h wctype.h)
AC_TYPE_SIGNAL
AC_C_BIGENDIAN
2006-11-03 11:10:14 -08:00
AC_C_CONST
AC_C_INLINE
AC_C___ATTRIBUTE__
2004-12-28 15:46:49 -08:00
AC_CHECK_SIZEOF(int, 4)
AC_CHECK_SIZEOF(long, 4)
AC_CHECK_SIZEOF(wchar_t, 4)
AC_CHECK_FUNCS(snprintf)
AM_CONDITIONAL(USE_ESNPRINTF, test "x$ac_cv_func_snprintf" != "xyes")
AC_CHECK_FUNCS(strcasecmp strcasestr)
AC_CHECK_FUNCS(setenv unsetenv)
AC_CHECK_FUNCS(strdup strndup)
AC_CHECK_FUNCS(blumfrub)
AC_CHECK_FUNCS(buckets_of_erogenous_nym)
AC_CHECK_FUNCS(buttox)
2006-11-03 11:10:14 -08:00
AM_ICONV
AM_LANGINFO_CODESET
AM_GNU_GETTEXT([external])
AM_GNU_GETTEXT_VERSION([0.12.1])
AC_ARG_ENABLE(hints-gnome,
[ --enable-hints-gnome compile with GNOME(<2.0) hints support @<:@default=no@:>@],,
2004-12-28 15:46:49 -08:00
enable_hints_gnome=no)
2004-12-28 15:46:49 -08:00
if test "x$enable_hints_gnome" = "xyes"; then
AC_DEFINE(ENABLE_GNOME, 1, [GNOME(<2.0) Hints])
fi
AM_CONDITIONAL(ENABLE_GNOME, test "x$enable_hints_gnome" = "xyes")
AC_ARG_ENABLE(sound,
[ --enable-sound compile with sound support @<:@default=yes@:>@],,
enable_sound=yes)
if test "x$enable_sound" = "xyes"; then
AC_ARG_ENABLE(sound_pulse,
[ --enable-sound-pulse compile with PulseAudio sound support (experimental) @<:@default=no@:>@],,
enable_sound_pulse=no)
AC_ARG_ENABLE(sound_esound,
[ --enable-sound-esound compile with EsounD sound support @<:@default=yes@:>@],,
enable_sound_esound=yes)
fi
enable_sound=no
if test "x$enable_sound_pulse" = "xyes"; then
PKG_CHECK_MODULES(PA, libpulse,, enable_sound_pulse=no)
fi
if test "x$enable_sound_pulse" = "xyes"; then
AC_DEFINE(HAVE_SOUND, 1, [Sound support])
AC_DEFINE(HAVE_SOUND_PA, 1, [PulseAudio sound support])
AC_DEFINE(USE_SOUND_LOADER_AUDIOFILE, 1, [Use audiofile sound loader])
PKG_CHECK_MODULES(AUDIOFILE, audiofile,,)
enable_sound=pulseaudio
enable_sound_esound=no
PA_LIBS="$PA_LIBS $AUDIOFILE_LIBS"
fi
AM_CONDITIONAL(USE_LIBPA, test "x$enable_sound_pulse" = "xyes")
if test "x$enable_sound_esound" = "xyes"; then
AM_PATH_ESD(0.2.17,,[
enable_sound_esound=no
AC_MSG_WARN([EsounD sound support was requested but not found.])
])
AC_CHECK_HEADERS(audiofile.h,, enable_sound_esound=no)
fi
if test "x$enable_sound_esound" = "xyes"; then
AC_DEFINE(HAVE_SOUND, 1, [Sound support])
AC_DEFINE(HAVE_SOUND_ESD, 1, [EsounD sound support])
AC_DEFINE(USE_SOUND_LOADER_AUDIOFILE, 1, [Use audiofile sound loader])
enable_sound=esound
fi
AM_CONDITIONAL(USE_LIBESD, test "x$enable_sound_esound" = "xyes")
CPPFLAGS="$X_CFLAGS $CPPFLAGS"
LDFLAGS="$X_LIBS $LDFLAGS -L$prefix/lib"
PKG_CHECK_MODULES(IMLIB2, imlib2 >= 1.2.0, have_good_imlib2=yes)
AC_CHECK_LIB(Imlib2, imlib_context_set_mask_alpha_threshold,
AC_DEFINE(HAVE_IMLIB_CONTEXT_SET_MASK_ALPHA_THRESHOLD, 1,
[Imlib2 has imlib_context_set_mask_alpha_threshold]),,
2006-10-20 15:39:35 -07:00
$IMLIB2_LIBS)
AC_CHECK_LIB(Imlib2, imlib_context_disconnect_display,
AC_DEFINE(HAVE_IMLIB_CONTEXT_DISCONNECT_DISPLAY, 1,
[Imlib2 has imlib_context_disconnect_display]),,
$IMLIB2_LIBS)
2004-12-28 15:46:49 -08:00
AC_ARG_ENABLE(sm,
[ --enable-sm compile with session management support @<:@default=yes@:>@],,
enable_sm=yes)
if test "x$enable_sm" = "xyes"; then
AC_CHECK_HEADERS(X11/SM/SMlib.h,, enable_sm=no)
AC_CHECK_LIB(SM, SmcOpenConnection, SM_LIBS="-lSM -lICE", enable_sm=no)
AC_SUBST(SM_LIBS)
fi
if test "x$enable_sm" = "xyes"; then
AC_DEFINE(USE_SM, 1, [Session management support])
fi
AC_ARG_ENABLE(pango,
[ --enable-pango compile with pango-xft support @<:@default=no@:>@],,
enable_pango=no)
if test "x$enable_pango" = "xyes"; then
PKG_CHECK_MODULES(PANGO, pangoxft, AC_DEFINE(USE_PANGO, 1, [pango-xft support]), enable_pango=no)
fi
AM_CONDITIONAL(USE_LIBPANGO, test "x$enable_pango" = "xyes")
2006-10-22 07:09:50 -07:00
AC_ARG_ENABLE(xft,
[ --enable-xft compile with Xft support @<:@default=yes@:>@],,
enable_xft=yes)
if test "x$enable_xft" = "xyes"; then
PKG_CHECK_MODULES(XFT, xft, AC_DEFINE(USE_XFT, 1, [Xft support]), enable_xft=no)
fi
AM_CONDITIONAL(USE_LIBXFT, test "x$enable_xft" = "xyes")
2006-10-22 07:09:50 -07:00
2006-10-20 15:39:35 -07:00
AC_ARG_ENABLE(ecore,
[ --enable-ecore use ecore functions (for testing only - DO NOT USE!) @<:@default=no@:>@],,
enable_ecore=no)
if test "x$enable_ecore" = "xyes"; then
PKG_CHECK_MODULES(ECORE, ecore-x,
AC_DEFINE(USE_ECORE, 1, [Use libecore])
AC_DEFINE(USE_ECORE_X, 1, [Use libecore_x]),
enable_ecore=no)
2004-12-28 15:46:49 -08:00
fi
# Is this reasonably correct?
AC_ARG_ENABLE(glx,
[ --enable-glx compile with GLX support (experimental) @<:@default=no@:>@],,
enable_glx=no)
if test "x$enable_glx" = "xyes"; then
AC_CHECK_HEADERS(GL/gl.h GL/glu.h GL/glx.h, , AC_MSG_ERROR([Cannot find GLX headers]))
AC_CHECK_LIB(GL, glXCreateNewContext,
[
AC_DEFINE(USE_GLX, 1, [GLX support])
GLX_LIBS="-lGL -lGLU"
],[
AC_MSG_ERROR([Cannot find GLX libraries])
])
AC_CHECK_LIB(GL, glXBindTexImageEXT,
AC_DEFINE(HAVE_GLX_glXBindTexImageEXT, 1, [glXBindTexImageEXT is available]))
AC_SUBST(GLX_LIBS)
fi
AM_CONDITIONAL(ENABLE_GLX, test "x$enable_glx" = "xyes")
AC_CHECK_LIB(Xext, XShapeQueryExtension,
E_X_LIBS="-lXext $E_X_LIBS",
AC_MSG_ERROR([Shape support is required but was not found]),
-lX11)
AC_ARG_ENABLE(xinerama,
[ --enable-xinerama compile with xinerama support @<:@default=yes@:>@],,
enable_xinerama=yes)
if test "x$enable_xinerama" = "xyes"; then
AC_CHECK_LIB(Xinerama, XineramaQueryExtension,
AC_DEFINE(USE_XINERAMA, 1, [Xinerama support])
XINERAMA_LIBS="-lXinerama",
enable_xinerama=no
AC_MSG_WARN([Xinerama support was requested but not found]),
-lXext -lX11)
fi
AC_SUBST(XINERAMA_LIBS)
AC_ARG_ENABLE(zoom,
[ --enable-zoom compile with zoom support @<:@default=yes@:>@],,
2004-12-28 15:46:49 -08:00
enable_zoom=yes)
if test "x$enable_zoom" = "xyes"; then
2004-12-28 15:46:49 -08:00
AC_CHECK_LIB(Xxf86vm, XF86VidModeQueryExtension,
AC_DEFINE(WITH_ZOOM, 1, [Zoom Support])
E_X_LIBS="-lXxf86vm $E_X_LIBS",
enable_zoom=no
AC_MSG_WARN([Zoom support was requested but not found]),
-lXext -lX11)
fi
AC_ARG_ENABLE(xsync,
[ --enable-xsync compile with SYNC support @<:@default=yes@:>@],,
enable_xsync=yes)
if test "x$enable_xsync" = "xyes"; then
AC_CHECK_LIB(Xext, XSyncQueryExtension,
AC_DEFINE(USE_XSYNC, 1, [SYNC support]),
enable_xsync=no
AC_MSG_WARN([Sync support was requested but not found]),
-lX11)
fi
AC_ARG_ENABLE(xscrnsaver,
[ --enable-xscrnsaver compile with ScreenSaver support (experimental/not useful) @<:@default=no@:>@],,
enable_xscrnsaver=no)
if test "x$enable_xscrnsaver" = "xyes"; then
AC_CHECK_LIB(Xss, XScreenSaverQueryExtension,
AC_DEFINE(USE_XSCREENSAVER, 1, [ScreenSaver support])
E_X_LIBS="-lXss $E_X_LIBS",
enable_xscrnsaver=no
AC_MSG_WARN([ScreenSaver support was requested but not found]),
-lXext -lX11)
fi
AC_ARG_ENABLE(xrandr,
[ --enable-xrandr compile with RandR support @<:@default=yes@:>@],,
enable_xrandr=yes)
if test "x$enable_xrandr" = "xyes"; then
AC_CHECK_LIB(Xrandr, XRRQueryExtension,
AC_DEFINE(USE_XRANDR, 1, [RandR support])
E_X_LIBS="-lXrandr -lXrender $E_X_LIBS",
enable_xrandr=no
AC_MSG_WARN([RandR support was requested but not found]),
-lXrender -lXext -lX11)
2004-12-28 15:46:49 -08:00
AC_CHECK_HEADERS(X11/extensions/Xrandr.h,,,[#include <X11/Xlib.h>])
fi
# FIXME - Do this properly
AC_ARG_ENABLE(composite,
[ --enable-composite compile with Composite support @<:@default=yes@:>@],,
2004-12-28 15:46:49 -08:00
enable_composite=yes)
if test "x$enable_composite" = "xyes"; then
AC_CHECK_LIB(Xcomposite, XCompositeQueryExtension,
AC_DEFINE(USE_COMPOSITE, 1, [Composite support])
E_X_LIBS="-lXcomposite -lXdamage -lXfixes -lXrender $E_X_LIBS",
enable_composite=no,
-lXext -lX11)
AC_CHECK_HEADERS(X11/extensions/Xcomposite.h ,, enable_composite=no, [#include <X11/Xlib.h>])
AC_CHECK_HEADERS(X11/extensions/Xdamage.h ,, enable_composite=no, [#include <X11/Xlib.h>])
AC_CHECK_HEADERS(X11/extensions/Xfixes.h ,, enable_composite=no, [#include <X11/Xlib.h>])
AC_CHECK_HEADERS(X11/extensions/Xrender.h ,, enable_composite=no, [#include <X11/Xlib.h>])
if test "x$enable_composite" != "xyes"; then
AC_MSG_WARN([Composite support was requested but required component was not found])
fi
fi
AM_CONDITIONAL(ENABLE_COMPOSITE, test "x$enable_composite" = "xyes")
AC_ARG_ENABLE(dbus,
[ --enable-dbus compile with D-Bus support (experimental) @<:@default=no@:>@],,
enable_dbus=no)
if test "x$enable_dbus" = "xyes"; then
PKG_CHECK_MODULES(DBUS, dbus-1, AC_DEFINE(USE_DBUS, 1, [dbus support]), enable_dbus=no)
fi
AM_CONDITIONAL(ENABLE_DBUS, test "x$enable_dbus" = "xyes")
AC_CHECK_LIB(Fridge,mass_quantities_of_bass_ale)
2004-12-28 15:46:49 -08:00
AC_CHECK_LIB(Fridge,mass_quantities_of_any_ale,, [
echo "Warning: No ales were found in your refrigerator."
echo " We highly suggest that you rectify this situation immediately."
])
AC_ARG_ENABLE(roothacklib,
[ --enable-roothacklib build window mode helper library @<:@default=yes@:>@],,
2008-03-01 08:38:05 -08:00
enable_roothacklib=yes)
if test "x$enable_roothacklib" = "xyes"; then
AC_CHECK_LIB(dl, dlopen, DLOPEN_LIBS=-ldl, enable_roothacklib=no)
AC_SUBST(DLOPEN_LIBS)
fi
if test "x$enable_roothacklib" = "xyes"; then
AC_DEFINE(USE_ROOTHACKLIB, 1, [Use window mode helper library])
fi
AM_CONDITIONAL(BUILD_ROOTHACKLIB, test "x$enable_roothacklib" = "xyes")
AC_ARG_ENABLE(modules,
[ --enable-modules enable support for loadable modules @<:@default=no@:>@],,
2008-03-01 08:38:05 -08:00
enable_modules=no)
if test "x$enable_modules" = "xyes"; then
AC_CHECK_LIB(dl, dlopen, DLOPEN_LIBS=-ldl, enable_modules=no)
AC_SUBST(DLOPEN_LIBS)
fi
if test "x$enable_modules" = "xyes"; then
AC_DEFINE(USE_MODULES, 1, [Loadable module support])
fi
AM_CONDITIONAL(BUILD_MODULES, test "x$enable_modules" = "xyes")
dnl Set default visibility to hidden (only useful with --enable-modules)
AC_ARG_ENABLE(visibility-hiding,
[ --enable-visibility-hiding enable visibility hiding @<:@default=no@:>@],,
enable_visibility_hiding=no
)
if test "x$enable_visibility_hiding" = xyes ; then
CPPFLAGS="$CPPFLAGS -fvisibility=hidden"
fi
AC_ARG_ENABLE(gcc-cpp,
[ --enable-gcc-cpp compile everything as if it were C++ @<:@default=no@:>@],,
2008-03-01 08:38:05 -08:00
enable_gcc_cpp=no)
if test "x$enable_gcc_cpp" = "xyes"; then
CC="g++"
CPPFLAGS="$CPPFLAGS -x c++"
AC_C_WARNFLAGS([cpp])
else
AC_C_WARNFLAGS()
fi
AC_DEFINE(_GNU_SOURCE, 1, [Enable extensions])
AC_DEFINE(USE_EXT_INIT_WIN, 1, [Use external init window during restart])
AC_DEFINE(ENABLE_DESKRAY, 0, [Enable deskrays (not functional)])
AC_DEFINE(ENABLE_TRANSPARENCY, 1, [Enable pseudotransparency])
AC_DEFINE(ENABLE_THEME_TRANSPARENCY, 1, [Enable adjusting theme element pseudotransparency])
AC_SUBST(E_X_LIBS)
AM_CONFIG_HEADER(config.h)
AC_OUTPUT([
Makefile
src/Makefile
dox/Makefile
dox/E-docs/Makefile
eesh/Makefile
epp/Makefile
lib/Makefile
man/Makefile
config/Makefile
config/pix/Makefile
2004-05-11 17:06:26 -07:00
themes/Makefile
fonts/Makefile
scripts/Makefile
misc/Makefile
po/Makefile.in
e16.spec
1999-10-21 06:17:09 -07:00
])
if test "x$have_good_imlib2" != "xyes"; then
echo "***************************************************************"
echo "*** WARNING: imlib2 >= 1.2.0 was not detected ***"
echo "*** WARNING: If you indeed do not have this, expect trouble ***"
echo "***************************************************************"
fi
echo
echo "------------------------------------------------------------------------"
echo "$PACKAGE Version $VERSION"
echo "------------------------------------------------------------------------"
echo
echo "Configuration summary"
echo
echo "Support for"
echo " Localisation ................. $USE_NLS"
echo " Sound ........................ $enable_sound"
echo " Old GNOME hints .............. $enable_hints_gnome"
echo " Session management ........... $enable_sm"
echo " Zoom ......................... $enable_zoom"
echo " Pango ........................ $enable_pango"
2006-10-22 07:09:50 -07:00
echo " Xft .......................... $enable_xft"
echo " Xinerama ..................... $enable_xinerama"
echo " RandR ........................ $enable_xrandr"
echo " Sync ......................... $enable_xsync"
echo " Composite .................... $enable_composite"
echo " Modules ...................... $enable_modules"
echo " Visibility hiding ............ $enable_visibility_hiding (only useful with modules)"
echo " Window mode helper library ... $enable_roothacklib"
echo
echo "Experimental options - DO NOT USE unless you know what you are doing"
echo " Compile with ecore/ecore_x ... $enable_ecore"
echo " GLX .......................... $enable_glx"
echo " ScreenSaver .................. $enable_xscrnsaver"
echo " D-Bus ........................ $enable_dbus"
echo
2006-12-24 02:21:52 -08:00
echo "Installation path .............. $prefix"
echo
echo "Compilation .................... make"
echo "Installation ................... make install"
echo
echo "***************************************************************"
echo "*** NOTE: If this is your first trip with version 0.16.8 ***"
echo "*** NOTE: you may want to take a look in docs/README-0.16.8 ***"
echo "***************************************************************"