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.
21 dnl Checks for system services
24 dnl Checks for libraries.
26 echo "Error: Math library not found.";
29 AC_CHECK_LIB(z, deflate,,
30 echo "Error: The zlib compression library is required."
32 MISSINGLIBS="${MISSINGLIBS} zlib"
34 AC_CHECK_LIB(jpeg, jpeg_write_raw_data,,
37 MISSINGLIBS="${MISSINGLIBS} jpeglib"
39 AC_CHECK_LIB(t1, T1_LoadFont,,
41 MISSINGLIBS="${MISSINGLIBS} T1lib"
45 dnl AC_CHECK_LIB(pthread, pthread_create)
46 dnl AC_CHECK_LIB(X11, XFlush)
48 dnl Checks for header files.
49 AC_CONFIG_HEADER(config.h)
54 AC_CHECK_HEADERS(math.h fcntl.h limits.h malloc.h unistd.h memory.h zlib.h jpeglib.h t1lib.h sys/stat.h)
56 if test "x${ac_cv_header_jpeglib_h}" != "xyes"; then
59 MISSINGLIBS="${MISSINGLIBS} jpeglib.h"
61 if test "x${ac_cv_header_t1lib_h}" != "xyes"; then
63 MISSINGLIBS="${MISSINGLIBS} t1lib.h"
66 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
67 AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
71 AC_SUBST(HAVE_UNISTD_H)
74 dnl Checks for typedefs, structures, and compiler characteristics.
80 dnl AC_CHECK_TYPE(uchar,unsigned char)
81 dnl AC_CHECK_TYPE(schar,signed char)
82 dnl AC_CHECK_TYPE(word,unsigned short int)
83 dnl AC_CHECK_TYPE(sword,unsigned short int)
84 dnl AC_CHECK_TYPE(uint,unsigned long int)
86 dnl Checks for library functions.
90 AC_CHECK_FUNCS(getcwd putenv socket strcspn strdup strerror strstr)
92 export JPEG2SWF='jpeg2swf$(EXEEXT)'
93 if test "x${DISABLEPDF2SWF}" = "xtrue"; then
94 echo "***************************************************"
95 echo "The following headers/libraries are missing: " ${MISSINGLIBS}
96 echo "Disabling pdf2swf tool..."
97 rm -f pdf2swf/Makefile
98 echo all: > pdf2swf/Makefile
99 echo install: >> pdf2swf/Makefile
100 if test "x${DISABLEJPEG2SWF}" = "xtrue"; then
101 echo "Disabling jpeg2swf tool..."
104 echo "***************************************************"
105 FILES="./release Makefile lib/Makefile src/Makefile"
107 FILES="./release Makefile lib/Makefile src/Makefile pdf2swf/Makefile pdf2swf/xpdf/Makefile pdf2swf/fonts/Makefile"