X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=configure.ac;h=09bd04e51f80711f1fe1bbff003b230ae46bf7ee;hb=1dd334419cb02225fc6c1372d46d08c68c474d6c;hp=8f10bcd850221e0539fd8c278db4f26cf4f7c503;hpb=59e07c7ecca7919dd312f5d0119564b79626807b;p=framework%2Fuifw%2Fembryo.git diff --git a/configure.ac b/configure.ac index 8f10bcd..09bd04e 100644 --- a/configure.ac +++ b/configure.ac @@ -1,38 +1,75 @@ -# get rid of that stupid cache mechanism -rm -f config.cache - -AC_INIT([embryo], [0.9.9.050], [enlightenment-devel@lists.sourceforge.net]) +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +m4_define([v_maj], [1]) +m4_define([v_min], [2]) +m4_define([v_mic], [0]) +m4_define([v_rev], m4_esyscmd([(svnversion "${SVN_REPO_PATH:-.}" | grep -v '\(export\|Unversioned directory\)' || echo 0) | awk -F : '{printf("%s\n", $1);}' | tr -d ' :MSP\n'])) +m4_if(v_rev, [0], [m4_define([v_rev], m4_esyscmd([git log 2> /dev/null | (grep -m1 git-svn-id || echo 0) | sed -e 's/.*@\([0-9]*\).*/\1/' | tr -d '\n']))]) +##-- When released, remove the dnl on the below line +m4_undefine([v_rev]) +##-- When doing snapshots - change soname. remove dnl on below line +dnl m4_define([relname], [ver-pre-svn-07]) +dnl m4_define([v_rel], [-release ver-pre-svn-07]) +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +m4_ifdef([v_rev], [m4_define([v_ver], [v_maj.v_min.v_mic.v_rev])], [m4_define([v_ver], [v_maj.v_min.v_mic])]) +m4_define([lt_cur], m4_eval(v_maj + v_min)) +m4_define([lt_rev], v_mic) +m4_define([lt_age], v_min) +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## + +AC_INIT([embryo], [v_ver]-alpha, [enlightenment-devel@lists.sourceforge.net]) AC_PREREQ([2.52]) AC_CONFIG_SRCDIR([configure.ac]) AC_CONFIG_MACRO_DIR([m4]) -AC_CANONICAL_BUILD -AC_CANONICAL_HOST -AC_ISC_POSIX -AM_INIT_AUTOMAKE(1.6 dist-bzip2) -AM_CONFIG_HEADER(config.h) +AC_CONFIG_HEADERS([config.h]) +AH_TOP([ +#ifndef EFL_CONFIG_H__ +#define EFL_CONFIG_H__ +]) +AH_BOTTOM([ +#endif /* EFL_CONFIG_H__ */ +]) + +AM_INIT_AUTOMAKE([1.6 dist-bzip2]) +m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) AC_LIBTOOL_WIN32_DLL define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])dnl define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl AC_PROG_LIBTOOL -VMAJ=`echo $PACKAGE_VERSION | awk -F. '{printf("%s", $1);}'` -VMIN=`echo $PACKAGE_VERSION | awk -F. '{printf("%s", $2);}'` -VMIC=`echo $PACKAGE_VERSION | awk -F. '{printf("%s", $3);}'` -SNAP=`echo $PACKAGE_VERSION | awk -F. '{printf("%s", $4);}'` -version_info=`expr $VMAJ + $VMIN`":$VMIC:$VMIN" +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +m4_ifdef([v_rev], , [m4_define([v_rev], [0])]) +m4_ifdef([v_rel], , [m4_define([v_rel], [])]) +AC_DEFINE_UNQUOTED(VMAJ, [v_maj], [Major version]) +AC_DEFINE_UNQUOTED(VMIN, [v_min], [Minor version]) +AC_DEFINE_UNQUOTED(VMIC, [v_mic], [Micro version]) +AC_DEFINE_UNQUOTED(VREV, [v_rev], [Revison]) +version_info="lt_cur:lt_rev:lt_age" +release_info="v_rel" AC_SUBST(version_info) - +AC_SUBST(release_info) +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--##--## +VMAJ=v_maj +AC_SUBST(VMAJ) ### Default options with respect to host +AC_CANONICAL_BUILD +AC_CANONICAL_HOST + requirement_embryo="" embryoincludedir="${datadir}/include" ### Additional options to configure +EFL_ENABLE_BIN([embryo-cc]) + ### Checks for programs AC_PROG_CC @@ -41,17 +78,27 @@ AC_PROG_CC EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"]) - -### Checks for libraries +# pkg-config PKG_PROG_PKG_CONFIG +# Check whether pkg-config supports Requires.private +if $PKG_CONFIG --atleast-pkgconfig-version 0.22; then + pkgconfig_requires_private="Requires.private" +else + pkgconfig_requires_private="Requires" +fi +AC_SUBST(pkgconfig_requires_private) + + +### Checks for libraries + # Evil library for compilation on Windows EFL_EMBRYO_BUILD="" case "$host_os" in - mingw* | cegcc*) - PKG_CHECK_MODULES([EVIL], [evil]) + mingw*) + PKG_CHECK_MODULES([EVIL], [evil >= 1.0.0]) AC_DEFINE(HAVE_EVIL, 1, [Set to 1 if Evil library is installed]) requirement_embryo="evil ${requirement_embryo}" EFL_EMBRYO_BUILD="-DEFL_EMBRYO_BUILD" @@ -59,12 +106,26 @@ case "$host_os" in esac AC_SUBST(EFL_EMBRYO_BUILD) +# For embryo_cc_prefix.c +PKG_CHECK_MODULES([EINA], [eina >= 1.2.0]) + +### Checks for portability layer + +PKG_CHECK_MODULES([EXOTIC], + [exotic], + [enable_exotic="yes"], + [enable_exotic="no"]) + +if test "x${enable_exotic}" = "xyes"; then + requirement_embryo="exotic ${requirement_embryo}" + + AC_DEFINE([HAVE_EXOTIC], [1], [Define to 1 if you have Exotic.]) +fi ### Checks for header files -AC_CHECK_HEADER([fnmatch.h], - [dummy="yes"], - [AC_MSG_ERROR([Cannot find fnmatch.h. Make sure your CFLAGS environment variable contains include lines for the location of this file. MinGW users: see the INSTALL file])]) +AC_CHECK_HEADERS([unistd.h]) +EFL_CHECK_PATH_MAX ### Checks for types @@ -88,10 +149,6 @@ case "$host_os" in mingw32ce*) EMBRYO_CPPFLAGS="-D_WIN32_WCE=0x0420" ;; - cegcc*) - EMBRYO_CPPFLAGS="-D_WIN32_WCE=0x0420" - EMBRYO_CFLAGS="-mwin32" - ;; esac AC_SUBST(EMBRYO_CPPFLAGS) AC_SUBST(EMBRYO_CFLAGS) @@ -101,7 +158,7 @@ AC_SUBST(EMBRYO_CFLAGS) lt_enable_auto_import="" case "$host_os" in - mingw* | cegcc*) + mingw*) lt_enable_auto_import="-Wl,--enable-auto-import" ;; esac @@ -109,30 +166,17 @@ AC_SUBST(lt_enable_auto_import) ### Checks for library functions + +AC_ISC_POSIX + +# alloca AC_FUNC_ALLOCA -case "$host_os" in - mingw* | cegcc*) - AC_DEFINE(HAVE_GETTIMEOFDAY, 1, [Defined to 1 (MinGW / CeGCC platform)]) - ;; - *) - AC_CHECK_FUNCS(gettimeofday) - ;; -esac +# fnmatch +EFL_CHECK_FNMATCH([], [AC_MSG_ERROR([Cannot find fnmatch()])]) -fnmatch_libs="" -AC_CHECK_FUNCS([fnmatch], [res="yes"], [res="no"]) -if test "x$res" = "xno"; then - AC_SEARCH_LIBS([fnmatch], - [fnmatch evil iberty], - [res="yes"], - [res="no"]) - if test "x$res" = "xno"; then - AC_MSG_ERROR([Cannot find fnmatch() in neither libc nor libfnmatch, nor libiberty, nor libevil]) - fi - fnmatch_libs="${ac_cv_search_fnmatch}" -fi -AC_SUBST(fnmatch_libs) +# gettimeofday +EFL_CHECK_GETTIMEOFDAY([], [AC_MSG_ERROR([Cannot find gettimeofday()])]) AC_SUBST(requirement_embryo) @@ -141,13 +185,13 @@ AC_SUBST(embryoincludedir) AC_OUTPUT([ Makefile doc/Makefile +doc/Doxyfile doc/embryo.dox embryo.pc include/Makefile src/Makefile src/lib/Makefile src/bin/Makefile -README embryo.spec ]) @@ -164,11 +208,15 @@ echo "------------------------------------------------------------------------" echo echo "Configuration Options Summary:" echo -echo " Documentation........: ${enable_doc}" +echo " Build embryo_cc......: $have_embryo_cc" echo -echo " Compilation..........: make" +echo " Documentation........: ${build_doc}" echo -echo " Installation.........: make install" +echo "Compilation............: make (or gmake)" +echo " CPPFLAGS.............: $CPPFLAGS" +echo " CFLAGS...............: $CFLAGS" +echo " LDFLAGS..............: $LDFLAGS" echo -echo " prefix.............: $prefix" +echo "Installation...........: make install (as root if needed, with 'su' or 'sudo')" +echo " prefix...............: $prefix" echo