Commit 5ff8a715 authored by Thomas Petazzoni's avatar Thomas Petazzoni Committed by Peter Korsgaard
Browse files

xlib_libXpm: fix build on noMMU architectures

parent 382eef52
Loading
Loading
Loading
Loading
+21 −0
Original line number Diff line number Diff line
Allow usage when fork() is not available

When fork() is not available, we need to define NO_ZPIPE so that
libXpm doesn't try to fork/exec to use a pipe to uncompress compressed
.xpm files. There is obviously a loss of functionality, but loading
uncompressed .xpm files should continue to work.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>

Index: b/configure.ac
===================================================================
--- a/configure.ac
+++ b/configure.ac
@@ -22,6 +22,7 @@
 
 # Checks for library functions
 AC_CHECK_FUNCS([strlcat])
+AC_CHECK_FUNC([fork],[], AC_DEFINE(NO_ZPIPE))
 
 # Obtain compiler/linker options for dependencies
 PKG_CHECK_MODULES(XPM, xproto x11)
+2 −0
Original line number Diff line number Diff line
@@ -10,6 +10,8 @@ XLIB_LIBXPM_SITE = http://xorg.freedesktop.org/releases/individual/lib
XLIB_LIBXPM_LICENSE = MIT
XLIB_LIBXPM_LICENSE_FILES = COPYING
XLIB_LIBXPM_INSTALL_STAGING = YES
# we patch configure.ac
XLIB_LIBXPM_AUTORECONF = YES
XLIB_LIBXPM_DEPENDENCIES = xlib_libX11 xlib_libXext xlib_libXt xproto_xproto \
	host-gettext