aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDRC <dcommander@users.sourceforge.net>2011-08-23 23:44:22 +0000
committerDRC <dcommander@users.sourceforge.net>2011-08-23 23:44:22 +0000
commit312c159ab0e94a1dc3f5f32f02e9b2313d902330 (patch)
treebec5f26e2c4411902d07303ba8a5539b9a412e11
parent6f9a3d7019a9a03332fc3437527c66680516d708 (diff)
downloadtigervnc-312c159ab0e94a1dc3f5f32f02e9b2313d902330.tar.gz
tigervnc-312c159ab0e94a1dc3f5f32f02e9b2313d902330.zip
We can't assume that Pixman is under ${includedir}, because ${includedir} depends on the install prefix. Fortunately, XSERVERLIBS_CFLAGS should contain the correct include directory for Pixman, so we can use this variable directly or parse it for the include directory.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4653 3789f03b-4d11-0410-bbf8-ca57d06f2519
-rw-r--r--unix/xserver/hw/vnc/Makefile.am19
1 files changed, 14 insertions, 5 deletions
diff --git a/unix/xserver/hw/vnc/Makefile.am b/unix/xserver/hw/vnc/Makefile.am
index 0beae052..dc1d4fc8 100644
--- a/unix/xserver/hw/vnc/Makefile.am
+++ b/unix/xserver/hw/vnc/Makefile.am
@@ -17,7 +17,7 @@ libvnccommon_la_SOURCES = $(HDRS) vncExtInit.cc vncHooks.cc XserverDesktop.cc \
libvnccommon_la_CPPFLAGS = -DVENDOR_RELEASE="$(VENDOR_RELEASE)" \
-DVENDOR_STRING="\"$(VENDOR_STRING)\"" -I$(TIGERVNC_SRCDIR)/common -UHAVE_CONFIG_H \
- -I$(TIGERVNC_SRCDIR)/unix/vncconfig $(XVNC_CPPFLAGS) -I$(includedir)/pixman-1 -I$(includedir)
+ -I$(TIGERVNC_SRCDIR)/unix/vncconfig $(XVNC_CPPFLAGS) ${XSERVERLIBS_CFLAGS} -I$(includedir)
bin_PROGRAMS = Xvnc
@@ -33,7 +33,7 @@ Xvnc_CPPFLAGS = $(XVNC_CPPFLAGS) -DTIGERVNC -DNO_HW_ONLY_EXTS -DNO_MODULE_EXTS \
-UHAVE_CONFIG_H \
-DXFree86Server -DVENDOR_RELEASE="$(VENDOR_RELEASE)" \
-DVENDOR_STRING="\"$(VENDOR_STRING)\"" -I$(TIGERVNC_SRCDIR)/common \
- -I$(top_srcdir)/include -I$(includedir)/pixman-1 -I$(includedir)
+ -I$(top_srcdir)/include ${XSERVERLIBS_CFLAGS} -I$(includedir)
Xvnc_LDADD = $(XVNC_LIBS) libvnccommon.la $(COMMON_LIBS) \
$(XSERVER_LIBS) $(XSERVER_SYS_LIBS) $(XVNC_SYS_LIBS) -lX11
@@ -49,7 +49,7 @@ libvnc_la_CPPFLAGS = $(XVNC_CPPFLAGS) -I$(TIGERVNC_SRCDIR)/common -UHAVE_CONFIG_
-I$(top_srcdir)/hw/xfree86/common \
-I$(top_srcdir)/hw/xfree86/os-support \
-I$(top_srcdir)/hw/xfree86/os-support/bus \
- -I$(includedir)/pixman-1 -I$(includedir)
+ ${XSERVERLIBS_CFLAGS} -I$(includedir)
libvnc_la_LDFLAGS = -module -avoid-version
@@ -63,8 +63,17 @@ BUILT_SOURCES = $(nodist_Xvnc_SOURCES)
fb.h: $(top_srcdir)/fb/fb.h
cat $(top_srcdir)/fb/fb.h | sed -e 's,and,c_and,' -e 's,xor,c_xor,' > $(srcdir)/fb.h
-pixman.h: $(includedir)/pixman-1/pixman.h
- cat $(includedir)/pixman-1/pixman.h | sed 's/xor/c_xor/' > $(srcdir)/pixman.h
+pixman.h:
+ for i in ${XSERVERLIBS_CFLAGS}; do \
+ if [[ "$$i" =~ "pixman" ]]; then \
+ PIXMANINCDIR=`echo $$i | sed s/-I//g`; \
+ fi; \
+ done; \
+ if [ ! "$$PIXMANINCDIR" = "" ]; then \
+ cat $$PIXMANINCDIR/pixman.h | sed 's/xor/c_xor/' > $(srcdir)/pixman.h; \
+ else \
+ echo Pixman include directory not set in XSERVERLIBS_CFLAGS (perhaps Pixman was not found by configure?); \
+ fi
fbrop.h: $(top_srcdir)/fb/fbrop.h
cat $(top_srcdir)/fb/fbrop.h | sed -e 's,and,c_and,' -e 's,xor,c_xor,' > $(srcdir)/fbrop.h