AVIFILE_CONFIG
splash_in_source
xpdf_in_source
-art_in_source
lame_in_source
DEVICE_OPENGL
FREETYPE_CONFIG
+# ------------------- option parsing -------------------------------
+
+DEBUG=
+CHECKMEM=
+PROFILING=
+ENABLE_WARNINGS=
+OPTIMIZE=
+DISABLE_LAME=
+
# Check whether --enable-checkmem was given.
if test "${enable_checkmem+set}" = set; then
enableval=$enable_checkmem; CHECKMEM=true
PACKAGE=swftools
-VERSION=2009-08-12-1514
-
+VERSION=2010-02-06-1900
# ------------------------------------------------------------------
exit 1
fi
-WARNINGS="-Wparentheses -Wimplicit -Wreturn-type"
+WARNINGS="-Wimplicit -Wreturn-type -Wno-write-strings -Wformat"
if test "x$ENABLE_WARNINGS" '!=' "x";then
- WARNINGS="-Wall -Wno-unused -Wno-format -Wno-redundant-decls -D_FORTIFY_SOURCE=2 "
+ WARNINGS="-Wall -Wno-unused -Wno-format -Wno-redundant-decls -Wno-write-strings -D_FORTIFY_SOURCE=2 "
fi
if test "x$CHECKMEM" '!=' "x";then
if test "x$PROFILING" = "x";then
CFLAGS="$WARNINGS -O2 -g $CFLAGS"
CXXFLAGS="$WARNINGS -O2 -g $CXXFLAGS"
- LDFLAGS="-g $LIBS"
+ LDFLAGS="-g $LDFLAGS"
else
CFLAGS="$WARNINGS -O2 -g -pg $CFLAGS"
CXXFLAGS="$WARNINGS -O2 -g -pg $CXXFLAGS"
- LDFLAGS="-g -pg $LIBS"
+ LDFLAGS="-g -pg $LDFLAGS"
fi
else if test "x$OPTIMIZE" '!=' "x"; then
CFLAGS="$WARNINGS -O3 -fomit-frame-pointer -Winline $CFLAGS"
fi
+{ $as_echo "$as_me:$LINENO: checking for zzip_file_open in -lzzip" >&5
+$as_echo_n "checking for zzip_file_open in -lzzip... " >&6; }
+if test "${ac_cv_lib_zzip_zzip_file_open+set}" = set; then
+ $as_echo_n "(cached) " >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lzzip $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char zzip_file_open ();
+int
+main ()
+{
+return zzip_file_open ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
+ (eval "$ac_link") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ $as_test_x conftest$ac_exeext
+ }; then
+ ac_cv_lib_zzip_zzip_file_open=yes
+else
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_cv_lib_zzip_zzip_file_open=no
+fi
+
+rm -rf conftest.dSYM
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_zzip_zzip_file_open" >&5
+$as_echo "$ac_cv_lib_zzip_zzip_file_open" >&6; }
+if test "x$ac_cv_lib_zzip_zzip_file_open" = x""yes; then
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_LIBZZIP 1
+_ACEOF
+
+ LIBS="-lzzip $LIBS"
+
+else
+ ZZIPMISSING=true
+fi
+
+
{ $as_echo "$as_me:$LINENO: checking for byte order" >&5
$as_echo_n "checking for byte order... " >&6; }
-for ac_header in zlib.h gif_lib.h io.h wchar.h jpeglib.h assert.h signal.h pthread.h sys/stat.h sys/mman.h sys/types.h dirent.h sys/bsdtypes.h sys/ndir.h sys/dir.h ndir.h time.h sys/time.h sys/resource.h pdflib.h
+
+for ac_header in zlib.h gif_lib.h io.h wchar.h jpeglib.h assert.h signal.h pthread.h sys/stat.h sys/mman.h sys/types.h dirent.h sys/bsdtypes.h sys/ndir.h sys/dir.h ndir.h time.h sys/time.h sys/resource.h pdflib.h zzip/lib.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-OLDCPPFLAGS="${CPPFLAGS}"
-OLDLIBS="${LIBS}"
-
-
-{ $as_echo "$as_me:$LINENO: checking for glBegin in -lGL" >&5
-$as_echo_n "checking for glBegin in -lGL... " >&6; }
-if test "${ac_cv_lib_GL_glBegin+set}" = set; then
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lGL $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char glBegin ();
-int
-main ()
-{
-return glBegin ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
-$as_echo "$ac_try_echo") >&5
- (eval "$ac_link") 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- $as_test_x conftest$ac_exeext
- }; then
- ac_cv_lib_GL_glBegin=yes
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_cv_lib_GL_glBegin=no
-fi
-
-rm -rf conftest.dSYM
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_GL_glBegin" >&5
-$as_echo "$ac_cv_lib_GL_glBegin" >&6; }
-if test "x$ac_cv_lib_GL_glBegin" = x""yes; then
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBGL 1
-_ACEOF
-
- LIBS="-lGL $LIBS"
-
-fi
-
-
-{ $as_echo "$as_me:$LINENO: checking for gluBeginSurface in -lGLU" >&5
-$as_echo_n "checking for gluBeginSurface in -lGLU... " >&6; }
-if test "${ac_cv_lib_GLU_gluBeginSurface+set}" = set; then
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lGLU $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gluBeginSurface ();
-int
-main ()
-{
-return gluBeginSurface ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
-$as_echo "$ac_try_echo") >&5
- (eval "$ac_link") 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- $as_test_x conftest$ac_exeext
- }; then
- ac_cv_lib_GLU_gluBeginSurface=yes
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_cv_lib_GLU_gluBeginSurface=no
-fi
-
-rm -rf conftest.dSYM
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_GLU_gluBeginSurface" >&5
-$as_echo "$ac_cv_lib_GLU_gluBeginSurface" >&6; }
-if test "x$ac_cv_lib_GLU_gluBeginSurface" = x""yes; then
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBGLU 1
-_ACEOF
-
- LIBS="-lGLU $LIBS"
-
-fi
-
+ OLDCPPFLAGS="${CPPFLAGS}"
+ OLDLIBS="${LIBS}"
-{ $as_echo "$as_me:$LINENO: checking for glutInit in -lglut" >&5
-$as_echo_n "checking for glutInit in -lglut... " >&6; }
-if test "${ac_cv_lib_glut_glutInit+set}" = set; then
+ { $as_echo "$as_me:$LINENO: checking for fftw_plan_dft_r2c_2d in -lfftw3" >&5
+$as_echo_n "checking for fftw_plan_dft_r2c_2d in -lfftw3... " >&6; }
+if test "${ac_cv_lib_fftw3_fftw_plan_dft_r2c_2d+set}" = set; then
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
-LIBS="-lglut $LIBS"
+LIBS="-lfftw3 $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
#ifdef __cplusplus
extern "C"
#endif
-char glutInit ();
+char fftw_plan_dft_r2c_2d ();
int
main ()
{
-return glutInit ();
+return fftw_plan_dft_r2c_2d ();
;
return 0;
}
test "$cross_compiling" = yes ||
$as_test_x conftest$ac_exeext
}; then
- ac_cv_lib_glut_glutInit=yes
+ ac_cv_lib_fftw3_fftw_plan_dft_r2c_2d=yes
else
$as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
- ac_cv_lib_glut_glutInit=no
+ ac_cv_lib_fftw3_fftw_plan_dft_r2c_2d=no
fi
rm -rf conftest.dSYM
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_glut_glutInit" >&5
-$as_echo "$ac_cv_lib_glut_glutInit" >&6; }
-if test "x$ac_cv_lib_glut_glutInit" = x""yes; then
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBGLUT 1
-_ACEOF
-
- LIBS="-lglut $LIBS"
-
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_fftw3_fftw_plan_dft_r2c_2d" >&5
+$as_echo "$ac_cv_lib_fftw3_fftw_plan_dft_r2c_2d" >&6; }
+if test "x$ac_cv_lib_fftw3_fftw_plan_dft_r2c_2d" = x""yes; then
+ HAVE_LIBFFTW3=1
fi
-
-for ac_header in GL/gl.h GL/glut.h
+for ac_header in fftw3.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
-
+ HAVE_FFTW3_H=1
fi
done
-cat > conftest.c << EOF
-#include <GL/gl.h>
-#include <GL/glu.h>
-#include <GL/glut.h>
+ if test "x${HAVE_LIBFFTW3}" != "x";then
+ if test "x${HAVE_FFTW3_H}" != "x";then
+ HAVE_FFTW3=1
+ fi
+ fi
-int main(int argc, char*argv)
-{
- glutInit(&argc, argv);
- glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGB | GLUT_DEPTH);
- glutInitWindowSize(320,200);
- glutInitWindowPosition(0,0);
- glutCreateWindow("main");
- glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
- glShadeModel(GL_SMOOTH);
- glEnable (GL_LINE_SMOOTH);
- glEnable (GL_POLYGON_SMOOTH);
- glEnable (GL_BLEND);
- glBlendFunc (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
- glHint (GL_LINE_SMOOTH_HINT, GL_DONT_CARE);
- glHint (GL_POLYGON_SMOOTH_HINT, GL_DONT_CARE);
-}
-EOF
+ if test "x${HAVE_FFTW3}" = "x1"; then
+ LIBS="$LIBS -lfftw3"
+ { $as_echo "$as_me:$LINENO: checking whether we can compile the fftw3 test program" >&5
+$as_echo_n "checking whether we can compile the fftw3 test program... " >&6; }
-{ $as_echo "$as_me:$LINENO: checking whether we can compile the opengl test program" >&5
-$as_echo_n "checking whether we can compile the opengl test program... " >&6; }
+ cat > conftest.c << EOF
+ #include <fftw3.h>
-ac_link='$CC $CPPFLAGS $CFLAGS conftest.c $LDFLAGS $LIBS -o conftest${ac_exeext}'
-if { (eval echo opengl.m4:71: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- { $as_echo "$as_me:$LINENO: result: yes" >&5
+ int main()
+ {
+ char*data = 0;
+ fftw_plan plan = fftw_plan_dft_2d(600, 800, (fftw_complex*)data, (fftw_complex*)data, FFTW_FORWARD, FFTW_ESTIMATE);
+ plan = fftw_plan_dft_r2c_2d(600, 800, (double*)data, (fftw_complex*)data, FFTW_ESTIMATE);
+ plan = fftw_plan_dft_c2r_2d(600, 800, (fftw_complex*)data, (double*)data, FFTW_ESTIMATE);
+ fftw_execute(plan);
+ fftw_destroy_plan(plan);
+ }
+EOF
+
+ ac_link='$CC $CPPFLAGS $CFLAGS conftest.c $LDFLAGS $LIBS -o conftest${ac_exeext}'
+ if { (eval echo fftw3.m4:71: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
- HAVE_OPENGL=1
cat >>confdefs.h <<\_ACEOF
-#define HAVE_OPENGL 1
+#define HAVE_FFTW3 1
_ACEOF
-else
- echo "configure: failed program was:" >&5
- cat conftest.c >&5
- HAVE_OPENGL=
- { $as_echo "$as_me:$LINENO: result: no" >&5
+ else
+ echo "configure: failed program was:" >&5
+ cat conftest.c >&5
+ HAVE_FFTW3=0
+ { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
-fi
-rm -f conftest*
+ fi
+ rm -f conftest*
+ fi
-# if the above didn't work out, reset all changes to the compiler variables.
-if test "x${HAVE_OPENGL}" "!=" "x1"; then
- CPPFLAGS=$OLDCPPFLAGS
- LIBS=$OLDLIBS
-fi
+ # if the above didn't work out, reset all changes to the compiler variables.
+ if test "x${HAVE_FFTW3}" "!=" "x1"; then
+ CPPFLAGS=$OLDCPPFLAGS
+ LIBS=$OLDLIBS
+ fi
-if test "$HAVE_OPENGL";then
- DEVICE_OPENGL='devices/opengl.$(O)'
-fi
+# RFX_CHECK_OPENGL
+# if test "$HAVE_OPENGL";then
+# DEVICE_OPENGL='devices/opengl.$(O)'
+# AC_SUBST(DEVICE_OPENGL)
+# fi
+
lame_in_source=
lame_makefile=
fi
-
-cat >>confdefs.h <<\_ACEOF
-#define INTERNAL_LIBART 1
-_ACEOF
-
-art_in_source='$(art_objects)'
splash_in_source='$(splash_objects)'
xpdf_in_source='$(xpdf_objects)'
-
# ------------------------------------------------------------------
if test "x${DISABLEPDF2SWF}" = "xtrue"; then
echo "* Disabling pdf2swf tool..."
rm -f lib/pdf/Makefile
- echo all install uninstall clean libpdf: > lib/pdf/Makefile
+ echo all install uninstall clean libpdf libgfxpdf: > lib/pdf/Makefile
pdf2swf_makefile=""
PDF2SWF=
LIBPDF=
if test -f "release.in"; then release_in="./release"; fi
if test -f "Makefile.new.in"; then mk_in="./Makefile.new"; fi
-FILES="$release_in $mk_in Makefile.common ${avi2swf} Makefile lib/Makefile lib/action/Makefile src/Makefile ${pdf2swf_makefile} swfs/Makefile ${pythonrfxswf} ${lame_makefile} lib/art/Makefile lib/readers/Makefile"
+FILES="$release_in $mk_in Makefile.common ${avi2swf} Makefile lib/Makefile lib/action/Makefile src/Makefile ${pdf2swf_makefile} swfs/Makefile ${pythonrfxswf} ${lame_makefile} lib/readers/Makefile"
ac_config_files="$ac_config_files ${FILES}"
cat >confcache <<\_ACEOF