1 dnl Process this file with autoconf to produce a configure script.
5 export PACKAGE=swftools
6 export VERSION=pre0.1.0
8 export CFLAGS="-O2 -fomit-frame-pointer"
9 export CXXFLAGS="-O2 -fomit-frame-pointer"
11 dnl Checks for programs.
20 dnl Checks for system services
23 dnl Checks for libraries.
25 echo "Error: Math library not found.";
28 AC_CHECK_LIB(z, deflate,,
29 echo "Error: The zlib compression library is required."
31 MISSINGLIBS="${MISSINGLIBS} zlib"
33 AC_CHECK_LIB(jpeg, jpeg_write_raw_data,,
36 MISSINGLIBS="${MISSINGLIBS} jpeglib"
38 AC_CHECK_LIB(t1, T1_LoadFont,,
40 MISSINGLIBS="${MISSINGLIBS} T1lib"
44 dnl AC_CHECK_LIB(pthread, pthread_create)
45 dnl AC_CHECK_LIB(X11, XFlush)
47 dnl Checks for header files.
48 AC_CONFIG_HEADER(config.h)
53 AC_CHECK_HEADERS(math.h fcntl.h limits.h malloc.h unistd.h memory.h zlib.h jpeglib.h t1lib.h sys/stat.h sys/types.h)
55 if test "x${ac_cv_header_jpeglib_h}" != "xyes"; then
58 MISSINGLIBS="${MISSINGLIBS} jpeglib.h"
60 if test "x${ac_cv_header_t1lib_h}" != "xyes"; then
62 MISSINGLIBS="${MISSINGLIBS} t1lib.h"
64 if test "x${ac_cv_header_zlib_h}" != "xyes"; then
66 MISSINGLIBS="${MISSINGLIBS} zlib.h"
69 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
70 AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
74 AC_SUBST(HAVE_UNISTD_H)
77 dnl Checks for typedefs, structures, and compiler characteristics.
83 dnl AC_CHECK_TYPE(uchar,unsigned char)
84 dnl AC_CHECK_TYPE(schar,signed char)
85 dnl AC_CHECK_TYPE(word,unsigned short int)
86 dnl AC_CHECK_TYPE(sword,unsigned short int)
87 dnl AC_CHECK_TYPE(uint,unsigned long int)
89 dnl Checks for library functions.
93 AC_CHECK_FUNCS(getcwd putenv socket strcspn strdup strerror strstr)
95 export JPEG2SWF='jpeg2swf$(EXEEXT)'
96 if test "x${DISABLEPDF2SWF}" = "xtrue"; then
97 echo "***************************************************"
98 echo "The following headers/libraries are missing: " ${MISSINGLIBS}
99 echo "Disabling pdf2swf tool..."
100 rm -f pdf2swf/Makefile
101 echo all: > pdf2swf/Makefile
102 echo install: >> pdf2swf/Makefile
103 if test "x${DISABLEJPEG2SWF}" = "xtrue"; then
104 echo "Disabling jpeg2swf tool..."
107 echo "***************************************************"
108 FILES="./release Makefile lib/Makefile src/Makefile"
110 FILES="./release Makefile lib/Makefile src/Makefile pdf2swf/Makefile pdf2swf/xpdf/Makefile pdf2swf/fonts/Makefile"