1 dnl Process this file with autoconf to produce a configure script.
7 CFLAGS="-Wparentheses -Wimplicit -Wreturn-type -O2 -fomit-frame-pointer"
8 CXXFLAGS="-Wparentheses -Wimplicit -Wreturn-type -O2 -fomit-frame-pointer"
9 export PACKAGE VERSION CFLAGS CXXFLAGS
11 dnl Checks for programs.
20 AC_CHECK_PROGS(UNCOMPRESS, gzip uncompress compress, )
22 dnl Checks for system services
25 dnl Checks for libraries.
27 echo "Error: Math library not found.";
30 AC_CHECK_LIB(z, deflate,,
31 echo "Error: The zlib compression library is required."
33 MISSINGLIBS="${MISSINGLIBS} zlib"
36 AC_CHECK_LIB(jpeg, jpeg_write_raw_data,,
39 MISSINGLIBS="${MISSINGLIBS} jpeglib"
41 AC_CHECK_LIB(t1, T1_LoadFont,,
43 MISSINGLIBS="${MISSINGLIBS} T1lib"
47 AC_SUBST(WORDS_BIGENDIAN)
48 RFX_CHECK_SYSTEM_BACKTICKS
49 AC_SUBST(SYSTEM_BACKTICKS)
54 dnl AC_CHECK_LIB(pthread, pthread_create)
55 dnl AC_CHECK_LIB(X11, XFlush)
57 dnl Checks for header files.
58 AC_CONFIG_HEADER(config.h)
63 AC_CHECK_HEADERS(zlib.h jpeglib.h t1lib.h sys/stat.h sys/types.h dirent.h sys/bsdtypes.h sys/ndir.h sys/dir.h ndir.h)
65 if test "x${ac_cv_header_jpeglib_h}" != "xyes"; then
68 MISSINGLIBS="${MISSINGLIBS} jpeglib.h"
70 if test "x${ac_cv_header_t1lib_h}" != "xyes"; then
72 MISSINGLIBS="${MISSINGLIBS} t1lib.h"
74 if test "x${ac_cv_header_zlib_h}" != "xyes"; then
76 MISSINGLIBS="${MISSINGLIBS} zlib.h"
79 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
80 AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
84 AC_SUBST(HAVE_UNISTD_H)
87 dnl Checks for typedefs, structures, and compiler characteristics.
93 AC_CHECK_TYPE(boolean,int)
94 AC_CHECK_TYPE(bool,char)
95 dnl AC_CHECK_TYPE(uchar,unsigned char)
96 dnl AC_CHECK_TYPE(schar,signed char)
97 dnl AC_CHECK_TYPE(word,unsigned short int)
98 dnl AC_CHECK_TYPE(sword,unsigned short int)
99 dnl AC_CHECK_TYPE(uint,unsigned long int)
101 dnl Checks for library functions.
102 AC_CHECK_FUNCS(popen mkstemp stat lrand48 rand srand48 srand)
105 avi2swf="avi2swf/Makefile"
106 if test "x${AVIFILE}" != "xtrue"; then
107 echo "* Couldn't compile the avifile test program."
108 echo "* Disabling avi2swf tool..."
109 echo all: > avi2swf/Makefile
110 echo install: >> avi2swf/Makefile
111 echo clean: >> avi2swf/Makefile
115 if test "x${UNCOMPRESS}" = "xgzip"; then
116 AC_DEFINE_UNQUOTED(USE_GZIP, 1)
120 JPEG2SWF='jpeg2swf$(EXEEXT)'
122 if test "x${DISABLEPDF2SWF}" = "xtrue"; then
123 echo "***************************************************"
124 echo "The following headers/libraries are missing: " ${MISSINGLIBS}
125 echo "Disabling pdf2swf tool..."
126 rm -f pdf2swf/Makefile
127 echo all: > pdf2swf/Makefile
128 echo install: >> pdf2swf/Makefile
129 echo clean: >> pdf2swf/Makefile
130 if test "x${DISABLEJPEG2SWF}" = "xtrue"; then
131 echo "Disabling jpeg2swf tool..."
135 echo "***************************************************"
136 FILES="./release ${avi2swf} Makefile lib/lame/Makefile lib/Makefile src/Makefile swfs/Makefile"
138 FILES="./release ${avi2swf} Makefile lib/lame/Makefile lib/Makefile src/Makefile pdf2swf/Makefile pdf2swf/xpdf/Makefile pdf2swf/ttf2pt1/Makefile pdf2swf/fonts/Makefile swfs/Makefile"