When experimenting in a VM, I just noticed herbstluftwm won't build on
a vanilla Archlinux:
In file included from src/layout.h:13:0,
from src/clientlist.h:16,
from src/settings.c:8:
src/monitor.h:13:37: fatal error: X11/extensions/Xinerama.h: No such file or directory
#include <X11/extensions/Xinerama.h>
^
compilation terminated.
make: *** [src/settings.o] Error 1
==> ERROR: A failure occurred in build().
Aborting...
My proposed fix would be to check if Xinerama is installed in the
Makefile, and if not, install without Xinerama. A patch to do so is
attached. I'm not sure if this is the most clean way to do it as I'm
not really a make expert, that's just what I got from another project
and it seems sane. I'd also add libxinerama to optdepends in the
PKGBUILD, so people know why detect_monitors does not work.
Another possible fix would be to add Xinerama to depends=() or
makedepends=() in the PKGBUILD, but that'd just increase dependencies
for people running a minimal system.
Regarding my other patches, I'll take another look at them soon, just
a bit busy with other projects at the moment.
Florian
--
www.the-compiler.org | Top-posting sucks! http://s.cmpl.cc/top
I love long mails! | http://email.is-not-s.ms/
Allen's Axiom: When all else fails, read the instructions.
From 020a5f8bf9c3b8288966941449affac8f5669266 Mon Sep 17 00:00:00 2001 From: Florian Bruhin <git _at_ the _minus_ compiler _dot_ org> Date: Tue, 13 Aug 2013 09:59:24 +0200 Subject: [PATCH] Only build with Xinerama if it's available --- config.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config.mk b/config.mk index a3cfd35..271d5b8 100644 --- a/config.mk +++ b/config.mk @@ -3,8 +3,8 @@ X11INC = /usr/X11R6/include X11LIB = /usr/X11R6/lib # Xinerama -XINERAMALIBS = -L${X11LIB} -lXinerama -XINERAMAFLAGS = -DXINERAMA +XINERAMALIBS = $(shell pkg-config --exists xinerama && echo -lXinerama) +XINERAMAFLAGS = $(shell pkg-config --exists xinerama && echo -DXINERAMA) INCS = -Isrc/ -I/usr/include -I${X11INC} `pkg-config --cflags glib-2.0` LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 $(XINERAMALIBS) `pkg-config --libs glib-2.0` -- 1.8.3.4
Attachment:
pgp_rlIOpTYiM.pgp
Description: PGP signature