From 9ff93666c68403f197be951a2bbef321352253c3 Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Mon, 24 Apr 2006 21:45:26 +0000 Subject: [PATCH] * Brought the Win32 build back on its wheels. --- build-win32 | 7 +++---- configure.ac | 12 +++++++++++- src/Makefile.am | 8 +++++++- src/cacaserver.c | 1 + 4 files changed, 22 insertions(+), 6 deletions(-) diff --git a/build-win32 b/build-win32 index da21a55..1878de7 100755 --- a/build-win32 +++ b/build-win32 @@ -14,12 +14,11 @@ rm -f "${DIRNAME}.zip" mkdir "${DIRNAME}" # Build for win32 -./configure --host=i586-mingw32msvc --prefix=/ --bindir=/bin --libdir=/lib --disable-imlib2 --disable-doc +./configure --host=i586-mingw32msvc --prefix=/ --bindir=/bin --libdir=/lib --disable-imlib2 --disable-doc --disable-pangoft2 make pkglibdir=/lib pkgdatadir=/data bindir=/bin # Install into our private directory make install DESTDIR="${DESTDIR}" pkglibdir=/lib/ pkgdatadir=/ bindir=/bin/ -cp COPYING COPYING.LGPL "${DESTDIR}/share/doc/libcaca-dev/" mv "${DESTDIR}/bin/"* "${DESTDIR}/" mv "${DESTDIR}/lib/"* "${DESTDIR}/" @@ -29,8 +28,8 @@ rmdir "${DESTDIR}/bin" rmdir "${DESTDIR}/lib" mkdir "${DESTDIR}/doc" -for f in `ls "${DESTDIR}/share/doc/libcaca-dev/"`; do - sed -e 's/$/ /' < "${DESTDIR}/share/doc/libcaca-dev/${f}" > "${DESTDIR}/doc/${f}.txt" +for f in COPYING COPYING.LGPL COPYING.GPL README AUTHORS NEWS NOTES THANKS TODO; do + sed -e 's/$/ /' < "${f}" > "${DESTDIR}/doc/${f}.txt" done rm -Rf "${DESTDIR}/share" rm -Rf "${DESTDIR}/man" diff --git a/configure.ac b/configure.ac index 9e4fb5c..accc431 100644 --- a/configure.ac +++ b/configure.ac @@ -60,6 +60,8 @@ AC_ARG_ENABLE(imlib2, dnl conditional builds AC_ARG_ENABLE(doc, [ --enable-doc build documentation (needs doxygen and LaTeX)]) +AC_ARG_ENABLE(pangoft2, + [ --enable-pangoft2 build font generator tool (autodetected)]) AC_CHECK_HEADERS(stdio.h stdarg.h signal.h sys/ioctl.h sys/time.h inttypes.h endian.h unistd.h arpa/inet.h netinet/in.h winsock2.h) AC_CHECK_FUNCS(signal ioctl vsnprintf getenv putenv strcasecmp htons) @@ -249,6 +251,12 @@ if test "${enable_cpp}" = "yes"; then fi AM_CONDITIONAL(USE_CPP, test "${ac_cv_my_have_cpp}" = "yes") +# Build cacaserver? +ac_cv_my_have_fcntl="no" +AC_CHECK_FUNC(fcntl, + [ac_cv_my_have_fcntl="yes"]) +AM_CONDITIONAL(USE_FCNTL, test "${ac_cv_my_have_fcntl}" = "yes") + # Use Imlib2? ac_cv_my_have_imlib2="no" save_CPPFLAGS="${CPPFLAGS}" @@ -267,7 +275,9 @@ AM_CONDITIONAL(USE_IMLIB2, test "${ac_cv_my_have_imlib2}" = "yes") # Build development tools? PANGOFT2="no" -PKG_CHECK_MODULES(pangoft2, pangoft2, [PANGOFT2="yes"], [AC_MSG_RESULT(no)]) +if test "${enable_pangoft2}" != "no"; then + PKG_CHECK_MODULES(pangoft2, pangoft2, [PANGOFT2="yes"], [AC_MSG_RESULT(no)]) +fi AM_CONDITIONAL(USE_PANGO, test "${PANGOFT2}" != "no") # Build documentation? diff --git a/src/Makefile.am b/src/Makefile.am index 9cdef38..e55468e 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -5,7 +5,7 @@ pkgdata_DATA = caca.txt EXTRA_DIST = caca.txt AM_CPPFLAGS = -I$(top_srcdir)/cucul -I$(top_srcdir)/caca -DLIBCACA=1 -DX_DISPLAY_MISSING=1 -bin_PROGRAMS = cacafire cacaball cacaplas cacaserver cacamoir cacaplay cacaview img2irc +bin_PROGRAMS = cacafire cacaball cacaplas cacamoir cacaplay cacaview img2irc $(fcntl_programs) cacafire_SOURCES = aafire.c cacafire_LDADD = ../caca/libcaca.la ../cucul/libcucul.la @CACA_LIBS@ @@ -43,3 +43,9 @@ img_cflags = img_ldflags = endif +if USE_FCNTL +fcntl_programs = cacaserver +else +fcntl_programs = +endif + diff --git a/src/cacaserver.c b/src/cacaserver.c index 020816e..83f26b8 100644 --- a/src/cacaserver.c +++ b/src/cacaserver.c @@ -24,6 +24,7 @@ # include #elif defined(HAVE_WINSOCK2_H) # include +# include #endif #include #include