--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-checkmem turn on ccmalloc debugging
--enable-debug turn on debugging
+ --enable-profiling turn on profiling
--enable-warnings turn on compiler warnings
--enable-optimizations turn on compiler optimizations (recommended for avi2swf)
--disable-lame don't compile any L.A.M.E. mp3 encoding code in
enableval="$enable_debug"
DEBUG=true
fi;
+# Check whether --enable-profiling or --disable-profiling was given.
+if test "${enable_profiling+set}" = set; then
+ enableval="$enable_profiling"
+ PROFILING=true
+fi;
# Check whether --enable-warnings or --disable-warnings was given.
if test "${enable_warnings+set}" = set; then
enableval="$enable_warnings"
fi;
PACKAGE=swftools
-VERSION=2004-11-07-1822
+VERSION=2004-11-23-2234
# ------------------------------------------------------------------
if test "x$CHECKMEM" '!=' "x";then
DEBUG=yes
fi
+if test "x$PROFILING" '!=' "x";then
+ DEBUG=yes
+fi
if test "x$DEBUG" '!=' "x";then
- CFLAGS="$WARNINGS -g $CFLAGS"
- CXXFLAGS="$WARNINGS -g $CXXFLAGS"
+ if test "x$PROFILING" = "x";then
+ CFLAGS="$WARNINGS -g $CFLAGS"
+ CXXFLAGS="$WARNINGS -g $CXXFLAGS"
+ else
+ CFLAGS="$WARNINGS -O2 -g -pg $CFLAGS"
+ CXXFLAGS="$WARNINGS -O2 -g -pg $CXXFLAGS"
+ LDFLAGS="-g -pg $LIBS"
+ fi
else if test "x$OPTIMIZE" '!=' "x"; then
CFLAGS="$WARNINGS -O3 -fomit-frame-pointer -Winline $CFLAGS"
CXXFLAGS="$WARNINGS -O3 -fomit-frame-pointer -Winline $CXXFLAGS"
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 4801 "configure"' > conftest.$ac_ext
+ echo '#line 4816 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
compiler_c_o=no
-if { (eval echo configure:5377: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
+if { (eval echo configure:5392: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings
if test -s out/conftest.err; then
libsuff=
case "$host_cpu" in
x86_64*)
- echo '#line 6610 "configure"' > conftest.$ac_ext
+ echo '#line 6625 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 7358 "configure"
+#line 7373 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 7456 "configure"
+#line 7471 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
done
+OBJEXT="o"
+
+if test "x$EXEEXT" = "x.exe";then
+ OBJEXT="obj"
+fi
# TODO- test whether gcc still works after this
fi
+#Mac OS:
+#LDFLAGS "-L/sw/lib" ; CPPFLAGS "-I/sw/include -I/sw/include/lame"
+
+
# this must be done after (I believe) AC_PROG_MAKE_SET
if test "x$DEBUG" '!=' "x";then
STRIP="@echo debug enabled, not stripping "
# ------------------------------------------------------------------
-for ac_prog in freetype-config
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
+
+# Extract the first word of "freetype-config", so it can be a program name with args.
+set dummy freetype-config; ac_word=$2
echo "$as_me:$LINENO: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_FREETYPE_CONFIG+set}" = set; then
+if test "${ac_cv_path_FREETYPE_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test -n "$FREETYPE_CONFIG"; then
- ac_cv_prog_FREETYPE_CONFIG="$FREETYPE_CONFIG" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
+ case $FREETYPE_CONFIG in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_FREETYPE_CONFIG="$FREETYPE_CONFIG" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+as_dummy=""$PATH:/usr/local/bin:/sw/bin:/opt/local/bin""
+for as_dir in $as_dummy
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_FREETYPE_CONFIG="$ac_prog"
+ ac_cv_path_FREETYPE_CONFIG="$as_dir/$ac_word$ac_exec_ext"
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
done
+ ;;
+esac
fi
-fi
-FREETYPE_CONFIG=$ac_cv_prog_FREETYPE_CONFIG
+FREETYPE_CONFIG=$ac_cv_path_FREETYPE_CONFIG
+
if test -n "$FREETYPE_CONFIG"; then
echo "$as_me:$LINENO: result: $FREETYPE_CONFIG" >&5
echo "${ECHO_T}$FREETYPE_CONFIG" >&6
echo "${ECHO_T}no" >&6
fi
- test -n "$FREETYPE_CONFIG" && break
-done
OLDCPPFLAGS="${CPPFLAGS}"
OLDLIBS="${LIBS}"
if test "x${FREETYPE_CONFIG}" '!=' "x"; then
- CPPFLAGS="$CPPFLAGS "`freetype-config --cflags`
+ CPPFLAGS="$CPPFLAGS "`$FREETYPE_CONFIG --cflags`
else if test -d /usr/include/freetype2; then
CPPFLAGS="$CPPFLAGS -I/usr/include/freetype2"
else if test -d /usr/local/include/freetype2; then
fi
fi
-echo "$as_me:$LINENO: checking for FT_Init_FreeType in -lfreetype" >&5
+if test "x${FREETYPE_CONFIG}" '=' "x";then
+ # if we didn't find the freetype-config program, we won't
+ # know where the libs are expected to be. So just blindly
+ # try to link against them.
+ echo "$as_me:$LINENO: checking for FT_Init_FreeType in -lfreetype" >&5
echo $ECHO_N "checking for FT_Init_FreeType in -lfreetype... $ECHO_C" >&6
if test "${ac_cv_lib_freetype_FT_Init_FreeType+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
HAVE_LIB_FREETYPE=1
fi
+fi
+
-for ac_header in freetype/freetype.h
+for ac_header in ft2build.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
if eval "test \"\${$as_ac_Header+set}\" = set"; then
cat >>confdefs.h <<_ACEOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
- HAVE_FREETYPE_FREETYPE_H=1
+ HAVE_FT2BUILD_H=1
fi
done
+if test "x${HAVE_FT2BUILD_H}" '=' "x";then
-for ac_header in ft2build.h
+for ac_header in freetype/freetype.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
if eval "test \"\${$as_ac_Header+set}\" = set"; then
cat >>confdefs.h <<_ACEOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
- HAVE_FT2BUILD_H=1
+ HAVE_FREETYPE_FREETYPE_H=1
fi
done
+fi
-if test "x${HAVE_LIB_FREETYPE}" '!=' "x";then
+if test "x${HAVE_LIB_FREETYPE}" '!=' "x" -o \
+ "x${FREETYPE_CONFIG}" '!=' "x";then
if test "x${HAVE_FREETYPE_FREETYPE_H}" '!=' "x";then
HAVE_FREETYPE=1
fi
fi
if test "x${HAVE_FREETYPE}" = "x1"; then
- if test "x{$FREETYPE_CONFIG}" '!=' "x"; then
- LIBS="$LIBS "`freetype-config --libs`
+ if test "x${FREETYPE_CONFIG}" '!=' "x"; then
+ LIBS="$LIBS "`$FREETYPE_CONFIG --libs`
else
LIBS="$LIBS -lfreetype"
fi
-if test "x${HAVE_FT2BUILD_H}" = "x1"; then
- HAVE_FT2BUILD_H_DEFINE='#define HAVE_FT2BUILD_H'
-fi
+ if test "x${HAVE_FT2BUILD_H}" = "x1"; then
+ HAVE_FT2BUILD_H_DEFINE='#define HAVE_FT2BUILD_H'
+ fi
echo "$as_me:$LINENO: checking whether we can compile the freetype test program" >&5
echo $ECHO_N "checking whether we can compile the freetype test program... $ECHO_C" >&6
else
# old lame code at lib/lame
if test -f lib/lame/Makefile.in; then
- lame_objects="lame/psymodel.o lame/fft.o lame/newmdct.o lame/quantize.o lame/takehiro.o lame/reservoir.o lame/quantize_pvt.o lame/vbrquantize.o lame/encoder.o lame/id3tag.o lame/version.o lame/tables.o lame/util.o lame/bitstream.o lame/set_get.o lame/VbrTag.o lame/lame.o"
+ lame_objects="lame/psymodel.\$(O) lame/fft.\$(O) lame/newmdct.\$(O) lame/quantize.\$(O) lame/takehiro.\$(O) lame/reservoir.\$(O) lame/quantize_pvt.\$(O) lame/vbrquantize.\$(O) lame/encoder.\$(O) lame/id3tag.\$(O) lame/version.\$(O) lame/tables.\$(O) lame/util.\$(O) lame/bitstream.\$(O) lame/set_get.\$(O) lame/VbrTag.\$(O) lame/lame.\$(O)"
lame_makefile="lib/lame/Makefile"
CPPFLAGS="$CPPFLAGS -Ilame"
cat >>confdefs.h <<_ACEOF
PY_VERSION=2.$v
PYTHON_LIB="-lpython$PY_VERSION /usr/lib/python$PY_VERSION/site-packages/PIL/_imaging.so"
PYTHON_INCLUDES="-I/usr/include/python$PY_VERSION"
- fi
# Mac OS X
- if test -f "/Library/Python/2.$v/PIL/_imaging.so" \
- -a "/System/Library/Frameworks/Python.framework/Versions/2.$v/include/python2.$v/Python.h";then
+ elif test -f "/Library/Python/2.$v/PIL/_imaging.so" \
+ -a -f "/System/Library/Frameworks/Python.framework/Versions/2.$v/include/python2.$v/Python.h";then
PY_VERSION=2.$v
- #PYTHON_LIB="-lpython$PY_VERSION /Library/Python/2.$v/PIL/_imaging.so"
PYTHON_LIB="-framework Python /Library/Python/2.$v/PIL/_imaging.so"
PYTHON_INCLUDES="-I/System/Library/Frameworks/Python.framework/Versions/2.$v/include/python2.$v/"
+ # Mac OS X [Fink]:
+ elif test "(" -f "/sw/lib/python2.$v/config/libpython2.$v.dylib" \
+ -o -f "/sw/lib/python2.$v/config/libpython2.$v.a" \
+ -o -f "/sw/lib/python2.$v/config/libpython2.$v.so" \
+ ")" \
+ -a -f "/sw/include/python2.$v/Python.h" \
+ -a -f "/sw/lib/python2.$v/site-packages/PIL/_imaging.so";then
+ PY_VERSION=2.$v
+ PYTHON_LIB="-L /sw/lib/python2.$v/config/ -lpython$PY_VERSION /sw/lib/python2.$v/site-packages/PIL/_imaging.so"
+ PYTHON_INCLUDES="-I /sw/include/python2.$v/"
fi
done
fi