From 0d7c50731bcd9fb694c4fec3ff345f6626bc35f9 Mon Sep 17 00:00:00 2001 From: pabs Date: Fri, 9 Nov 2007 01:42:45 +0000 Subject: [PATCH] Kill off synfigstudio ./bootstrap git-svn-id: http://svn.voria.com/code@1121 1f10aa63-cdf2-0310-b900-c93c546f37ac --- synfig-studio/trunk/Makefile.am | 8 +- synfig-studio/trunk/bootstrap | 258 ------------------ synfig-studio/trunk/config/ETL.m4 | 75 ------ synfig-studio/trunk/config/build.cfg | 22 -- synfig-studio/trunk/config/configure.ac | 215 --------------- synfig-studio/trunk/config/cxx_macros.m4 | 88 ------- synfig-studio/trunk/config/gnome.m4 | 407 ----------------------------- synfig-studio/trunk/config/libxml.m4 | 389 --------------------------- synfig-studio/trunk/config/project.spec.in | 46 ---- synfig-studio/trunk/config/subs.m4 | 277 -------------------- synfig-studio/trunk/config/synfig.m4 | 51 ---- synfig-studio/trunk/configure.ac | 207 +++++++++++++++ synfig-studio/trunk/m4/ETL.m4 | 75 ++++++ synfig-studio/trunk/m4/cxx_macros.m4 | 88 +++++++ synfig-studio/trunk/m4/gnome.m4 | 407 +++++++++++++++++++++++++++++ synfig-studio/trunk/m4/libxml.m4 | 389 +++++++++++++++++++++++++++ synfig-studio/trunk/m4/subs.m4 | 277 ++++++++++++++++++++ synfig-studio/trunk/m4/synfig.m4 | 51 ++++ synfig-studio/trunk/synfigstudio.spec.in | 46 ++++ 19 files changed, 1543 insertions(+), 1833 deletions(-) delete mode 100755 synfig-studio/trunk/bootstrap delete mode 100755 synfig-studio/trunk/config/ETL.m4 delete mode 100644 synfig-studio/trunk/config/build.cfg delete mode 100755 synfig-studio/trunk/config/configure.ac delete mode 100755 synfig-studio/trunk/config/cxx_macros.m4 delete mode 100755 synfig-studio/trunk/config/gnome.m4 delete mode 100755 synfig-studio/trunk/config/libxml.m4 delete mode 100755 synfig-studio/trunk/config/project.spec.in delete mode 100755 synfig-studio/trunk/config/subs.m4 delete mode 100755 synfig-studio/trunk/config/synfig.m4 create mode 100755 synfig-studio/trunk/configure.ac create mode 100755 synfig-studio/trunk/m4/ETL.m4 create mode 100755 synfig-studio/trunk/m4/cxx_macros.m4 create mode 100755 synfig-studio/trunk/m4/gnome.m4 create mode 100755 synfig-studio/trunk/m4/libxml.m4 create mode 100755 synfig-studio/trunk/m4/subs.m4 create mode 100755 synfig-studio/trunk/m4/synfig.m4 create mode 100755 synfig-studio/trunk/synfigstudio.spec.in diff --git a/synfig-studio/trunk/Makefile.am b/synfig-studio/trunk/Makefile.am index 0cfe457..fa4503e 100644 --- a/synfig-studio/trunk/Makefile.am +++ b/synfig-studio/trunk/Makefile.am @@ -1,10 +1,10 @@ # $Id$ -MAINTAINERCLEANFILES=config/ltmain.sh config/config.guess config/config.sub config/ltmain.sh config/install-sh config/mkinstalldirs config/aclocal.m4 config/missing config/texinfo.tex config/depcomp aclocal.m4 config.h.in configure stamp-h.in Makefile.in config.log config.status .doc_stamp .DS_Store @PACKAGE_TARNAME@.spec +MAINTAINERCLEANFILES=COPYING INSTALL config/ltmain.sh config/config.guess config/config.sub config/ltmain.sh config/install-sh config/mkinstalldirs config/aclocal.m4 config/missing config/texinfo.tex config/depcomp aclocal.m4 config.h.in configure stamp-h.in Makefile.in config.log config.status .doc_stamp .DS_Store synfigstudio.spec SUBDIRS=src images -EXTRA_DIST=COPYING TODO config/subs.m4 macosxbuild.sh win32build.sh win32inst.nsi.in bootstrap config/package config/depcomp config/cxx_macros.m4 @PACKAGE_TARNAME@.spec config/project.spec.in config/build.cfg config/ETL.m4 ChangeLog.old synfigstudio.xml.in synfigstudio-thumbnailer.schemas.in +EXTRA_DIST=COPYING TODO m4/subs.m4 macosxbuild.sh win32build.sh win32inst.nsi.in config/package config/depcomp m4/cxx_macros.m4 synfigstudio.spec synfigstudio.spec.in m4/ETL.m4 ChangeLog.old synfigstudio.xml.in synfigstudio-thumbnailer.schemas.in # Desktop entry #desktopdir = $(datadir)/gnome/apps/Graphics @@ -22,6 +22,7 @@ mime_DATA = synfigstudio.keys synfigstudio.mime icondir = $(datadir)/pixmaps icon_DATA = images/synfig_icon.png images/sif_icon.png +ACLOCAL_AMFLAGS=-I m4 CVS=cvs GREP=grep @@ -77,9 +78,6 @@ listhacks: run: check -$(srcdir)/configure: $(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES) - $(srcdir)/bootstrap - .doc_stamp: doxygen.cfg $(DOXYGEN) doxygen.cfg touch .doc_stamp diff --git a/synfig-studio/trunk/bootstrap b/synfig-studio/trunk/bootstrap deleted file mode 100755 index 1e66948..0000000 --- a/synfig-studio/trunk/bootstrap +++ /dev/null @@ -1,258 +0,0 @@ -#! /bin/sh -# -# Synfig Studio Bootstrap Script -# $Id$ -# -# This script creates the configure script and Makefile.in files, -# and also fixes a few things in both to ensure a smooth build -# on all compilers and platforms. -# - -# Grab the current directory and move to our own -CURR_DIR=$(pwd) -cd $(dirname $0) - -# Environment Variables -BOOTSTRAP_NAME=$(basename $0) -CONFIG_DIR="config" - -. "$CONFIG_DIR/build.cfg" - -SED_SCRIPT=" -s/@PACKAGE@/$PACKAGE/g; -s/@PACKAGE_NAME@/$PACKAGE_NAME/g; -s/@PACKAGE_BUGREPORT@/$PACKAGE_BUGREPORT/g; -s/@PACKAGE_TARNAME@/$PACKAGE_TARNAME/g; -s/@PACKAGE_VERSION@/$PACKAGE_VERSION/g; -s|@SVN_REPOSITORY@|$SVN_REPOSITORY|g; -s/@VERSION@/$VERSION/g; -s/@API_VERSION@/$API_VERSION/g; -s/@VERSION_MAJ@/$VERSION_MAJ/g; -s/@VERSION_MIN@/$VERSION_MIN/g; -s/@VERSION_REV@/$VERSION_REV/g; -s/@VERSION_REL@/$VERSION_REL/g; -s/@CFLAGS@//g; -" - -# Required automake and autoconf versions -#AUTOCONF_VERSION=2.5 -#AUTOMAKE_VERSION=1.6 -#LIBTOOL_VERSION=1.4 -export WANT_AUTOMAKE=1.8 -export WANT_AUTOCONF_2_5=1 - -LIBTOOLIZE=libtoolize -INTLTOOLIZE=intltoolize -AUTOCONF=autoconf -AUTOMAKE=automake -ACLOCAL=aclocal -AUTOHEADER=autoheader - -# Define the output function -output () { - echo $BOOTSTRAP_NAME: $* -} - -# Define the cleanup function -cleanup () { - output Cleaning up... - rm -fr config.cache autom4te*.cache configure.in $TEMPFILE -} - -output Preparing build environment for $PACKAGE-$VERSION... - -# Look for the CVS directory. If we don't find it, we need to -# ask the user if they know what they are doing. -( test -d CVS || test -d .svn ) || -{ - echo " -$BOOTSTRAP_NAME: warning: This shell script is intended for those -$BOOTSTRAP_NAME: warning: who either know what they are doing or -$BOOTSTRAP_NAME: warning: or downloaded this program from the CVS -$BOOTSTRAP_NAME: warning: repository. See README for more details. -$BOOTSTRAP_NAME: warning: To avoid seeing this message in the future, -$BOOTSTRAP_NAME: warning: create an empty directory called 'CVS'." - echo Waiting for 15 seconds... - sleep 15 -} - -# Create the temporary file -output Creating temporary file... -TEMPFILE=`mktemp /tmp/$BOOTSTRAP_NAME.XXXXXX` || -{ - output ERROR: Unable to create temporary file! - exit 1 -} - -# Check for autoconf -(which autoconf > /dev/null 2>&1 ) || -{ - output error: 'Could not find GNU autoconf!' - output You need to download and install GNU autoconf v2.52 or higher. - output '' - cleanup; - exit 1 -} - -# Check autoconf version -output Using $(autoconf --version | grep utoconf) -autoconf --version | grep -q "$AUTOCONF_VERSION" || echo \ -"$BOOTSTRAP_NAME: warning: Unexpected version of GNU Autoconf (expected $AUTOCONF_VERSION) -$BOOTSTRAP_NAME: warning: *** Bootstrap process may fail!" - -# Check for automake -(which automake > /dev/null 2>&1 ) || -{ - output error: 'Could not find GNU automake!' - output You need to download and install GNU automake v1.5 or higher. - output '' - cleanup; - exit 1 -} - -# Check automake version -output Using $(automake --version | grep utomake) -automake --version | grep -q "$AUTOMAKE_VERSION" || echo \ -"$BOOTSTRAP_NAME: warning: Unexpected version of GNU Automake (expected $AUTOMAKE_VERSION) -$BOOTSTRAP_NAME: warning: *** Bootstrap process may fail!" - -# Check for libtool -(which libtool > /dev/null 2>&1 ) || -{ - output error: 'Could not find GNU libtool!' - output You need to download and install GNU libtool v1.4 or higher. - output '' - exit 1 -} - -# Check libtool version -output Using $(libtoolize --version | grep ibtool) -libtoolize --version | grep -q "$LIBTOOL_VERSION" || echo \ -"$BOOTSTRAP_NAME: warning: Unexpected version of GNU Libtool (expected $LIBTOOL_VERSION) -$BOOTSTRAP_NAME: warning: *** Bootstrap process may fail!" - - -aclocalfix () { -sed ' -s:${srcdir}/intltool:${ac_aux_dir}/intltool:g; -s.printf ("\\t%s @ %ld ;\\n", erva+name_rva, 1+ i);.printf ("\\t\\"%s\\" @ %ld ;\\n", erva+name_rva, 1+ i);.; -' < aclocal.m4 > $TEMPFILE && -rm aclocal.m4 && -mv $TEMPFILE aclocal.m4 -} - -for FILENAME in project.spec ; do { -output Creating $FILENAME... -sed "$SED_SCRIPT" < "$CONFIG_DIR/$FILENAME.in" > "$FILENAME"; -} ; done - -output Renaming project.spec to $PACKAGE.spec... -mv project.spec "$PACKAGE.spec" - -output Finishing up $PACKAGE.spec... -echo %changelog >> "$PACKAGE.spec" -cat NEWS >> "$PACKAGE.spec" - -output Creating configure.in from configure.ac... -sed "$SED_SCRIPT" < "$CONFIG_DIR/configure.ac" > configure.in; - -output Generating ChangeLog from SVN -if test x != "x$VERSION_REL" ; then export REVISION="--revision $VERSION_REL" ; fi -test -f ChangeLog || svn2cl --include-rev $REVISION $SVN_REPOSITORY/trunk/ || touch ChangeLog - -output Setting up build environment... - -# Set the shell to output what we are doing -set -x - -# Create all of the build environment files -( -# $INTLTOOLIZE -c && - $LIBTOOLIZE -c -f && - $ACLOCAL -I "$CONFIG_DIR" $ACLOCAL_FLAGS && - aclocalfix && - $AUTOHEADER && - $AUTOCONF -o configure && - $AUTOMAKE --force-missing --add-missing --include-deps && - true -) || -{ - # Something went wrong... - set +x - output Failure. - cleanup; - exit 1 -} - -# Turn off echoing of commands -set +x - -#output Patching configure script to look for gcc3... -#sed " -#s/g++ c++/g++3 g++ c++/; -#s/gcc cc/gcc3 gcc cc/; -#s:"'${prefix}/include'":"'${prefix}/include/synfig'":; -#s:PREFIX/include:PREFIX/include/ETL:; -#" < configure > $TEMPFILE -#cp $TEMPFILE configure - -# Patch the Makefile.in files -for filename in $(find Makefile.in src -name Makefile.in) ; do { - echo $BOOTSTRAP_NAME: Patching $filename - ( - cp $filename $TEMPFILE && - sed " - s;-I. ;; - s;-I"'$(srcdir)'" ;-I"'$(top_srcdir)'" ; - s;configure.in;config/configure.ac; - " < $TEMPFILE > $filename - ) || - { - # Patch failure - output Failure. Unable to patch $filename. - cleanup; - exit 1 - } -}; done - -output Creating Makefile... -( echo " -all: - ./configure --enable-maintainer-mode - make all - -install: - ./configure --enable-maintainer-mode - make install - -check: - ./configure --enable-maintainer-mode - make check - -distcheck: - ./configure --enable-maintainer-mode - make check - -dist: - ./configure --enable-maintainer-mode - make dist - -TAG=${PACKAGE_TARNAME}_${VERSION_MAJ}_${VERSION_MIN}_${VERSION_REV} - -tagstable: - -svn delete $SVN_REPOSITORY/tags/stable -m \"Stabe Tag: Removing old tag\" - svn mkdir $SVN_REPOSITORY/tags/stable -m \"Stable Tag: Creating new directory\" - svn copy . $SVN_REPOSITORY/tags/stable -m \"Stable Tag: Copying everyhting over\" - -tagrelease: - svn mkdir $SVN_REPOSITORY/tags/\$(TAG) -m \"Release Tag: Making directory\" - svn copy . $SVN_REPOSITORY/tags/\$(TAG) -m \"Release \$(TAG)\" - -" ) > Makefile - -echo $BOOTSTRAP_NAME: Complete. - -cleanup; - -# Move back to the current directory -cd "$CURR_DIR" diff --git a/synfig-studio/trunk/config/ETL.m4 b/synfig-studio/trunk/config/ETL.m4 deleted file mode 100755 index 4cbd609..0000000 --- a/synfig-studio/trunk/config/ETL.m4 +++ /dev/null @@ -1,75 +0,0 @@ -# ETL M4 Macro -# For GNU Autotools -# $Id$ -# -# By Robert B. Quattlebaum Jr. -# - -AC_DEFUN([ETL_DEPS], -[ - AC_C_BIGENDIAN - - AC_CHECK_LIB(user32, main) - AC_CHECK_LIB(kernel32, main) - AC_CHECK_LIB(pthread, main) - - AC_HEADER_STDC - - AC_CHECK_HEADERS(pthread.h) - AC_CHECK_HEADERS(sched.h) - AC_CHECK_HEADERS(sys/times.h) - AC_CHECK_HEADERS(sys/time.h) - AC_CHECK_HEADERS(unistd.h) - AC_CHECK_HEADERS(windows.h) - AC_CHECK_FUNCS([pthread_create]) - AC_CHECK_FUNCS([pthread_rwlock_init]) - AC_CHECK_FUNCS([pthread_yield]) - AC_CHECK_FUNCS([sched_yield]) - AC_CHECK_FUNCS([CreateThread]) - AC_CHECK_FUNCS([__clone]) - AC_CHECK_FUNCS([QueryPerformanceCounter]) - - AC_CHECK_FUNCS([gettimeofday]) - AC_CHECK_FUNCS([vsscanf]) - AC_CHECK_FUNCS([vsprintf]) - AC_CHECK_FUNCS([vasprintf]) - AC_CHECK_FUNCS([vsnprintf],[],[ - AC_CHECK_FUNC([_vsnprintf],[ - AC_DEFINE(vsnprintf,_vsnprintf,[define if the vsnprintf function is mangled]) - AC_DEFINE(HAVE_VSNPRINTF,1) - ]) - ]) - - $1 -]) - -AC_DEFUN([USING_ETL], -[ - AC_ARG_WITH(ETL-includes, - [ --with-ETL-includes Specify location of ETL headers],[ - CXXFLAGS="$CXXFLAGS -I$withval" - ]) - - AC_PATH_PROG(ETL_CONFIG,ETL-config,no) - - if test "$ETL_CONFIG" = "no"; then - no_ETL_config="yes" - $2 - else - AC_MSG_CHECKING([if $ETL_CONFIG works]) - if $ETL_CONFIG --libs >/dev/null 2>&1; then - ETL_VERSION="`$ETL_CONFIG --version`" - AC_MSG_RESULT([yes, $ETL_VERSION]) - CXXFLAGS="$CXXFLAGS `$ETL_CONFIG --cxxflags`" - $1 - else - AC_MSG_RESULT(no) - no_ETL_config="yes" - $2 - fi - fi - - ETL_DEPS($1,$2) -]) - - diff --git a/synfig-studio/trunk/config/build.cfg b/synfig-studio/trunk/config/build.cfg deleted file mode 100644 index 5814530..0000000 --- a/synfig-studio/trunk/config/build.cfg +++ /dev/null @@ -1,22 +0,0 @@ - -PACKAGE_NAME="Synfig Studio" -PACKAGE_BUGREPORT="darco@deepdarc.com" -PACKAGE_TARNAME=synfigstudio -VERSION_MAJ="0" -VERSION_MIN="61" -VERSION_REV="07" -VERSION_REL=`svn info | grep Revision | sed "s/.* \([0123456789]*\)/\1/"` -SVN_REPOSITORY="http://svn.voria.com/code/synfig-studio" - -[ -d CVS ] && VERSION_REL="CVS" - -if [ x$VERSION_REL = "x" ] ; then { - VERSION=$VERSION_MAJ.$VERSION_MIN.$VERSION_REV -} else { - VERSION=$VERSION_MAJ.$VERSION_MIN.$VERSION_REV-$VERSION_REL -} ; fi - -API_VERSION="0.0" - -PACKAGE_VERSION=$VERSION -PACKAGE=$PACKAGE_TARNAME diff --git a/synfig-studio/trunk/config/configure.ac b/synfig-studio/trunk/config/configure.ac deleted file mode 100755 index 144ad10..0000000 --- a/synfig-studio/trunk/config/configure.ac +++ /dev/null @@ -1,215 +0,0 @@ -# $Id$ - -# -- I N I T -------------------------------------------------- - -. $srcdir/config/build.cfg - -AC_INIT(@PACKAGE_NAME@,@PACKAGE_VERSION@,@PACKAGE_BUGREPORT@,@PACKAGE_TARNAME@) -AC_REVISION - -AC_CONFIG_AUX_DIR(config) -AM_CONFIG_HEADER(config.h) -AC_CANONICAL_HOST -dnl AC_CANONICAL_TARGET - -AM_INIT_AUTOMAKE -AM_MAINTAINER_MODE - -API_VERSION=@API_VERSION@ - -# -- V A R I A B L E S ---------------------------------------- - -SVN_REPOSITORY=@SVN_REPOSITORY@ - -# -- P R O G R A M S ------------------------------------------ - -AC_PROG_CC -AC_PROG_CXX -AC_PROG_CPP -AC_PROG_CXXCPP -AC_PROG_INSTALL - -AC_LANG_CPLUSPLUS - - -AC_ARG_DEBUG -AC_ARG_OPTIMIZATION -AC_ARG_WARNINGS -AC_ARG_PROFILE_ARCS -AC_ARG_BRANCH_PROBABILITIES -AC_ARG_PROFILING -AC_ARG_LICENSE_KEY - -AC_ARG_ENABLE(g5opt,[ - --enable-g5opt enable optimizations specific to G5 proc],[ - G5OPTFLAGS="-mpowerpc-gpopt -mno-multiple -mno-update -mcpu=970 -mtune=970 -falign-loops=16 -falign-functions=16" -], -[ - G5OPTFLAGS= -]) - -AC_WIN32_QUIRKS - -AC_LIBTOOL_WIN32_DLL -AC_LIBTOOL_DLOPEN -AC_DISABLE_STATIC -AC_ENABLE_SHARED -AC_PROG_LIBTOOL -AC_SUBST(LIBTOOL_DEPS) -AC_LIBTOOL_PATCH - - - - - -dnl AC_PROG_INTLTOOL(0.11) - -case "$host" in - *mingw* | *cygwin*) - AM_CONDITIONAL(WIN32_PKG, true) - AM_CONDITIONAL(MACOSX_PKG, false) - ;; - *darwin*) - AM_CONDITIONAL(WIN32_PKG, false) - AM_CONDITIONAL(MACOSX_PKG, true) - ;; - *) - AM_CONDITIONAL(WIN32_PKG, false) - AM_CONDITIONAL(MACOSX_PKG, false) - ;; -esac -# -- L I B R A R I E S ---------------------------------------- - -PKG_CHECK_MODULES(GTKMM, gtkmm-2.4 gthread-2.0,[],[ - AC_MSG_ERROR([ ** Gtkmm-2.4 Is a required library, aborting.]) -]) -AC_SUBST(GTKMM_CFLAGS) -AC_SUBST(GTKMM_LIBS) - -PKG_CHECK_MODULES(SYNFIG, [synfig >= 0.61.07] [ETL >= 0.04.10] sigc++-2.0,,[ - AC_MSG_ERROR([ ** Unable to set up dependent libraries (synfig >= 0.61.07, ETL >= 0.04.10)]) -]) -AC_SUBST(SYNFIG_CFLAGS) -AC_SUBST(SYNFIG_LIBS) - -windowsys="gtkmm" -AC_DEFINE(STUDIO_WINSYS_H,"gtkmm/winsys.h",[blah]) -AM_CONDITIONAL(WINDOWSYS_GTKMM,true) - -AC_ARG_WITH(userdir,[ - --with-userdir=(dirname) Relative path to user directory],[ -],[ -case "$host" in - *mingw* | *cygwin*) - with_userdir="Synfig" - ;; - *darwin*) - with_userdir="Library/Synfig" - ;; - *) - with_userdir=".synfig" - ;; -esac -]) -AC_DEFINE_UNQUOTED(SYNFIG_USER_APP_DIR,"$with_userdir",[Synfig User Data Directory]) - -# --- FMOD CHECK ------------- -AC_ARG_WITH(libfmod,[ - --with-libfmod Enable support for FMOD],[ -],[ - AC_CHECK_LIB(fmod, FSOUND_Init,[ - with_libfmod="yes" - ],[ - with_libfmod="no" - ]) -]) -if test $with_libfmod = "yes" ; then { - AM_CONDITIONAL(WITH_FMOD,true) - FMOD_LIBS="/usr/lib/libfmod.so" - AC_DEFINE(WITH_FMOD,"I'm here damnit",[blah]) -} else { - AM_CONDITIONAL(WITH_FMOD,false) - FMOD_LIBS= -} ; fi - -# -- H E A D E R S -------------------------------------------- - -AC_CHECK_HEADERS([unistd.h signal.h fcntl.h]) -AC_CHECK_HEADERS([sys/types.h sys/wait.h sys/stat.h sys/time.h sys/resource.h sys/errno.h]) - -# -- T Y P E S & S T R U C T S -------------------------------- - -# -- F U N C T I O N S ---------------------------------------- - -AC_CHECK_FUNCS([fork]) -AC_CHECK_FUNCS([kill]) -AC_CHECK_FUNCS([pipe]) -AC_CHECK_FUNCS([setpriority mkfifo stat]) - -# -- A R G U M E N T S ---------------------------------------- - -# -- O U T P U T ---------------------------------------------- - -AC_SUBST(CFLAGS) -AC_SUBST(CPPFLAGS) -AC_SUBST(CXXFLAGS) -AC_SUBST(LDFLAGS) -AC_SUBST(SVN_REPOSITORY) - -AC_SUBST(API_VERSION) - -VERSION_MAJ=@VERSION_MAJ@ -VERSION_MIN=@VERSION_MIN@ -VERSION_REV=@VERSION_REV@ -AC_SUBST(VERSION_MAJ) -AC_SUBST(VERSION_MIN) -AC_SUBST(VERSION_REV) - -# fmod stuff... -AC_SUBST(FMOD_LIBS) - -imageext=png -AC_SUBST(imageext) - -imagedir="${datadir}/pixmaps/synfigstudio" -AC_SUBST(imagedir) - -AC_OUTPUT( -Makefile -synfigstudio.desktop -synfigstudio.mime -synfigstudio.keys -synfigstudio.xml -synfigstudio-thumbnailer.schemas -src/Makefile -src/gtkmm/Makefile -src/synfigapp/Makefile -images/Makefile -win32inst.nsi -pkg-info/macosx/synfig-studio.info -) - -# -- S U M M A R Y -------------------------------------------- - -echo " -$PACKAGE_NAME v.$VERSION -Configuration Summary -- - - - - - - -Install Prefix -------------------> $prefix -Host Platform --------------------> $host -Icon Format ----------------------> $imageext -Debug Mode -----------------------> $debug -Profiling Mode -------------------> $profiling -Optimizations --------------------> $optimization -Window System --------------------> $windowsys -FMOD Enabled ---------------------> $with_libfmod - -"'$'"CXX ------------------------------> '$CXX' -"'$'"CXXFLAGS -------------------------> '$CXXFLAGS' -"'$'"LDFLAGS --------------------------> '$LDFLAGS' -"'$'"SYNFIG_CFLAGS ---------------------> '$SYNFIG_CFLAGS' -"'$'"SYNFIG_LIBS -----------------------> '$SYNFIG_LIBS' -"'$'"GTKMM_CFLAGS ---------------------> '$GTKMM_CFLAGS' -"'$'"GTKMM_LIBS -----------------------> '$GTKMM_LIBS' -" diff --git a/synfig-studio/trunk/config/cxx_macros.m4 b/synfig-studio/trunk/config/cxx_macros.m4 deleted file mode 100755 index 8fc247a..0000000 --- a/synfig-studio/trunk/config/cxx_macros.m4 +++ /dev/null @@ -1,88 +0,0 @@ -AC_DEFUN([AC_CXX_FUNCTION_NONTYPE_PARAMETERS], -[AC_CACHE_CHECK(whether the compiler supports function templates with non-type parameters, -ac_cv_cxx_function_nontype_parameters, -[AC_LANG_SAVE - AC_LANG_CPLUSPLUS - AC_TRY_COMPILE([ -template class A {}; -template int f(const A& x) { return 0; } -],[A z; return f(z);], - ac_cv_cxx_function_nontype_parameters=yes, ac_cv_cxx_function_nontype_parameters=no) - AC_LANG_RESTORE -]) -if test "$ac_cv_cxx_function_nontype_parameters" = yes; then - AC_DEFINE(HAVE_FUNCTION_NONTYPE_PARAMETERS,, - [define if the compiler supports function templates with non-type parameters]) -fi -]) - -AC_DEFUN([AC_CXX_NAMESPACES], -[AC_CACHE_CHECK(whether the compiler implements namespaces, -ac_cv_cxx_namespaces, -[AC_LANG_SAVE - AC_LANG_CPLUSPLUS - AC_TRY_COMPILE([namespace Outer { namespace Inner { int i = 0; }}], - [using namespace Outer::Inner; return i;], - ac_cv_cxx_namespaces=yes, ac_cv_cxx_namespaces=no) - AC_LANG_RESTORE -]) -if test "$ac_cv_cxx_namespaces" = yes; then - AC_DEFINE(HAVE_NAMESPACES,,[define if the compiler implements namespaces]) -fi -]) - -AC_DEFUN([AC_CXX_HAVE_COMPLEX], -[AC_CACHE_CHECK(whether the compiler has complex, -ac_cv_cxx_have_complex, -[AC_REQUIRE([AC_CXX_NAMESPACES]) - AC_LANG_SAVE - AC_LANG_CPLUSPLUS - AC_TRY_COMPILE([#include -#ifdef HAVE_NAMESPACES -using namespace std; -#endif],[complex a; complex b; return 0;], - ac_cv_cxx_have_complex=yes, ac_cv_cxx_have_complex=no) - AC_LANG_RESTORE -]) -if test "$ac_cv_cxx_have_complex" = yes; then - AC_DEFINE(HAVE_COMPLEX,,[define if the compiler has complex]) -fi -]) - -AC_DEFUN([AC_CXX_HAVE_SSTREAM], -[AC_CACHE_CHECK(whether the compiler has stringstream, -ac_cv_cxx_have_sstream, -[AC_REQUIRE([AC_CXX_NAMESPACES]) - AC_LANG_SAVE - AC_LANG_CPLUSPLUS - AC_TRY_COMPILE([#include -#ifdef HAVE_NAMESPACES -using namespace std; -#endif],[stringstream message; message << "Hello"; return 0;], - ac_cv_cxx_have_sstream=yes, ac_cv_cxx_have_sstream=no) - AC_LANG_RESTORE -]) -if test "$ac_cv_cxx_have_sstream" = yes; then - AC_DEFINE(HAVE_SSTREAM,,[define if the compiler has stringstream]) -fi -]) - -AC_DEFUN([AC_CXX_MUTABLE], -[AC_CACHE_CHECK(whether the compiler supports the mutable keyword, -ac_cv_cxx_mutable, -[AC_LANG_SAVE - AC_LANG_CPLUSPLUS - AC_TRY_COMPILE([ -class A { mutable int i; - public: - int f (int n) const { i = n; return i; } - }; -],[A a; return a.f (1);], - ac_cv_cxx_mutable=yes, ac_cv_cxx_mutable=no) - AC_LANG_RESTORE -]) -if test "$ac_cv_cxx_mutable" = yes; then - AC_DEFINE(HAVE_MUTABLE,,[define if the compiler supports the mutable keyword]) -fi -]) - diff --git a/synfig-studio/trunk/config/gnome.m4 b/synfig-studio/trunk/config/gnome.m4 deleted file mode 100755 index bb96b4b..0000000 --- a/synfig-studio/trunk/config/gnome.m4 +++ /dev/null @@ -1,407 +0,0 @@ -# gnome-common.m4 -# - -dnl GNOME_COMMON_INIT - -AC_DEFUN([GNOME_COMMON_INIT], -[ - AC_CACHE_VAL(ac_cv_gnome_aclocal_dir, - [ac_cv_gnome_aclocal_dir="$GNOME_COMMON_MACROS_DIR"]) - AC_CACHE_VAL(ac_cv_gnome_aclocal_flags, - [ac_cv_gnome_aclocal_flags="$ACLOCAL_FLAGS"]) - GNOME_ACLOCAL_DIR="$ac_cv_gnome_aclocal_dir" - GNOME_ACLOCAL_FLAGS="$ac_cv_gnome_aclocal_flags" - AC_SUBST(GNOME_ACLOCAL_DIR) - AC_SUBST(GNOME_ACLOCAL_FLAGS) - - ACLOCAL="$ACLOCAL $GNOME_ACLOCAL_FLAGS" - - AM_CONDITIONAL(INSIDE_GNOME_DOCU, false) -]) - -AC_DEFUN([GNOME_GTKDOC_CHECK], -[ - AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false) - AM_CONDITIONAL(HAVE_GTK_DOC, $GTKDOC) - AC_SUBST(HAVE_GTK_DOC) - - dnl Let people disable the gtk-doc stuff. - AC_ARG_ENABLE(gtk-doc, [ --enable-gtk-doc Use gtk-doc to build documentation [default=auto]], enable_gtk_doc="$enableval", enable_gtk_doc=auto) - - if test x$enable_gtk_doc = xauto ; then - if test x$GTKDOC = xtrue ; then - enable_gtk_doc=yes - else - enable_gtk_doc=no - fi - fi - - dnl NOTE: We need to use a separate automake conditional for this - dnl to make this work with the tarballs. - AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes) -]) - -AC_DEFUN([GNOME_DEBUG_CHECK], -[ - AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]], enable_debug="$enableval", enable_debug=no) - - if test x$enable_debug = xyes ; then - AC_DEFINE(GNOME_ENABLE_DEBUG) - fi -]) - -# Define a conditional. - -AC_DEFUN([AM_CONDITIONAL], -[AC_SUBST($1_TRUE) -AC_SUBST($1_FALSE) -if $2; then - $1_TRUE= - $1_FALSE='#' -else - $1_TRUE='#' - $1_FALSE= -fi]) - - -dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not) -dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page -dnl also defines GSTUFF_PKG_ERRORS on error -AC_DEFUN([PKG_CHECK_MODULES], [ - succeeded=no - - if test -z "$PKG_CONFIG"; then - AC_PATH_PROG(PKG_CONFIG, pkg-config, no) - fi - - if test "$PKG_CONFIG" = "no" ; then - echo "*** The pkg-config script could not be found. Make sure it is" - echo "*** in your path, or set the PKG_CONFIG environment variable" - echo "*** to the full path to pkg-config." - echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config." - else - PKG_CONFIG_MIN_VERSION=0.9.0 - if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then - AC_MSG_CHECKING(for $2) - - if $PKG_CONFIG --exists "$2" ; then - AC_MSG_RESULT(yes) - succeeded=yes - - AC_MSG_CHECKING($1_CFLAGS) - $1_CFLAGS=`$PKG_CONFIG --cflags "$2"` - AC_MSG_RESULT($$1_CFLAGS) - - AC_MSG_CHECKING($1_LIBS) - $1_LIBS=`$PKG_CONFIG --libs "$2"` - AC_MSG_RESULT($$1_LIBS) - else - $1_CFLAGS="" - $1_LIBS="" - ## If we have a custom action on failure, don't print errors, but - ## do set a variable so people can do so. - $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"` - ifelse([$4], ,echo $$1_PKG_ERRORS,) - fi - - AC_SUBST($1_CFLAGS) - AC_SUBST($1_LIBS) - else - echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." - echo "*** See http://www.freedesktop.org/software/pkgconfig" - fi - fi - - if test $succeeded = yes; then - ifelse([$3], , :, [$3]) - else - ifelse([$4], , AC_MSG_ERROR([Library requirements ($2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.]), [$4]) - fi -]) - - - -# Macro to add for using GNU gettext. -# Ulrich Drepper , 1995, 1996 -# -# Modified to never use included libintl. -# Owen Taylor , 12/15/1998 -# -# -# This file can be copied and used freely without restrictions. It can -# be used in projects which are not available under the GNU Public License -# but which still want to provide support for the GNU gettext functionality. -# Please note that the actual code is *not* freely available. -# -# -# If you make changes to this file, you MUST update the copy in -# acinclude.m4. [ aclocal dies on duplicate macros, so if -# we run 'aclocal -I macros/' then we'll run into problems -# once we've installed glib-gettext.m4 :-( ] -# - -AC_DEFUN([AM_GLIB_LC_MESSAGES], - [if test $ac_cv_header_locale_h = yes; then - AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, - [AC_TRY_LINK([#include ], [return LC_MESSAGES], - am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) - if test $am_cv_val_LC_MESSAGES = yes; then - AC_DEFINE(HAVE_LC_MESSAGES, 1, - [Define if your file defines LC_MESSAGES.]) - fi - fi]) - -dnl AM_GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, -dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) -AC_DEFUN([AM_GLIB_PATH_PROG_WITH_TEST], -[# Extract the first word of "$2", so it can be a program name with args. -set dummy $2; ac_word=[$]2 -AC_MSG_CHECKING([for $ac_word]) -AC_CACHE_VAL(ac_cv_path_$1, -[case "[$]$1" in - /*) - ac_cv_path_$1="[$]$1" # Let the user override the test with a path. - ;; - *) - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in ifelse([$5], , $PATH, [$5]); do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - if [$3]; then - ac_cv_path_$1="$ac_dir/$ac_word" - break - fi - fi - done - IFS="$ac_save_ifs" -dnl If no 4th arg is given, leave the cache variable unset, -dnl so AC_PATH_PROGS will keep looking. -ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" -])dnl - ;; -esac])dnl -$1="$ac_cv_path_$1" -if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then - AC_MSG_RESULT([$]$1) -else - AC_MSG_RESULT(no) -fi -AC_SUBST($1)dnl -]) - -# serial 5 - -AC_DEFUN([AM_GLIB_WITH_NLS], - dnl NLS is obligatory - [USE_NLS=yes - AC_SUBST(USE_NLS) - - dnl Figure out what method - nls_cv_force_use_gnu_gettext="no" - - nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" - if test "$nls_cv_force_use_gnu_gettext" != "yes"; then - dnl User does not insist on using GNU NLS library. Figure out what - dnl to use. If gettext or catgets are available (in this order) we - dnl use this. Else we have to fall back to GNU NLS library. - dnl catgets is only used if permitted by option --with-catgets. - nls_cv_header_intl= - nls_cv_header_libgt= - CATOBJEXT=NONE - XGETTEXT=: - - AC_CHECK_HEADER(libintl.h, - [AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc, - [AC_TRY_LINK([#include ], [return (int) dgettext ("","")], - gt_cv_func_dgettext_libc=yes, gt_cv_func_dgettext_libc=no)]) - - gt_cv_func_dgettext_libintl="no" - libintl_extra_libs="" - - if test "$gt_cv_func_dgettext_libc" != "yes" ; then - AC_CHECK_LIB(intl, bindtextdomain, - [AC_CHECK_LIB(intl, dgettext, - gt_cv_func_dgettext_libintl=yes)]) - - if test "$gt_cv_func_dgettext_libc" != "yes" ; then - AC_MSG_CHECKING([if -liconv is needed to use gettext]) - AC_MSG_RESULT([]) - AC_CHECK_LIB(intl, dcgettext, - [gt_cv_func_dgettext_libintl=yes - libintl_extra_libs=-liconv], - :,-liconv) - fi - fi - - if test "$gt_cv_func_dgettext_libintl" = "yes"; then - LIBS="$LIBS -lintl $libintl_extra_libs"; - fi - - if test "$gt_cv_func_dgettext_libc" = "yes" \ - || test "$gt_cv_func_dgettext_libintl" = "yes"; then - AC_DEFINE(HAVE_GETTEXT,1, - [Define if the GNU gettext() function is already present or preinstalled.]) - AM_GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, - [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl - if test "$MSGFMT" != "no"; then - AC_CHECK_FUNCS(dcgettext) - AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) - AM_GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, - [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :) - AC_TRY_LINK(, [extern int _nl_msg_cat_cntr; - return _nl_msg_cat_cntr], - [CATOBJEXT=.gmo - DATADIRNAME=share], - [CATOBJEXT=.mo - DATADIRNAME=lib]) - INSTOBJEXT=.mo - fi - fi - - # Added by Martin Baulig 12/15/98 for libc5 systems - if test "$gt_cv_func_dgettext_libc" != "yes" \ - && test "$gt_cv_func_dgettext_libintl" = "yes"; then - INTLLIBS="-lintl $libintl_extra_libs" - LIBS=`echo $LIBS | sed -e 's/-lintl//'` - fi - ]) - - if test "$CATOBJEXT" = "NONE"; then - dnl Neither gettext nor catgets in included in the C library. - dnl Fall back on GNU gettext library. - nls_cv_use_gnu_gettext=yes - fi - fi - - if test "$nls_cv_use_gnu_gettext" != "yes"; then - AC_DEFINE(ENABLE_NLS, 1, - [always defined to indicate that i18n is enabled]) - else - dnl Unset this variable since we use the non-zero value as a flag. - CATOBJEXT= - fi - - dnl Test whether we really found GNU xgettext. - if test "$XGETTEXT" != ":"; then - dnl If it is no GNU xgettext we define it as : so that the - dnl Makefiles still can work. - if $XGETTEXT --omit-header /dev/null 2> /dev/null; then - : ; - else - AC_MSG_RESULT( - [found xgettext program is not GNU xgettext; ignore it]) - XGETTEXT=":" - fi - fi - - # We need to process the po/ directory. - POSUB=po - - AC_OUTPUT_COMMANDS( - [case "$CONFIG_FILES" in *po/Makefile.in*) - sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile - esac]) - - dnl These rules are solely for the distribution goal. While doing this - dnl we only have to keep exactly one list of the available catalogs - dnl in configure.in. - for lang in $ALL_LINGUAS; do - GMOFILES="$GMOFILES $lang.gmo" - POFILES="$POFILES $lang.po" - done - - dnl Make all variables we use known to autoconf. - AC_SUBST(CATALOGS) - AC_SUBST(CATOBJEXT) - AC_SUBST(DATADIRNAME) - AC_SUBST(GMOFILES) - AC_SUBST(INSTOBJEXT) - AC_SUBST(INTLDEPS) - AC_SUBST(INTLLIBS) - AC_SUBST(INTLOBJS) - AC_SUBST(POFILES) - AC_SUBST(POSUB) - ]) - -AC_DEFUN([AM_GLIB_GNU_GETTEXT], - [AC_REQUIRE([AC_PROG_MAKE_SET])dnl - AC_REQUIRE([AC_PROG_CC])dnl - AC_REQUIRE([AC_PROG_RANLIB])dnl - AC_REQUIRE([AC_HEADER_STDC])dnl - AC_REQUIRE([AC_C_CONST])dnl - AC_REQUIRE([AC_C_INLINE])dnl - AC_REQUIRE([AC_TYPE_OFF_T])dnl - AC_REQUIRE([AC_TYPE_SIZE_T])dnl - AC_REQUIRE([AC_FUNC_ALLOCA])dnl - AC_REQUIRE([AC_FUNC_MMAP])dnl - - AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h string.h \ -unistd.h sys/param.h]) - AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp \ -strdup __argz_count __argz_stringify __argz_next]) - - AM_GLIB_LC_MESSAGES - AM_GLIB_WITH_NLS - - if test "x$CATOBJEXT" != "x"; then - if test "x$ALL_LINGUAS" = "x"; then - LINGUAS= - else - AC_MSG_CHECKING(for catalogs to be installed) - NEW_LINGUAS= - for lang in ${LINGUAS=$ALL_LINGUAS}; do - case "$ALL_LINGUAS" in - *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; - esac - done - LINGUAS=$NEW_LINGUAS - AC_MSG_RESULT($LINGUAS) - fi - - dnl Construct list of names of catalog files to be constructed. - if test -n "$LINGUAS"; then - for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done - fi - fi - - dnl Determine which catalog format we have (if any is needed) - dnl For now we know about two different formats: - dnl Linux libc-5 and the normal X/Open format - test -d po || mkdir po - if test "$CATOBJEXT" = ".cat"; then - AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen) - - dnl Transform the SED scripts while copying because some dumb SEDs - dnl cannot handle comments. - sed -e '/^#/d' $srcdir/po/$msgformat-msg.sed > po/po2msg.sed - fi - - dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly - dnl find the mkinstalldirs script in another subdir but ($top_srcdir). - dnl Try to locate is. - MKINSTALLDIRS= - if test -n "$ac_aux_dir"; then - MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" - fi - if test -z "$MKINSTALLDIRS"; then - MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" - fi - AC_SUBST(MKINSTALLDIRS) - - dnl Generate list of files to be processed by xgettext which will - dnl be included in po/Makefile. - test -d po || mkdir po - if test "x$srcdir" != "x."; then - if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then - posrcprefix="$srcdir/" - else - posrcprefix="../$srcdir/" - fi - else - posrcprefix="../" - fi - rm -f po/POTFILES - sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ - < $srcdir/po/POTFILES.in > po/POTFILES - ]) - diff --git a/synfig-studio/trunk/config/libxml.m4 b/synfig-studio/trunk/config/libxml.m4 deleted file mode 100755 index 8b0e006..0000000 --- a/synfig-studio/trunk/config/libxml.m4 +++ /dev/null @@ -1,389 +0,0 @@ -# Configure paths for LIBXML2 -# Toshio Kuratomi 2001-04-21 -# Adapted from: -# Configure paths for GLIB -# Owen Taylor 97-11-3 - -dnl AM_PATH_XML([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) -dnl Test for XML, and define XML_CFLAGS and XML_LIBS -dnl -AC_DEFUN([AM_PATH_XML],[ -AC_ARG_WITH(xml-prefix, - [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], - xml_config_prefix="$withval", xml_config_prefix="") -AC_ARG_WITH(xml-exec-prefix, - [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], - xml_config_exec_prefix="$withval", xml_config_exec_prefix="") -AC_ARG_ENABLE(xmltest, - [ --disable-xmltest Do not try to compile and run a test LIBXML program],, - enable_xmltest=yes) - - if test x$xml_config_exec_prefix != x ; then - xml_config_args="$xml_config_args --exec-prefix=$xml_config_exec_prefix" - if test x${XML_CONFIG+set} != xset ; then - XML_CONFIG=$xml_config_exec_prefix/bin/xml-config - fi - fi - if test x$xml_config_prefix != x ; then - xml_config_args="$xml_config_args --prefix=$xml_config_prefix" - if test x${XML_CONFIG+set} != xset ; then - XML_CONFIG=$xml_config_prefix/bin/xml-config - fi - fi - - AC_PATH_PROG(XML_CONFIG, xml-config, no) - min_xml_version=ifelse([$1], ,1.0.0,[$1]) - AC_MSG_CHECKING(for libxml - version >= $min_xml_version) - no_xml="" - if test "$XML_CONFIG" = "no" ; then - no_xml=yes - else - XML_CFLAGS=`$XML_CONFIG $xml_config_args --cflags` - XML_LIBS=`$XML_CONFIG $xml_config_args --libs` - xml_config_major_version=`$XML_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - xml_config_minor_version=`$XML_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - xml_config_micro_version=`$XML_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_xmltest" = "xyes" ; then - ac_save_CFLAGS="$CFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $XML_CFLAGS" - LIBS="$XML_LIBS $LIBS" -dnl -dnl Now check if the installed libxml is sufficiently new. -dnl (Also sanity checks the results of xml-config to some extent) -dnl - rm -f conf.xmltest - AC_TRY_RUN([ -#include -#include -#include -#include - -int -main() -{ - int xml_major_version, xml_minor_version, xml_micro_version; - int major, minor, micro; - char *tmp_version; - int tmp_int_version; - - system("touch conf.xmltest"); - - /* Capture xml-config output via autoconf/configure variables */ - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = (char *)strdup("$min_xml_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string from xml-config\n", "$min_xml_version"); - exit(1); - } - free(tmp_version); - - /* Capture the version information from the header files */ - tmp_int_version = LIBXML_VERSION; - xml_major_version=tmp_int_version / 10000; - xml_minor_version=(tmp_int_version - xml_major_version * 10000) / 100; - xml_micro_version=(tmp_int_version - xml_minor_version * 100 - xml_major_version * 10000); - - /* Compare xml-config output to the libxml headers */ - if ((xml_major_version != $xml_config_major_version) || - (xml_minor_version != $xml_config_minor_version) -#if 0 - || -/* The last released version of libxml-1.x has an incorrect micro version in - * the header file so neither the includes nor the library will match the - * micro_version to the output of xml-config - */ - (xml_micro_version != $xml_config_micro_version) -#endif - ) - - { - printf("*** libxml header files (version %d.%d.%d) do not match\n", - xml_major_version, xml_minor_version, xml_micro_version); - printf("*** xml-config (version %d.%d.%d)\n", - $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); - return 1; - } -/* Compare the headers to the library to make sure we match */ - /* Less than ideal -- doesn't provide us with return value feedback, - * only exits if there's a serious mismatch between header and library. - */ - LIBXML_TEST_VERSION; - - /* Test that the library is greater than our minimum version */ - if (($xml_config_major_version > major) || - (($xml_config_major_version == major) && ($xml_config_minor_version > minor)) || - (($xml_config_major_version == major) && ($xml_config_minor_version == minor) && - ($xml_config_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", - xml_major_version, xml_minor_version, xml_micro_version); - printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the xml-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of LIBXML, but you can also set the XML_CONFIG environment to point to the\n"); - printf("*** correct copy of xml-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - return 1; -} -],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - if test "x$no_xml" = x ; then - AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$XML_CONFIG" = "no" ; then - echo "*** The xml-config script installed by LIBXML could not be found" - echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" - echo "*** your path, or set the XML_CONFIG environment variable to the" - echo "*** full path to xml-config." - else - if test -f conf.xmltest ; then - : - else - echo "*** Could not run libxml test program, checking why..." - CFLAGS="$CFLAGS $XML_CFLAGS" - LIBS="$LIBS $XML_LIBS" - AC_TRY_LINK([ -#include -#include -], [ LIBXML_TEST_VERSION; return 0;], - [ echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding LIBXML or finding the wrong" - echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], - [ echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" - echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" - echo "*** may want to edit the xml-config script: $XML_CONFIG" ]) - CFLAGS="$ac_save_CFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - XML_CFLAGS="" - XML_LIBS="" - ifelse([$3], , :, [$3]) - fi - AC_SUBST(XML_CFLAGS) - AC_SUBST(XML_LIBS) - rm -f conf.xmltest -]) - -# Configure paths for LIBXML2 -# Toshio Kuratomi 2001-04-21 -# Adapted from: -# Configure paths for GLIB -# Owen Taylor 97-11-3 - -dnl AM_PATH_XML2([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) -dnl Test for XML, and define XML_CFLAGS and XML_LIBS -dnl -AC_DEFUN([AM_PATH_XML2],[ -AC_ARG_WITH(xml-prefix, - [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], - xml_config_prefix="$withval", xml_config_prefix="") -AC_ARG_WITH(xml-exec-prefix, - [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], - xml_config_exec_prefix="$withval", xml_config_exec_prefix="") -AC_ARG_ENABLE(xmltest, - [ --disable-xmltest Do not try to compile and run a test LIBXML program],, - enable_xmltest=yes) - - if test x$xml_config_exec_prefix != x ; then - xml_config_args="$xml_config_args --exec-prefix=$xml_config_exec_prefix" - if test x${XML2_CONFIG+set} != xset ; then - XML2_CONFIG=$xml_config_exec_prefix/bin/xml2-config - fi - fi - if test x$xml_config_prefix != x ; then - xml_config_args="$xml_config_args --prefix=$xml_config_prefix" - if test x${XML2_CONFIG+set} != xset ; then - XML2_CONFIG=$xml_config_prefix/bin/xml2-config - fi - fi - - AC_PATH_PROG(XML2_CONFIG, xml2-config, no) - min_xml_version=ifelse([$1], ,2.0.0,[$1]) - AC_MSG_CHECKING(for libxml - version >= $min_xml_version) - no_xml="" - if test "$XML2_CONFIG" = "no" ; then - no_xml=yes - else - XML_CFLAGS=`$XML2_CONFIG $xml_config_args --cflags` - XML_LIBS=`$XML2_CONFIG $xml_config_args --libs` - xml_config_major_version=`$XML2_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - xml_config_minor_version=`$XML2_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` - xml_config_micro_version=`$XML2_CONFIG $xml_config_args --version | \ - sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` - if test "x$enable_xmltest" = "xyes" ; then - ac_save_CFLAGS="$CFLAGS" - ac_save_CXXFLAGS="$CXXFLAGS" - ac_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $XML_CFLAGS" - CXXFLAGS="$CXXFLAGS $XML_CFLAGS" - LIBS="$XML_LIBS $LIBS" -dnl -dnl Now check if the installed libxml is sufficiently new. -dnl (Also sanity checks the results of xml2-config to some extent) -dnl - rm -f conf.xmltest - AC_TRY_RUN([ -#include -#include -#include -#include - -int -main() -{ - int xml_major_version, xml_minor_version, xml_micro_version; - int major, minor, micro; - char *tmp_version; - - system("touch conf.xmltest"); - - /* Capture xml2-config output via autoconf/configure variables */ - /* HP/UX 9 (%@#!) writes to sscanf strings */ - tmp_version = (char *)strdup("$min_xml_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { - printf("%s, bad version string from xml2-config\n", "$min_xml_version"); - exit(1); - } - free(tmp_version); - - /* Capture the version information from the header files */ - tmp_version = (char *)strdup(LIBXML_DOTTED_VERSION); - if (sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) { - printf("%s, bad version string from libxml includes\n", "LIBXML_DOTTED_VERSION"); - exit(1); - } - free(tmp_version); - - /* Compare xml2-config output to the libxml headers */ - if ((xml_major_version != $xml_config_major_version) || - (xml_minor_version != $xml_config_minor_version) || - (xml_micro_version != $xml_config_micro_version)) - { - printf("*** libxml header files (version %d.%d.%d) do not match\n", - xml_major_version, xml_minor_version, xml_micro_version); - printf("*** xml2-config (version %d.%d.%d)\n", - $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); - return 1; - } -/* Compare the headers to the library to make sure we match */ - /* Less than ideal -- doesn't provide us with return value feedback, - * only exits if there's a serious mismatch between header and library. - */ - LIBXML_TEST_VERSION; - - /* Test that the library is greater than our minimum version */ - if ((xml_major_version > major) || - ((xml_major_version == major) && (xml_minor_version > minor)) || - ((xml_major_version == major) && (xml_minor_version == minor) && - (xml_micro_version >= micro))) - { - return 0; - } - else - { - printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", - xml_major_version, xml_minor_version, xml_micro_version); - printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", - major, minor, micro); - printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); - printf("***\n"); - printf("*** If you have already installed a sufficiently new version, this error\n"); - printf("*** probably means that the wrong copy of the xml2-config shell script is\n"); - printf("*** being found. The easiest way to fix this is to remove the old version\n"); - printf("*** of LIBXML, but you can also set the XML2_CONFIG environment to point to the\n"); - printf("*** correct copy of xml2-config. (In this case, you will have to\n"); - printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); - printf("*** so that the correct libraries are found at run-time))\n"); - } - return 1; -} -],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) - CFLAGS="$ac_save_CFLAGS" - CXXFLAGS="$ac_save_CXXFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - if test "x$no_xml" = x ; then - AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) - ifelse([$2], , :, [$2]) - else - AC_MSG_RESULT(no) - if test "$XML2_CONFIG" = "no" ; then - echo "*** The xml2-config script installed by LIBXML could not be found" - echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" - echo "*** your path, or set the XML2_CONFIG environment variable to the" - echo "*** full path to xml2-config." - else - if test -f conf.xmltest ; then - : - else - echo "*** Could not run libxml test program, checking why..." - CFLAGS="$CFLAGS $XML_CFLAGS" - CXXFLAGS="$CXXFLAGS $XML_CFLAGS" - LIBS="$LIBS $XML_LIBS" - AC_TRY_LINK([ -#include -#include -], [ LIBXML_TEST_VERSION; return 0;], - [ echo "*** The test program compiled, but did not run. This usually means" - echo "*** that the run-time linker is not finding LIBXML or finding the wrong" - echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" - echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" - echo "*** to the installed location Also, make sure you have run ldconfig if that" - echo "*** is required on your system" - echo "***" - echo "*** If you have an old version installed, it is best to remove it, although" - echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], - [ echo "*** The test program failed to compile or link. See the file config.log for the" - echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" - echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" - echo "*** may want to edit the xml2-config script: $XML2_CONFIG" ]) - CFLAGS="$ac_save_CFLAGS" - CXXFLAGS="$ac_save_CXXFLAGS" - LIBS="$ac_save_LIBS" - fi - fi - - XML_CFLAGS="" - XML_LIBS="" - $3 - - - ifelse([$3], , :, [$3]) - fi - AC_SUBST(XML_CFLAGS) - AC_SUBST(XML_LIBS) - rm -f conf.xmltest -]) diff --git a/synfig-studio/trunk/config/project.spec.in b/synfig-studio/trunk/config/project.spec.in deleted file mode 100755 index 8720e8c..0000000 --- a/synfig-studio/trunk/config/project.spec.in +++ /dev/null @@ -1,46 +0,0 @@ - -Summary: Voria Extented Template Library -Name: @PACKAGE_TARNAME@-devel -Version: @VERSION_MAJ@.@VERSION_MIN@.@VERSION_REV@ -Release: @VERSION_REL@ -Copyright: free (see license), see /usr/share/doc/%{name}-%{version}/license.html -URL: http://www.synfig.com/ -Packager: Robert B. Quattlebaum Jr. -Group: Development/Languages -Icon: config/logo.gif -#Patch0: STLport-rename.patch -#Patch1: STLport-rules.patch -#Patch2: STLport-install-dir.patch -Buildroot: %{_tmppath}/%{name}-%{version}-%(id -u -n) - -%description -VoriaETL is a multiplatform class and template library -designed to complement and supplement the C++ STL. - -%prep -%setup -#%patch0 -p1 -#%patch1 -p1 -#%patch2 -p1 - -%build -./configure --prefix=$RPM_BUILD_ROOT -make - -%install -make install - -%clean -make clean - -%post -n @PACKAGE@-devel -/sbin/ldconfig - -%postun -n @PACKAGE@-devel -/sbin/ldconfig - -%files -%defattr(-,root,root) -%doc INSTALL README doc test -/usr/include/* - diff --git a/synfig-studio/trunk/config/subs.m4 b/synfig-studio/trunk/config/subs.m4 deleted file mode 100755 index 7815530..0000000 --- a/synfig-studio/trunk/config/subs.m4 +++ /dev/null @@ -1,277 +0,0 @@ - -## AC_ARG_WARNINGS() -## -## Provide the --enable-warnings configure argument, set to 'minimum' -## by default. -## -AC_DEFUN([AC_ARG_WARNINGS], -[ - AC_ARG_ENABLE([warnings], - [ --enable-warnings=[[none|minimum|maximum|hardcore]] - Control compiler pickyness. [[default=maximum]]], - [gtkmm_enable_warnings="$enableval"], - gtkmm_enable_warnings="maximum") - - AC_MSG_CHECKING([for compiler warning flags to use]) - - gtkmm_warning_flags='' - - # -W is now known as -Wextra, but that's not known by gcc 2 or 3 - case "$gtkmm_enable_warnings" in - none|no) gtkmm_warning_flags='';; - minimum|yes) gtkmm_warning_flags='-Wall -Wno-unused-parameter';; - maximum) gtkmm_warning_flags='-W -Wall -Wno-unused-parameter';; - hardcore) gtkmm_warning_flags='-W -Wall -Werror -Wno-unused-parameter';; - esac - - gtkmm_use_flags='' - - if test "x$gtkmm_warning_flags" != "x" - then - echo 'int foo() { return 0; }' > conftest.cc - - for flag in $gtkmm_warning_flags - do - # Test whether the compiler accepts the flag. GCC doesn't bail - # out when given an unsupported flag but prints a warning, so - # check the compiler output instead. - gtkmm_cxx_out="`$CXX $flag -c conftest.cc 2>&1`" - rm -f conftest.$OBJEXT - test "x${gtkmm_cxx_out}" = "x" && \ - gtkmm_use_flags="${gtkmm_use_flags:+$gtkmm_use_flags }$flag" - done - - rm -f conftest.cc - gtkmm_cxx_out='' - fi - - if test "x$gtkmm_use_flags" != "x" - then - for flag in $gtkmm_use_flags - do - case " $CXXFLAGS " in - *" $flag "*) ;; # don't add flags twice - *) CXXFLAGS="${CXXFLAGS:+$CXXFLAGS }$flag";; - esac - done - else - gtkmm_use_flags='none' - fi - - AC_MSG_RESULT([$gtkmm_use_flags]) -]) - - - - -AC_DEFUN([AC_ARG_DEBUG], -[ - AC_MSG_CHECKING([for debug flags]) - - AC_ARG_ENABLE(debug,[ --enable-debug Build in debugging mode],[ - debug=$enableval - ],[ - debug="no" - ]) - debug_flags='' - - case "$debug" in - yes) - debug_flags="-D_DEBUG -g" - ;; - half) - debug_flags="-DNDEBUG -g" - ;; - no|*) - debug_flags="-DNDEBUG -Wno-deprecated" - ;; - esac - - - CXXFLAGS="`echo $CXXFLAGS | sed s:-g::` $debug_flags" - CFLAGS="`echo $CFLAGS | sed s:-g::` $debug_flags" - - AC_MSG_RESULT([$debug_flags]) -]) - - - - -AC_DEFUN([AC_ARG_OPTIMIZATION], -[ - AC_MSG_CHECKING([for optimization flags]) - - AC_ARG_ENABLE(optimization,[ --enable-optimization=[[0,1,2,3,4]] Select optimization level (default=2)],[ - optimization=$enableval - ],[ - optimization="2" - ]) - optimization_flags='' - case "$optimization" in - 0|no) optimization_flags="-O0";; - 1) optimization_flags="-O1";; - 2|yes) optimization_flags="-O2";; - pass1) optimization_flags="-O2 -fprofile-arcs";; - pass2) optimization_flags="-O2 -fbranch-probabilities";; - 3) optimization_flags="-O3";; - *) optimization_flags="-O4";; - esac - CXXFLAGS="`echo $CXXFLAGS | sed 's:-O.::g'` $optimization_flags" - CFLAGS="`echo $CFLAGS | sed 's:-O.::g'` $optimization_flags" - AC_MSG_RESULT([$optimization_flags]) -]) - -AC_DEFUN([AC_ARG_PROFILE_ARCS], -[ - AC_MSG_CHECKING([for arc profiling]) - - AC_ARG_ENABLE(profile-arcs,[ --enable-profile-arcs Enable arc profiling],[ - profile_arcs=$enableval - ],[ - profile_arcs=no - ]) - - if test $profile_arcs = "yes" ; then { - CXXFLAGS="$CXXFLAGS -fprofile-arcs"; - CFLAGS="$CFLAGS -fprofile-arcs"; - } ; fi - - AC_MSG_RESULT([$profile_arcs]) -]) - -AC_DEFUN([AC_ARG_BRANCH_PROBABILITIES], -[ - AC_MSG_CHECKING([for branch-probabilities]) - - AC_ARG_ENABLE(branch-probabilities,[ --enable-branch-probabilities Enable branch-probabilities],[ - branch_probabilities=$enableval - ],[ - branch_probabilities=no - ]) - - if test $branch_probabilities = "yes" ; then { - CXXFLAGS="$CXXFLAGS -fbranch-probabilities"; - CFLAGS="$CFLAGS -fbranch-probabilities"; - } ; fi - - AC_MSG_RESULT([$branch_probabilities]) -]) - -AC_DEFUN([AC_ARG_PROFILING], -[ - AC_MSG_CHECKING([for profiling]) - - AC_ARG_ENABLE(profiling,[ --enable-profiling Enable profiling using gprof],[ - profiling=$enableval - ],[ - profiling=no - ]) - - if test $profiling = "yes" ; then { - CFLAGS="$CFLAGS -pg"; - CXXFLAGS="$CXXFLAGS -pg"; - LDFLAGS="$LDFLAGS -pg"; - LIBS="$LIBS"; - } ; fi - - AC_MSG_RESULT([$profiling]) -]) - -AC_DEFUN([AC_ARG_TIMELIMIT], -[ - AC_ARG_ENABLE(timelimit,[ --enable-timelimit=[[days]] Set number of usable days(default=forever)],[ - death_time=$((`date +%s`+$enableval*60*60*24)) - AC_DEFINE_UNQUOTED(DEATH_TIME,$death_time, [ Describes the time at which the library will stop working ] ) - ], - [ - death_time="no" - ]) -]) - -AC_DEFUN([AC_ARG_LICENSE_KEY], -[ - AC_ARG_ENABLE(license_key,[ --enable-license-key Turn on license key requirement],[ - AC_DEFINE(LICENSE_KEY_REQUIRED,, [ Enables license key checks ] ) - ], - [ - license_key="no" - ]) -]) - -AC_DEFUN([AC_ARG_TIMELIMIT], -[ - AC_ARG_ENABLE(timelimit,[ --enable-timelimit=[[days]] Set number of usable days(default=forever)],[ - death_time=$((`date +%s`+$enableval*60*60*24)) - AC_DEFINE_UNQUOTED(DEATH_TIME,$death_time, [ Describes the time at which the library will stop working ] ) - ], - [ - death_time="no" - ]) -]) - -MINGW_FLAGS="-mno-cygwin" - - -AC_DEFUN([AC_WIN32_QUIRKS], -[ - -case "$host" in - *mingw*) - AC_MSG_CHECKING([the flavor of the compiler]) - if ( $CC --version | grep -q mingw ) ; then { - AC_MSG_RESULT([compiler is mingw special]) - LIBTOOL_PATCH_SED=" - s/dir=\"\$absdir\"/dir=\`cygpath -d -m \"\$absdir\"\`/; - s/absdir=\`cd \"\$dir\" && pwd\`/absdir=\`cygpath -d -m \"\$dir\"\`/; - s/# We need an absolute path/dir=\`cygpath -d -m \"\$dir\"\` # We need an absolute path/; - s- /usr/lib- C:/mingw/lib-g; - s-\"/lib -\"C:/mingw/lib -g; - s- /lib/ - -g; - "; - sys_lib_dlsearch_path_spec="C:/mingw/lib" - ac_default_prefix=`cygpath -d -m "$ac_default_prefix"`; - } else { - AC_MSG_RESULT([compiler is cygwin stock, adding -mno-cygwin]) - CPP="$CPP $MINGW_FLAGS" - CC="$CC $MINGW_FLAGS" - CXX="$CXX $MINGW_FLAGS -L/usr/$host/lib -I/usr/include/c++/3.3.3/$host" - CXXCPP="$CXXCPP $MINGW_FLAGS" - - -} ; fi - - LTCC="gcc" - CXXFLAGS="$CXXFLAGS -LC:/GTK/lib" - CFLAGS="$CFLAGS -LC:/GTK/lib" - LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--subsystem=console -Wl,--enable-runtime-pseudo-reloc" -dnl LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--subsystem=console -Wl,--enable-runtime-pseudo-reloc" - ;; - *cygwin*) - LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols" -dnl LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--subsystem=console" - CXXFLAGS="$CXXFLAGS -I/target/include" - CFLAGS="$CFLAGS -I/target/include" - ;; - powerpc-apple*) - echo Adding mac-specific optimization flags. . . - CXXFLAGS="$CXXFLAGS $G5OPTFLAGS" - ;; -esac - - -]) - -AC_DEFUN([AC_LIBTOOL_PATCH], -[ - -if [[ "$LIBTOOL_PATCH_SED""x" != "x" ]] ; then { - printf "Patching libtool... " - cat libtool | sed "$LIBTOOL_PATCH_SED" > libtool2 - rm libtool - mv libtool2 libtool - chmod +x libtool - AC_MSG_RESULT([patched]) -} fi ; - - -]) diff --git a/synfig-studio/trunk/config/synfig.m4 b/synfig-studio/trunk/config/synfig.m4 deleted file mode 100755 index 5c9ca83..0000000 --- a/synfig-studio/trunk/config/synfig.m4 +++ /dev/null @@ -1,51 +0,0 @@ -# SYNFIG M4 Macro -# For GNU Autotools -# $Id$ -# -# By Robert B. Quattlebaum Jr. -# - -AC_DEFUN([SYNFIG_DEPS], -[ - USING_ETL(,$2) - AM_PATH_XML2(,,$2) - AC_CHECK_FUNCS([floor pow sqrt],,$2) - $1 -]) - -AC_DEFUN([USING_SYNFIG], -[ - AC_ARG_WITH(synfig-includes, - [ --with-synfig-includes Specify location of synfig headers],[ - CXXFLAGS="$CXXFLAGS -I$withval" - ]) - - AC_PATH_PROG(SYNFIG_CONFIG,synfig-config,no) - - if test "$SYNFIG_CONFIG" = "no"; then - no_SYNFIG_config="yes" - $2 - else - AC_MSG_CHECKING([if $SYNFIG_CONFIG works]) - if $SYNFIG_CONFIG --libs >/dev/null 2>&1; then - SYNFIG_VERSION="`$SYNFIG_CONFIG --version`" - AC_MSG_RESULT([yes, $SYNFIG_VERSION]) - SYNFIG_CXXFLAGS="`$SYNFIG_CONFIG --cxxflags`" - SYNFIG_CFLAGS="`$SYNFIG_CONFIG --cflags`" - SYNFIG_LIBS="`$SYNFIG_CONFIG --libs`" - CXXFLAGS="$CXXFLAGS $SYNFIG_CXXFLAGS" - AC_SUBST(SYNFIG_CXXFLAGS) - AC_SUBST(SYNFIG_LIBS) - AC_SUBST(SYNFIG_CFLAGS) - $1 - else - AC_MSG_RESULT(no) - no_SYNFIG_config="yes" - $2 - fi - fi - - SYNFIG_DEPS($1,$2) -]) - - diff --git a/synfig-studio/trunk/configure.ac b/synfig-studio/trunk/configure.ac new file mode 100755 index 0000000..ce4e74c --- /dev/null +++ b/synfig-studio/trunk/configure.ac @@ -0,0 +1,207 @@ +# $Id$ + +# -- I N I T -------------------------------------------------- + +AC_INIT([Synfig Studio],[0.61.07],[http://sourceforge.net/tracker/?group_id=144022&atid=757416],[synfigstudio]) +AC_REVISION + +AC_CONFIG_AUX_DIR(config) +AM_CONFIG_HEADER(config.h) +AC_CANONICAL_HOST +dnl AC_CANONICAL_TARGET + +AM_INIT_AUTOMAKE +AM_MAINTAINER_MODE + +API_VERSION=0.0 + +# -- V A R I A B L E S ---------------------------------------- + +SVN_REPOSITORY=http://svn.voria.com/code/synfig-studio + +# -- P R O G R A M S ------------------------------------------ + +AC_PROG_CC +AC_PROG_CXX +AC_PROG_CPP +AC_PROG_CXXCPP +AC_PROG_INSTALL + +AC_LANG_CPLUSPLUS + + +AC_ARG_DEBUG +AC_ARG_OPTIMIZATION +AC_ARG_WARNINGS +AC_ARG_PROFILE_ARCS +AC_ARG_BRANCH_PROBABILITIES +AC_ARG_PROFILING +AC_ARG_LICENSE_KEY + +AC_ARG_ENABLE(g5opt,[ + --enable-g5opt enable optimizations specific to G5 proc],[ + G5OPTFLAGS="-mpowerpc-gpopt -mno-multiple -mno-update -mcpu=970 -mtune=970 -falign-loops=16 -falign-functions=16" +], +[ + G5OPTFLAGS= +]) + +AC_WIN32_QUIRKS + +AC_LIBTOOL_WIN32_DLL +AC_LIBTOOL_DLOPEN +AC_DISABLE_STATIC +AC_ENABLE_SHARED +AC_PROG_LIBTOOL +AC_SUBST(LIBTOOL_DEPS) +AC_LIBTOOL_PATCH + + + + + +dnl AC_PROG_INTLTOOL(0.11) + +case "$host" in + *mingw* | *cygwin*) + AM_CONDITIONAL(WIN32_PKG, true) + AM_CONDITIONAL(MACOSX_PKG, false) + ;; + *darwin*) + AM_CONDITIONAL(WIN32_PKG, false) + AM_CONDITIONAL(MACOSX_PKG, true) + ;; + *) + AM_CONDITIONAL(WIN32_PKG, false) + AM_CONDITIONAL(MACOSX_PKG, false) + ;; +esac +# -- L I B R A R I E S ---------------------------------------- + +PKG_CHECK_MODULES(GTKMM, gtkmm-2.4 gthread-2.0,[],[ + AC_MSG_ERROR([ ** Gtkmm-2.4 Is a required library, aborting.]) +]) +AC_SUBST(GTKMM_CFLAGS) +AC_SUBST(GTKMM_LIBS) + +PKG_CHECK_MODULES(SYNFIG, [synfig >= 0.61.07] [ETL >= 0.04.10] sigc++-2.0,,[ + AC_MSG_ERROR([ ** Unable to set up dependent libraries (synfig >= 0.61.07, ETL >= 0.04.10)]) +]) +AC_SUBST(SYNFIG_CFLAGS) +AC_SUBST(SYNFIG_LIBS) + +windowsys="gtkmm" +AC_DEFINE(STUDIO_WINSYS_H,"gtkmm/winsys.h",[blah]) +AM_CONDITIONAL(WINDOWSYS_GTKMM,true) + +AC_ARG_WITH(userdir,[ + --with-userdir=(dirname) Relative path to user directory],[ +],[ +case "$host" in + *mingw* | *cygwin*) + with_userdir="Synfig" + ;; + *darwin*) + with_userdir="Library/Synfig" + ;; + *) + with_userdir=".synfig" + ;; +esac +]) +AC_DEFINE_UNQUOTED(SYNFIG_USER_APP_DIR,"$with_userdir",[Synfig User Data Directory]) + +# --- FMOD CHECK ------------- +AC_ARG_WITH(libfmod,[ + --with-libfmod Enable support for FMOD],[ +],[ + AC_CHECK_LIB(fmod, FSOUND_Init,[ + with_libfmod="yes" + ],[ + with_libfmod="no" + ]) +]) +if test $with_libfmod = "yes" ; then { + AM_CONDITIONAL(WITH_FMOD,true) + FMOD_LIBS="/usr/lib/libfmod.so" + AC_DEFINE(WITH_FMOD,"I'm here damnit",[blah]) +} else { + AM_CONDITIONAL(WITH_FMOD,false) + FMOD_LIBS= +} ; fi + +# -- H E A D E R S -------------------------------------------- + +AC_CHECK_HEADERS([unistd.h signal.h fcntl.h]) +AC_CHECK_HEADERS([sys/types.h sys/wait.h sys/stat.h sys/time.h sys/resource.h sys/errno.h]) + +# -- T Y P E S & S T R U C T S -------------------------------- + +# -- F U N C T I O N S ---------------------------------------- + +AC_CHECK_FUNCS([fork]) +AC_CHECK_FUNCS([kill]) +AC_CHECK_FUNCS([pipe]) +AC_CHECK_FUNCS([setpriority mkfifo stat]) + +# -- A R G U M E N T S ---------------------------------------- + +# -- O U T P U T ---------------------------------------------- + +AC_SUBST(CFLAGS) +AC_SUBST(CPPFLAGS) +AC_SUBST(CXXFLAGS) +AC_SUBST(LDFLAGS) +AC_SUBST(SVN_REPOSITORY) + +AC_SUBST(API_VERSION) + +# fmod stuff... +AC_SUBST(FMOD_LIBS) + +imageext=png +AC_SUBST(imageext) + +imagedir="${datadir}/pixmaps/synfigstudio" +AC_SUBST(imagedir) + +AC_OUTPUT( +Makefile +synfigstudio.spec +synfigstudio.desktop +synfigstudio.mime +synfigstudio.keys +synfigstudio.xml +synfigstudio-thumbnailer.schemas +src/Makefile +src/gtkmm/Makefile +src/synfigapp/Makefile +images/Makefile +win32inst.nsi +pkg-info/macosx/synfig-studio.info +) + +# -- S U M M A R Y -------------------------------------------- + +echo " +$PACKAGE_NAME v.$VERSION +Configuration Summary +- - - - - - + +Install Prefix -------------------> $prefix +Host Platform --------------------> $host +Icon Format ----------------------> $imageext +Debug Mode -----------------------> $debug +Profiling Mode -------------------> $profiling +Optimizations --------------------> $optimization +Window System --------------------> $windowsys +FMOD Enabled ---------------------> $with_libfmod + +"'$'"CXX ------------------------------> '$CXX' +"'$'"CXXFLAGS -------------------------> '$CXXFLAGS' +"'$'"LDFLAGS --------------------------> '$LDFLAGS' +"'$'"SYNFIG_CFLAGS ---------------------> '$SYNFIG_CFLAGS' +"'$'"SYNFIG_LIBS -----------------------> '$SYNFIG_LIBS' +"'$'"GTKMM_CFLAGS ---------------------> '$GTKMM_CFLAGS' +"'$'"GTKMM_LIBS -----------------------> '$GTKMM_LIBS' +" diff --git a/synfig-studio/trunk/m4/ETL.m4 b/synfig-studio/trunk/m4/ETL.m4 new file mode 100755 index 0000000..4cbd609 --- /dev/null +++ b/synfig-studio/trunk/m4/ETL.m4 @@ -0,0 +1,75 @@ +# ETL M4 Macro +# For GNU Autotools +# $Id$ +# +# By Robert B. Quattlebaum Jr. +# + +AC_DEFUN([ETL_DEPS], +[ + AC_C_BIGENDIAN + + AC_CHECK_LIB(user32, main) + AC_CHECK_LIB(kernel32, main) + AC_CHECK_LIB(pthread, main) + + AC_HEADER_STDC + + AC_CHECK_HEADERS(pthread.h) + AC_CHECK_HEADERS(sched.h) + AC_CHECK_HEADERS(sys/times.h) + AC_CHECK_HEADERS(sys/time.h) + AC_CHECK_HEADERS(unistd.h) + AC_CHECK_HEADERS(windows.h) + AC_CHECK_FUNCS([pthread_create]) + AC_CHECK_FUNCS([pthread_rwlock_init]) + AC_CHECK_FUNCS([pthread_yield]) + AC_CHECK_FUNCS([sched_yield]) + AC_CHECK_FUNCS([CreateThread]) + AC_CHECK_FUNCS([__clone]) + AC_CHECK_FUNCS([QueryPerformanceCounter]) + + AC_CHECK_FUNCS([gettimeofday]) + AC_CHECK_FUNCS([vsscanf]) + AC_CHECK_FUNCS([vsprintf]) + AC_CHECK_FUNCS([vasprintf]) + AC_CHECK_FUNCS([vsnprintf],[],[ + AC_CHECK_FUNC([_vsnprintf],[ + AC_DEFINE(vsnprintf,_vsnprintf,[define if the vsnprintf function is mangled]) + AC_DEFINE(HAVE_VSNPRINTF,1) + ]) + ]) + + $1 +]) + +AC_DEFUN([USING_ETL], +[ + AC_ARG_WITH(ETL-includes, + [ --with-ETL-includes Specify location of ETL headers],[ + CXXFLAGS="$CXXFLAGS -I$withval" + ]) + + AC_PATH_PROG(ETL_CONFIG,ETL-config,no) + + if test "$ETL_CONFIG" = "no"; then + no_ETL_config="yes" + $2 + else + AC_MSG_CHECKING([if $ETL_CONFIG works]) + if $ETL_CONFIG --libs >/dev/null 2>&1; then + ETL_VERSION="`$ETL_CONFIG --version`" + AC_MSG_RESULT([yes, $ETL_VERSION]) + CXXFLAGS="$CXXFLAGS `$ETL_CONFIG --cxxflags`" + $1 + else + AC_MSG_RESULT(no) + no_ETL_config="yes" + $2 + fi + fi + + ETL_DEPS($1,$2) +]) + + diff --git a/synfig-studio/trunk/m4/cxx_macros.m4 b/synfig-studio/trunk/m4/cxx_macros.m4 new file mode 100755 index 0000000..8fc247a --- /dev/null +++ b/synfig-studio/trunk/m4/cxx_macros.m4 @@ -0,0 +1,88 @@ +AC_DEFUN([AC_CXX_FUNCTION_NONTYPE_PARAMETERS], +[AC_CACHE_CHECK(whether the compiler supports function templates with non-type parameters, +ac_cv_cxx_function_nontype_parameters, +[AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([ +template class A {}; +template int f(const A& x) { return 0; } +],[A z; return f(z);], + ac_cv_cxx_function_nontype_parameters=yes, ac_cv_cxx_function_nontype_parameters=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_function_nontype_parameters" = yes; then + AC_DEFINE(HAVE_FUNCTION_NONTYPE_PARAMETERS,, + [define if the compiler supports function templates with non-type parameters]) +fi +]) + +AC_DEFUN([AC_CXX_NAMESPACES], +[AC_CACHE_CHECK(whether the compiler implements namespaces, +ac_cv_cxx_namespaces, +[AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([namespace Outer { namespace Inner { int i = 0; }}], + [using namespace Outer::Inner; return i;], + ac_cv_cxx_namespaces=yes, ac_cv_cxx_namespaces=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_namespaces" = yes; then + AC_DEFINE(HAVE_NAMESPACES,,[define if the compiler implements namespaces]) +fi +]) + +AC_DEFUN([AC_CXX_HAVE_COMPLEX], +[AC_CACHE_CHECK(whether the compiler has complex, +ac_cv_cxx_have_complex, +[AC_REQUIRE([AC_CXX_NAMESPACES]) + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([#include +#ifdef HAVE_NAMESPACES +using namespace std; +#endif],[complex a; complex b; return 0;], + ac_cv_cxx_have_complex=yes, ac_cv_cxx_have_complex=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_have_complex" = yes; then + AC_DEFINE(HAVE_COMPLEX,,[define if the compiler has complex]) +fi +]) + +AC_DEFUN([AC_CXX_HAVE_SSTREAM], +[AC_CACHE_CHECK(whether the compiler has stringstream, +ac_cv_cxx_have_sstream, +[AC_REQUIRE([AC_CXX_NAMESPACES]) + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([#include +#ifdef HAVE_NAMESPACES +using namespace std; +#endif],[stringstream message; message << "Hello"; return 0;], + ac_cv_cxx_have_sstream=yes, ac_cv_cxx_have_sstream=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_have_sstream" = yes; then + AC_DEFINE(HAVE_SSTREAM,,[define if the compiler has stringstream]) +fi +]) + +AC_DEFUN([AC_CXX_MUTABLE], +[AC_CACHE_CHECK(whether the compiler supports the mutable keyword, +ac_cv_cxx_mutable, +[AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([ +class A { mutable int i; + public: + int f (int n) const { i = n; return i; } + }; +],[A a; return a.f (1);], + ac_cv_cxx_mutable=yes, ac_cv_cxx_mutable=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_mutable" = yes; then + AC_DEFINE(HAVE_MUTABLE,,[define if the compiler supports the mutable keyword]) +fi +]) + diff --git a/synfig-studio/trunk/m4/gnome.m4 b/synfig-studio/trunk/m4/gnome.m4 new file mode 100755 index 0000000..bb96b4b --- /dev/null +++ b/synfig-studio/trunk/m4/gnome.m4 @@ -0,0 +1,407 @@ +# gnome-common.m4 +# + +dnl GNOME_COMMON_INIT + +AC_DEFUN([GNOME_COMMON_INIT], +[ + AC_CACHE_VAL(ac_cv_gnome_aclocal_dir, + [ac_cv_gnome_aclocal_dir="$GNOME_COMMON_MACROS_DIR"]) + AC_CACHE_VAL(ac_cv_gnome_aclocal_flags, + [ac_cv_gnome_aclocal_flags="$ACLOCAL_FLAGS"]) + GNOME_ACLOCAL_DIR="$ac_cv_gnome_aclocal_dir" + GNOME_ACLOCAL_FLAGS="$ac_cv_gnome_aclocal_flags" + AC_SUBST(GNOME_ACLOCAL_DIR) + AC_SUBST(GNOME_ACLOCAL_FLAGS) + + ACLOCAL="$ACLOCAL $GNOME_ACLOCAL_FLAGS" + + AM_CONDITIONAL(INSIDE_GNOME_DOCU, false) +]) + +AC_DEFUN([GNOME_GTKDOC_CHECK], +[ + AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false) + AM_CONDITIONAL(HAVE_GTK_DOC, $GTKDOC) + AC_SUBST(HAVE_GTK_DOC) + + dnl Let people disable the gtk-doc stuff. + AC_ARG_ENABLE(gtk-doc, [ --enable-gtk-doc Use gtk-doc to build documentation [default=auto]], enable_gtk_doc="$enableval", enable_gtk_doc=auto) + + if test x$enable_gtk_doc = xauto ; then + if test x$GTKDOC = xtrue ; then + enable_gtk_doc=yes + else + enable_gtk_doc=no + fi + fi + + dnl NOTE: We need to use a separate automake conditional for this + dnl to make this work with the tarballs. + AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes) +]) + +AC_DEFUN([GNOME_DEBUG_CHECK], +[ + AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]], enable_debug="$enableval", enable_debug=no) + + if test x$enable_debug = xyes ; then + AC_DEFINE(GNOME_ENABLE_DEBUG) + fi +]) + +# Define a conditional. + +AC_DEFUN([AM_CONDITIONAL], +[AC_SUBST($1_TRUE) +AC_SUBST($1_FALSE) +if $2; then + $1_TRUE= + $1_FALSE='#' +else + $1_TRUE='#' + $1_FALSE= +fi]) + + +dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not) +dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page +dnl also defines GSTUFF_PKG_ERRORS on error +AC_DEFUN([PKG_CHECK_MODULES], [ + succeeded=no + + if test -z "$PKG_CONFIG"; then + AC_PATH_PROG(PKG_CONFIG, pkg-config, no) + fi + + if test "$PKG_CONFIG" = "no" ; then + echo "*** The pkg-config script could not be found. Make sure it is" + echo "*** in your path, or set the PKG_CONFIG environment variable" + echo "*** to the full path to pkg-config." + echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config." + else + PKG_CONFIG_MIN_VERSION=0.9.0 + if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then + AC_MSG_CHECKING(for $2) + + if $PKG_CONFIG --exists "$2" ; then + AC_MSG_RESULT(yes) + succeeded=yes + + AC_MSG_CHECKING($1_CFLAGS) + $1_CFLAGS=`$PKG_CONFIG --cflags "$2"` + AC_MSG_RESULT($$1_CFLAGS) + + AC_MSG_CHECKING($1_LIBS) + $1_LIBS=`$PKG_CONFIG --libs "$2"` + AC_MSG_RESULT($$1_LIBS) + else + $1_CFLAGS="" + $1_LIBS="" + ## If we have a custom action on failure, don't print errors, but + ## do set a variable so people can do so. + $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"` + ifelse([$4], ,echo $$1_PKG_ERRORS,) + fi + + AC_SUBST($1_CFLAGS) + AC_SUBST($1_LIBS) + else + echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." + echo "*** See http://www.freedesktop.org/software/pkgconfig" + fi + fi + + if test $succeeded = yes; then + ifelse([$3], , :, [$3]) + else + ifelse([$4], , AC_MSG_ERROR([Library requirements ($2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.]), [$4]) + fi +]) + + + +# Macro to add for using GNU gettext. +# Ulrich Drepper , 1995, 1996 +# +# Modified to never use included libintl. +# Owen Taylor , 12/15/1998 +# +# +# This file can be copied and used freely without restrictions. It can +# be used in projects which are not available under the GNU Public License +# but which still want to provide support for the GNU gettext functionality. +# Please note that the actual code is *not* freely available. +# +# +# If you make changes to this file, you MUST update the copy in +# acinclude.m4. [ aclocal dies on duplicate macros, so if +# we run 'aclocal -I macros/' then we'll run into problems +# once we've installed glib-gettext.m4 :-( ] +# + +AC_DEFUN([AM_GLIB_LC_MESSAGES], + [if test $ac_cv_header_locale_h = yes; then + AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, + [AC_TRY_LINK([#include ], [return LC_MESSAGES], + am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) + if test $am_cv_val_LC_MESSAGES = yes; then + AC_DEFINE(HAVE_LC_MESSAGES, 1, + [Define if your file defines LC_MESSAGES.]) + fi + fi]) + +dnl AM_GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, +dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) +AC_DEFUN([AM_GLIB_PATH_PROG_WITH_TEST], +[# Extract the first word of "$2", so it can be a program name with args. +set dummy $2; ac_word=[$]2 +AC_MSG_CHECKING([for $ac_word]) +AC_CACHE_VAL(ac_cv_path_$1, +[case "[$]$1" in + /*) + ac_cv_path_$1="[$]$1" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in ifelse([$5], , $PATH, [$5]); do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if [$3]; then + ac_cv_path_$1="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" +dnl If no 4th arg is given, leave the cache variable unset, +dnl so AC_PATH_PROGS will keep looking. +ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" +])dnl + ;; +esac])dnl +$1="$ac_cv_path_$1" +if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then + AC_MSG_RESULT([$]$1) +else + AC_MSG_RESULT(no) +fi +AC_SUBST($1)dnl +]) + +# serial 5 + +AC_DEFUN([AM_GLIB_WITH_NLS], + dnl NLS is obligatory + [USE_NLS=yes + AC_SUBST(USE_NLS) + + dnl Figure out what method + nls_cv_force_use_gnu_gettext="no" + + nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" + if test "$nls_cv_force_use_gnu_gettext" != "yes"; then + dnl User does not insist on using GNU NLS library. Figure out what + dnl to use. If gettext or catgets are available (in this order) we + dnl use this. Else we have to fall back to GNU NLS library. + dnl catgets is only used if permitted by option --with-catgets. + nls_cv_header_intl= + nls_cv_header_libgt= + CATOBJEXT=NONE + XGETTEXT=: + + AC_CHECK_HEADER(libintl.h, + [AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc, + [AC_TRY_LINK([#include ], [return (int) dgettext ("","")], + gt_cv_func_dgettext_libc=yes, gt_cv_func_dgettext_libc=no)]) + + gt_cv_func_dgettext_libintl="no" + libintl_extra_libs="" + + if test "$gt_cv_func_dgettext_libc" != "yes" ; then + AC_CHECK_LIB(intl, bindtextdomain, + [AC_CHECK_LIB(intl, dgettext, + gt_cv_func_dgettext_libintl=yes)]) + + if test "$gt_cv_func_dgettext_libc" != "yes" ; then + AC_MSG_CHECKING([if -liconv is needed to use gettext]) + AC_MSG_RESULT([]) + AC_CHECK_LIB(intl, dcgettext, + [gt_cv_func_dgettext_libintl=yes + libintl_extra_libs=-liconv], + :,-liconv) + fi + fi + + if test "$gt_cv_func_dgettext_libintl" = "yes"; then + LIBS="$LIBS -lintl $libintl_extra_libs"; + fi + + if test "$gt_cv_func_dgettext_libc" = "yes" \ + || test "$gt_cv_func_dgettext_libintl" = "yes"; then + AC_DEFINE(HAVE_GETTEXT,1, + [Define if the GNU gettext() function is already present or preinstalled.]) + AM_GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, + [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl + if test "$MSGFMT" != "no"; then + AC_CHECK_FUNCS(dcgettext) + AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + AM_GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, + [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :) + AC_TRY_LINK(, [extern int _nl_msg_cat_cntr; + return _nl_msg_cat_cntr], + [CATOBJEXT=.gmo + DATADIRNAME=share], + [CATOBJEXT=.mo + DATADIRNAME=lib]) + INSTOBJEXT=.mo + fi + fi + + # Added by Martin Baulig 12/15/98 for libc5 systems + if test "$gt_cv_func_dgettext_libc" != "yes" \ + && test "$gt_cv_func_dgettext_libintl" = "yes"; then + INTLLIBS="-lintl $libintl_extra_libs" + LIBS=`echo $LIBS | sed -e 's/-lintl//'` + fi + ]) + + if test "$CATOBJEXT" = "NONE"; then + dnl Neither gettext nor catgets in included in the C library. + dnl Fall back on GNU gettext library. + nls_cv_use_gnu_gettext=yes + fi + fi + + if test "$nls_cv_use_gnu_gettext" != "yes"; then + AC_DEFINE(ENABLE_NLS, 1, + [always defined to indicate that i18n is enabled]) + else + dnl Unset this variable since we use the non-zero value as a flag. + CATOBJEXT= + fi + + dnl Test whether we really found GNU xgettext. + if test "$XGETTEXT" != ":"; then + dnl If it is no GNU xgettext we define it as : so that the + dnl Makefiles still can work. + if $XGETTEXT --omit-header /dev/null 2> /dev/null; then + : ; + else + AC_MSG_RESULT( + [found xgettext program is not GNU xgettext; ignore it]) + XGETTEXT=":" + fi + fi + + # We need to process the po/ directory. + POSUB=po + + AC_OUTPUT_COMMANDS( + [case "$CONFIG_FILES" in *po/Makefile.in*) + sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile + esac]) + + dnl These rules are solely for the distribution goal. While doing this + dnl we only have to keep exactly one list of the available catalogs + dnl in configure.in. + for lang in $ALL_LINGUAS; do + GMOFILES="$GMOFILES $lang.gmo" + POFILES="$POFILES $lang.po" + done + + dnl Make all variables we use known to autoconf. + AC_SUBST(CATALOGS) + AC_SUBST(CATOBJEXT) + AC_SUBST(DATADIRNAME) + AC_SUBST(GMOFILES) + AC_SUBST(INSTOBJEXT) + AC_SUBST(INTLDEPS) + AC_SUBST(INTLLIBS) + AC_SUBST(INTLOBJS) + AC_SUBST(POFILES) + AC_SUBST(POSUB) + ]) + +AC_DEFUN([AM_GLIB_GNU_GETTEXT], + [AC_REQUIRE([AC_PROG_MAKE_SET])dnl + AC_REQUIRE([AC_PROG_CC])dnl + AC_REQUIRE([AC_PROG_RANLIB])dnl + AC_REQUIRE([AC_HEADER_STDC])dnl + AC_REQUIRE([AC_C_CONST])dnl + AC_REQUIRE([AC_C_INLINE])dnl + AC_REQUIRE([AC_TYPE_OFF_T])dnl + AC_REQUIRE([AC_TYPE_SIZE_T])dnl + AC_REQUIRE([AC_FUNC_ALLOCA])dnl + AC_REQUIRE([AC_FUNC_MMAP])dnl + + AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h string.h \ +unistd.h sys/param.h]) + AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp \ +strdup __argz_count __argz_stringify __argz_next]) + + AM_GLIB_LC_MESSAGES + AM_GLIB_WITH_NLS + + if test "x$CATOBJEXT" != "x"; then + if test "x$ALL_LINGUAS" = "x"; then + LINGUAS= + else + AC_MSG_CHECKING(for catalogs to be installed) + NEW_LINGUAS= + for lang in ${LINGUAS=$ALL_LINGUAS}; do + case "$ALL_LINGUAS" in + *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; + esac + done + LINGUAS=$NEW_LINGUAS + AC_MSG_RESULT($LINGUAS) + fi + + dnl Construct list of names of catalog files to be constructed. + if test -n "$LINGUAS"; then + for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done + fi + fi + + dnl Determine which catalog format we have (if any is needed) + dnl For now we know about two different formats: + dnl Linux libc-5 and the normal X/Open format + test -d po || mkdir po + if test "$CATOBJEXT" = ".cat"; then + AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen) + + dnl Transform the SED scripts while copying because some dumb SEDs + dnl cannot handle comments. + sed -e '/^#/d' $srcdir/po/$msgformat-msg.sed > po/po2msg.sed + fi + + dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly + dnl find the mkinstalldirs script in another subdir but ($top_srcdir). + dnl Try to locate is. + MKINSTALLDIRS= + if test -n "$ac_aux_dir"; then + MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" + fi + if test -z "$MKINSTALLDIRS"; then + MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" + fi + AC_SUBST(MKINSTALLDIRS) + + dnl Generate list of files to be processed by xgettext which will + dnl be included in po/Makefile. + test -d po || mkdir po + if test "x$srcdir" != "x."; then + if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then + posrcprefix="$srcdir/" + else + posrcprefix="../$srcdir/" + fi + else + posrcprefix="../" + fi + rm -f po/POTFILES + sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ + < $srcdir/po/POTFILES.in > po/POTFILES + ]) + diff --git a/synfig-studio/trunk/m4/libxml.m4 b/synfig-studio/trunk/m4/libxml.m4 new file mode 100755 index 0000000..8b0e006 --- /dev/null +++ b/synfig-studio/trunk/m4/libxml.m4 @@ -0,0 +1,389 @@ +# Configure paths for LIBXML2 +# Toshio Kuratomi 2001-04-21 +# Adapted from: +# Configure paths for GLIB +# Owen Taylor 97-11-3 + +dnl AM_PATH_XML([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) +dnl Test for XML, and define XML_CFLAGS and XML_LIBS +dnl +AC_DEFUN([AM_PATH_XML],[ +AC_ARG_WITH(xml-prefix, + [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], + xml_config_prefix="$withval", xml_config_prefix="") +AC_ARG_WITH(xml-exec-prefix, + [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], + xml_config_exec_prefix="$withval", xml_config_exec_prefix="") +AC_ARG_ENABLE(xmltest, + [ --disable-xmltest Do not try to compile and run a test LIBXML program],, + enable_xmltest=yes) + + if test x$xml_config_exec_prefix != x ; then + xml_config_args="$xml_config_args --exec-prefix=$xml_config_exec_prefix" + if test x${XML_CONFIG+set} != xset ; then + XML_CONFIG=$xml_config_exec_prefix/bin/xml-config + fi + fi + if test x$xml_config_prefix != x ; then + xml_config_args="$xml_config_args --prefix=$xml_config_prefix" + if test x${XML_CONFIG+set} != xset ; then + XML_CONFIG=$xml_config_prefix/bin/xml-config + fi + fi + + AC_PATH_PROG(XML_CONFIG, xml-config, no) + min_xml_version=ifelse([$1], ,1.0.0,[$1]) + AC_MSG_CHECKING(for libxml - version >= $min_xml_version) + no_xml="" + if test "$XML_CONFIG" = "no" ; then + no_xml=yes + else + XML_CFLAGS=`$XML_CONFIG $xml_config_args --cflags` + XML_LIBS=`$XML_CONFIG $xml_config_args --libs` + xml_config_major_version=`$XML_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` + xml_config_minor_version=`$XML_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` + xml_config_micro_version=`$XML_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` + if test "x$enable_xmltest" = "xyes" ; then + ac_save_CFLAGS="$CFLAGS" + ac_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $XML_CFLAGS" + LIBS="$XML_LIBS $LIBS" +dnl +dnl Now check if the installed libxml is sufficiently new. +dnl (Also sanity checks the results of xml-config to some extent) +dnl + rm -f conf.xmltest + AC_TRY_RUN([ +#include +#include +#include +#include + +int +main() +{ + int xml_major_version, xml_minor_version, xml_micro_version; + int major, minor, micro; + char *tmp_version; + int tmp_int_version; + + system("touch conf.xmltest"); + + /* Capture xml-config output via autoconf/configure variables */ + /* HP/UX 9 (%@#!) writes to sscanf strings */ + tmp_version = (char *)strdup("$min_xml_version"); + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + printf("%s, bad version string from xml-config\n", "$min_xml_version"); + exit(1); + } + free(tmp_version); + + /* Capture the version information from the header files */ + tmp_int_version = LIBXML_VERSION; + xml_major_version=tmp_int_version / 10000; + xml_minor_version=(tmp_int_version - xml_major_version * 10000) / 100; + xml_micro_version=(tmp_int_version - xml_minor_version * 100 - xml_major_version * 10000); + + /* Compare xml-config output to the libxml headers */ + if ((xml_major_version != $xml_config_major_version) || + (xml_minor_version != $xml_config_minor_version) +#if 0 + || +/* The last released version of libxml-1.x has an incorrect micro version in + * the header file so neither the includes nor the library will match the + * micro_version to the output of xml-config + */ + (xml_micro_version != $xml_config_micro_version) +#endif + ) + + { + printf("*** libxml header files (version %d.%d.%d) do not match\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** xml-config (version %d.%d.%d)\n", + $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); + return 1; + } +/* Compare the headers to the library to make sure we match */ + /* Less than ideal -- doesn't provide us with return value feedback, + * only exits if there's a serious mismatch between header and library. + */ + LIBXML_TEST_VERSION; + + /* Test that the library is greater than our minimum version */ + if (($xml_config_major_version > major) || + (($xml_config_major_version == major) && ($xml_config_minor_version > minor)) || + (($xml_config_major_version == major) && ($xml_config_minor_version == minor) && + ($xml_config_micro_version >= micro))) + { + return 0; + } + else + { + printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", + major, minor, micro); + printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); + printf("***\n"); + printf("*** If you have already installed a sufficiently new version, this error\n"); + printf("*** probably means that the wrong copy of the xml-config shell script is\n"); + printf("*** being found. The easiest way to fix this is to remove the old version\n"); + printf("*** of LIBXML, but you can also set the XML_CONFIG environment to point to the\n"); + printf("*** correct copy of xml-config. (In this case, you will have to\n"); + printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); + printf("*** so that the correct libraries are found at run-time))\n"); + } + return 1; +} +],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + if test "x$no_xml" = x ; then + AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) + ifelse([$2], , :, [$2]) + else + AC_MSG_RESULT(no) + if test "$XML_CONFIG" = "no" ; then + echo "*** The xml-config script installed by LIBXML could not be found" + echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" + echo "*** your path, or set the XML_CONFIG environment variable to the" + echo "*** full path to xml-config." + else + if test -f conf.xmltest ; then + : + else + echo "*** Could not run libxml test program, checking why..." + CFLAGS="$CFLAGS $XML_CFLAGS" + LIBS="$LIBS $XML_LIBS" + AC_TRY_LINK([ +#include +#include +], [ LIBXML_TEST_VERSION; return 0;], + [ echo "*** The test program compiled, but did not run. This usually means" + echo "*** that the run-time linker is not finding LIBXML or finding the wrong" + echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" + echo "*** to the installed location Also, make sure you have run ldconfig if that" + echo "*** is required on your system" + echo "***" + echo "*** If you have an old version installed, it is best to remove it, although" + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], + [ echo "*** The test program failed to compile or link. See the file config.log for the" + echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" + echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" + echo "*** may want to edit the xml-config script: $XML_CONFIG" ]) + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + XML_CFLAGS="" + XML_LIBS="" + ifelse([$3], , :, [$3]) + fi + AC_SUBST(XML_CFLAGS) + AC_SUBST(XML_LIBS) + rm -f conf.xmltest +]) + +# Configure paths for LIBXML2 +# Toshio Kuratomi 2001-04-21 +# Adapted from: +# Configure paths for GLIB +# Owen Taylor 97-11-3 + +dnl AM_PATH_XML2([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) +dnl Test for XML, and define XML_CFLAGS and XML_LIBS +dnl +AC_DEFUN([AM_PATH_XML2],[ +AC_ARG_WITH(xml-prefix, + [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], + xml_config_prefix="$withval", xml_config_prefix="") +AC_ARG_WITH(xml-exec-prefix, + [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], + xml_config_exec_prefix="$withval", xml_config_exec_prefix="") +AC_ARG_ENABLE(xmltest, + [ --disable-xmltest Do not try to compile and run a test LIBXML program],, + enable_xmltest=yes) + + if test x$xml_config_exec_prefix != x ; then + xml_config_args="$xml_config_args --exec-prefix=$xml_config_exec_prefix" + if test x${XML2_CONFIG+set} != xset ; then + XML2_CONFIG=$xml_config_exec_prefix/bin/xml2-config + fi + fi + if test x$xml_config_prefix != x ; then + xml_config_args="$xml_config_args --prefix=$xml_config_prefix" + if test x${XML2_CONFIG+set} != xset ; then + XML2_CONFIG=$xml_config_prefix/bin/xml2-config + fi + fi + + AC_PATH_PROG(XML2_CONFIG, xml2-config, no) + min_xml_version=ifelse([$1], ,2.0.0,[$1]) + AC_MSG_CHECKING(for libxml - version >= $min_xml_version) + no_xml="" + if test "$XML2_CONFIG" = "no" ; then + no_xml=yes + else + XML_CFLAGS=`$XML2_CONFIG $xml_config_args --cflags` + XML_LIBS=`$XML2_CONFIG $xml_config_args --libs` + xml_config_major_version=`$XML2_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` + xml_config_minor_version=`$XML2_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` + xml_config_micro_version=`$XML2_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` + if test "x$enable_xmltest" = "xyes" ; then + ac_save_CFLAGS="$CFLAGS" + ac_save_CXXFLAGS="$CXXFLAGS" + ac_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $XML_CFLAGS" + CXXFLAGS="$CXXFLAGS $XML_CFLAGS" + LIBS="$XML_LIBS $LIBS" +dnl +dnl Now check if the installed libxml is sufficiently new. +dnl (Also sanity checks the results of xml2-config to some extent) +dnl + rm -f conf.xmltest + AC_TRY_RUN([ +#include +#include +#include +#include + +int +main() +{ + int xml_major_version, xml_minor_version, xml_micro_version; + int major, minor, micro; + char *tmp_version; + + system("touch conf.xmltest"); + + /* Capture xml2-config output via autoconf/configure variables */ + /* HP/UX 9 (%@#!) writes to sscanf strings */ + tmp_version = (char *)strdup("$min_xml_version"); + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + printf("%s, bad version string from xml2-config\n", "$min_xml_version"); + exit(1); + } + free(tmp_version); + + /* Capture the version information from the header files */ + tmp_version = (char *)strdup(LIBXML_DOTTED_VERSION); + if (sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) { + printf("%s, bad version string from libxml includes\n", "LIBXML_DOTTED_VERSION"); + exit(1); + } + free(tmp_version); + + /* Compare xml2-config output to the libxml headers */ + if ((xml_major_version != $xml_config_major_version) || + (xml_minor_version != $xml_config_minor_version) || + (xml_micro_version != $xml_config_micro_version)) + { + printf("*** libxml header files (version %d.%d.%d) do not match\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** xml2-config (version %d.%d.%d)\n", + $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); + return 1; + } +/* Compare the headers to the library to make sure we match */ + /* Less than ideal -- doesn't provide us with return value feedback, + * only exits if there's a serious mismatch between header and library. + */ + LIBXML_TEST_VERSION; + + /* Test that the library is greater than our minimum version */ + if ((xml_major_version > major) || + ((xml_major_version == major) && (xml_minor_version > minor)) || + ((xml_major_version == major) && (xml_minor_version == minor) && + (xml_micro_version >= micro))) + { + return 0; + } + else + { + printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", + major, minor, micro); + printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); + printf("***\n"); + printf("*** If you have already installed a sufficiently new version, this error\n"); + printf("*** probably means that the wrong copy of the xml2-config shell script is\n"); + printf("*** being found. The easiest way to fix this is to remove the old version\n"); + printf("*** of LIBXML, but you can also set the XML2_CONFIG environment to point to the\n"); + printf("*** correct copy of xml2-config. (In this case, you will have to\n"); + printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); + printf("*** so that the correct libraries are found at run-time))\n"); + } + return 1; +} +],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) + CFLAGS="$ac_save_CFLAGS" + CXXFLAGS="$ac_save_CXXFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + if test "x$no_xml" = x ; then + AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) + ifelse([$2], , :, [$2]) + else + AC_MSG_RESULT(no) + if test "$XML2_CONFIG" = "no" ; then + echo "*** The xml2-config script installed by LIBXML could not be found" + echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" + echo "*** your path, or set the XML2_CONFIG environment variable to the" + echo "*** full path to xml2-config." + else + if test -f conf.xmltest ; then + : + else + echo "*** Could not run libxml test program, checking why..." + CFLAGS="$CFLAGS $XML_CFLAGS" + CXXFLAGS="$CXXFLAGS $XML_CFLAGS" + LIBS="$LIBS $XML_LIBS" + AC_TRY_LINK([ +#include +#include +], [ LIBXML_TEST_VERSION; return 0;], + [ echo "*** The test program compiled, but did not run. This usually means" + echo "*** that the run-time linker is not finding LIBXML or finding the wrong" + echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" + echo "*** to the installed location Also, make sure you have run ldconfig if that" + echo "*** is required on your system" + echo "***" + echo "*** If you have an old version installed, it is best to remove it, although" + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], + [ echo "*** The test program failed to compile or link. See the file config.log for the" + echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" + echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" + echo "*** may want to edit the xml2-config script: $XML2_CONFIG" ]) + CFLAGS="$ac_save_CFLAGS" + CXXFLAGS="$ac_save_CXXFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + XML_CFLAGS="" + XML_LIBS="" + $3 + + + ifelse([$3], , :, [$3]) + fi + AC_SUBST(XML_CFLAGS) + AC_SUBST(XML_LIBS) + rm -f conf.xmltest +]) diff --git a/synfig-studio/trunk/m4/subs.m4 b/synfig-studio/trunk/m4/subs.m4 new file mode 100755 index 0000000..7815530 --- /dev/null +++ b/synfig-studio/trunk/m4/subs.m4 @@ -0,0 +1,277 @@ + +## AC_ARG_WARNINGS() +## +## Provide the --enable-warnings configure argument, set to 'minimum' +## by default. +## +AC_DEFUN([AC_ARG_WARNINGS], +[ + AC_ARG_ENABLE([warnings], + [ --enable-warnings=[[none|minimum|maximum|hardcore]] + Control compiler pickyness. [[default=maximum]]], + [gtkmm_enable_warnings="$enableval"], + gtkmm_enable_warnings="maximum") + + AC_MSG_CHECKING([for compiler warning flags to use]) + + gtkmm_warning_flags='' + + # -W is now known as -Wextra, but that's not known by gcc 2 or 3 + case "$gtkmm_enable_warnings" in + none|no) gtkmm_warning_flags='';; + minimum|yes) gtkmm_warning_flags='-Wall -Wno-unused-parameter';; + maximum) gtkmm_warning_flags='-W -Wall -Wno-unused-parameter';; + hardcore) gtkmm_warning_flags='-W -Wall -Werror -Wno-unused-parameter';; + esac + + gtkmm_use_flags='' + + if test "x$gtkmm_warning_flags" != "x" + then + echo 'int foo() { return 0; }' > conftest.cc + + for flag in $gtkmm_warning_flags + do + # Test whether the compiler accepts the flag. GCC doesn't bail + # out when given an unsupported flag but prints a warning, so + # check the compiler output instead. + gtkmm_cxx_out="`$CXX $flag -c conftest.cc 2>&1`" + rm -f conftest.$OBJEXT + test "x${gtkmm_cxx_out}" = "x" && \ + gtkmm_use_flags="${gtkmm_use_flags:+$gtkmm_use_flags }$flag" + done + + rm -f conftest.cc + gtkmm_cxx_out='' + fi + + if test "x$gtkmm_use_flags" != "x" + then + for flag in $gtkmm_use_flags + do + case " $CXXFLAGS " in + *" $flag "*) ;; # don't add flags twice + *) CXXFLAGS="${CXXFLAGS:+$CXXFLAGS }$flag";; + esac + done + else + gtkmm_use_flags='none' + fi + + AC_MSG_RESULT([$gtkmm_use_flags]) +]) + + + + +AC_DEFUN([AC_ARG_DEBUG], +[ + AC_MSG_CHECKING([for debug flags]) + + AC_ARG_ENABLE(debug,[ --enable-debug Build in debugging mode],[ + debug=$enableval + ],[ + debug="no" + ]) + debug_flags='' + + case "$debug" in + yes) + debug_flags="-D_DEBUG -g" + ;; + half) + debug_flags="-DNDEBUG -g" + ;; + no|*) + debug_flags="-DNDEBUG -Wno-deprecated" + ;; + esac + + + CXXFLAGS="`echo $CXXFLAGS | sed s:-g::` $debug_flags" + CFLAGS="`echo $CFLAGS | sed s:-g::` $debug_flags" + + AC_MSG_RESULT([$debug_flags]) +]) + + + + +AC_DEFUN([AC_ARG_OPTIMIZATION], +[ + AC_MSG_CHECKING([for optimization flags]) + + AC_ARG_ENABLE(optimization,[ --enable-optimization=[[0,1,2,3,4]] Select optimization level (default=2)],[ + optimization=$enableval + ],[ + optimization="2" + ]) + optimization_flags='' + case "$optimization" in + 0|no) optimization_flags="-O0";; + 1) optimization_flags="-O1";; + 2|yes) optimization_flags="-O2";; + pass1) optimization_flags="-O2 -fprofile-arcs";; + pass2) optimization_flags="-O2 -fbranch-probabilities";; + 3) optimization_flags="-O3";; + *) optimization_flags="-O4";; + esac + CXXFLAGS="`echo $CXXFLAGS | sed 's:-O.::g'` $optimization_flags" + CFLAGS="`echo $CFLAGS | sed 's:-O.::g'` $optimization_flags" + AC_MSG_RESULT([$optimization_flags]) +]) + +AC_DEFUN([AC_ARG_PROFILE_ARCS], +[ + AC_MSG_CHECKING([for arc profiling]) + + AC_ARG_ENABLE(profile-arcs,[ --enable-profile-arcs Enable arc profiling],[ + profile_arcs=$enableval + ],[ + profile_arcs=no + ]) + + if test $profile_arcs = "yes" ; then { + CXXFLAGS="$CXXFLAGS -fprofile-arcs"; + CFLAGS="$CFLAGS -fprofile-arcs"; + } ; fi + + AC_MSG_RESULT([$profile_arcs]) +]) + +AC_DEFUN([AC_ARG_BRANCH_PROBABILITIES], +[ + AC_MSG_CHECKING([for branch-probabilities]) + + AC_ARG_ENABLE(branch-probabilities,[ --enable-branch-probabilities Enable branch-probabilities],[ + branch_probabilities=$enableval + ],[ + branch_probabilities=no + ]) + + if test $branch_probabilities = "yes" ; then { + CXXFLAGS="$CXXFLAGS -fbranch-probabilities"; + CFLAGS="$CFLAGS -fbranch-probabilities"; + } ; fi + + AC_MSG_RESULT([$branch_probabilities]) +]) + +AC_DEFUN([AC_ARG_PROFILING], +[ + AC_MSG_CHECKING([for profiling]) + + AC_ARG_ENABLE(profiling,[ --enable-profiling Enable profiling using gprof],[ + profiling=$enableval + ],[ + profiling=no + ]) + + if test $profiling = "yes" ; then { + CFLAGS="$CFLAGS -pg"; + CXXFLAGS="$CXXFLAGS -pg"; + LDFLAGS="$LDFLAGS -pg"; + LIBS="$LIBS"; + } ; fi + + AC_MSG_RESULT([$profiling]) +]) + +AC_DEFUN([AC_ARG_TIMELIMIT], +[ + AC_ARG_ENABLE(timelimit,[ --enable-timelimit=[[days]] Set number of usable days(default=forever)],[ + death_time=$((`date +%s`+$enableval*60*60*24)) + AC_DEFINE_UNQUOTED(DEATH_TIME,$death_time, [ Describes the time at which the library will stop working ] ) + ], + [ + death_time="no" + ]) +]) + +AC_DEFUN([AC_ARG_LICENSE_KEY], +[ + AC_ARG_ENABLE(license_key,[ --enable-license-key Turn on license key requirement],[ + AC_DEFINE(LICENSE_KEY_REQUIRED,, [ Enables license key checks ] ) + ], + [ + license_key="no" + ]) +]) + +AC_DEFUN([AC_ARG_TIMELIMIT], +[ + AC_ARG_ENABLE(timelimit,[ --enable-timelimit=[[days]] Set number of usable days(default=forever)],[ + death_time=$((`date +%s`+$enableval*60*60*24)) + AC_DEFINE_UNQUOTED(DEATH_TIME,$death_time, [ Describes the time at which the library will stop working ] ) + ], + [ + death_time="no" + ]) +]) + +MINGW_FLAGS="-mno-cygwin" + + +AC_DEFUN([AC_WIN32_QUIRKS], +[ + +case "$host" in + *mingw*) + AC_MSG_CHECKING([the flavor of the compiler]) + if ( $CC --version | grep -q mingw ) ; then { + AC_MSG_RESULT([compiler is mingw special]) + LIBTOOL_PATCH_SED=" + s/dir=\"\$absdir\"/dir=\`cygpath -d -m \"\$absdir\"\`/; + s/absdir=\`cd \"\$dir\" && pwd\`/absdir=\`cygpath -d -m \"\$dir\"\`/; + s/# We need an absolute path/dir=\`cygpath -d -m \"\$dir\"\` # We need an absolute path/; + s- /usr/lib- C:/mingw/lib-g; + s-\"/lib -\"C:/mingw/lib -g; + s- /lib/ - -g; + "; + sys_lib_dlsearch_path_spec="C:/mingw/lib" + ac_default_prefix=`cygpath -d -m "$ac_default_prefix"`; + } else { + AC_MSG_RESULT([compiler is cygwin stock, adding -mno-cygwin]) + CPP="$CPP $MINGW_FLAGS" + CC="$CC $MINGW_FLAGS" + CXX="$CXX $MINGW_FLAGS -L/usr/$host/lib -I/usr/include/c++/3.3.3/$host" + CXXCPP="$CXXCPP $MINGW_FLAGS" + + +} ; fi + + LTCC="gcc" + CXXFLAGS="$CXXFLAGS -LC:/GTK/lib" + CFLAGS="$CFLAGS -LC:/GTK/lib" + LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--subsystem=console -Wl,--enable-runtime-pseudo-reloc" +dnl LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--subsystem=console -Wl,--enable-runtime-pseudo-reloc" + ;; + *cygwin*) + LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols" +dnl LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--subsystem=console" + CXXFLAGS="$CXXFLAGS -I/target/include" + CFLAGS="$CFLAGS -I/target/include" + ;; + powerpc-apple*) + echo Adding mac-specific optimization flags. . . + CXXFLAGS="$CXXFLAGS $G5OPTFLAGS" + ;; +esac + + +]) + +AC_DEFUN([AC_LIBTOOL_PATCH], +[ + +if [[ "$LIBTOOL_PATCH_SED""x" != "x" ]] ; then { + printf "Patching libtool... " + cat libtool | sed "$LIBTOOL_PATCH_SED" > libtool2 + rm libtool + mv libtool2 libtool + chmod +x libtool + AC_MSG_RESULT([patched]) +} fi ; + + +]) diff --git a/synfig-studio/trunk/m4/synfig.m4 b/synfig-studio/trunk/m4/synfig.m4 new file mode 100755 index 0000000..5c9ca83 --- /dev/null +++ b/synfig-studio/trunk/m4/synfig.m4 @@ -0,0 +1,51 @@ +# SYNFIG M4 Macro +# For GNU Autotools +# $Id$ +# +# By Robert B. Quattlebaum Jr. +# + +AC_DEFUN([SYNFIG_DEPS], +[ + USING_ETL(,$2) + AM_PATH_XML2(,,$2) + AC_CHECK_FUNCS([floor pow sqrt],,$2) + $1 +]) + +AC_DEFUN([USING_SYNFIG], +[ + AC_ARG_WITH(synfig-includes, + [ --with-synfig-includes Specify location of synfig headers],[ + CXXFLAGS="$CXXFLAGS -I$withval" + ]) + + AC_PATH_PROG(SYNFIG_CONFIG,synfig-config,no) + + if test "$SYNFIG_CONFIG" = "no"; then + no_SYNFIG_config="yes" + $2 + else + AC_MSG_CHECKING([if $SYNFIG_CONFIG works]) + if $SYNFIG_CONFIG --libs >/dev/null 2>&1; then + SYNFIG_VERSION="`$SYNFIG_CONFIG --version`" + AC_MSG_RESULT([yes, $SYNFIG_VERSION]) + SYNFIG_CXXFLAGS="`$SYNFIG_CONFIG --cxxflags`" + SYNFIG_CFLAGS="`$SYNFIG_CONFIG --cflags`" + SYNFIG_LIBS="`$SYNFIG_CONFIG --libs`" + CXXFLAGS="$CXXFLAGS $SYNFIG_CXXFLAGS" + AC_SUBST(SYNFIG_CXXFLAGS) + AC_SUBST(SYNFIG_LIBS) + AC_SUBST(SYNFIG_CFLAGS) + $1 + else + AC_MSG_RESULT(no) + no_SYNFIG_config="yes" + $2 + fi + fi + + SYNFIG_DEPS($1,$2) +]) + + diff --git a/synfig-studio/trunk/synfigstudio.spec.in b/synfig-studio/trunk/synfigstudio.spec.in new file mode 100755 index 0000000..e9844f6 --- /dev/null +++ b/synfig-studio/trunk/synfigstudio.spec.in @@ -0,0 +1,46 @@ + +Summary: Voria Extented Template Library +Name: @PACKAGE_TARNAME@-devel +Version: @VERSION@ +Release: 1 +Copyright: free (see license), see /usr/share/doc/%{name}-%{version}/license.html +URL: http://www.synfig.com/ +Packager: Robert B. Quattlebaum Jr. +Group: Development/Languages +Icon: config/logo.gif +#Patch0: STLport-rename.patch +#Patch1: STLport-rules.patch +#Patch2: STLport-install-dir.patch +Buildroot: %{_tmppath}/%{name}-%{version}-%(id -u -n) + +%description +VoriaETL is a multiplatform class and template library +designed to complement and supplement the C++ STL. + +%prep +%setup +#%patch0 -p1 +#%patch1 -p1 +#%patch2 -p1 + +%build +./configure --prefix=$RPM_BUILD_ROOT +make + +%install +make install + +%clean +make clean + +%post -n @PACKAGE@-devel +/sbin/ldconfig + +%postun -n @PACKAGE@-devel +/sbin/ldconfig + +%files +%defattr(-,root,root) +%doc INSTALL README doc test +/usr/include/* + -- 2.7.4