dmx, vfb, xnest: fix fbcmap compilation

Don't always define XFree86Server, but only for damn fbcmap.c.
Split fbcmap.c into its own library to achieve this.
This commit is contained in:
Daniel Stone 2007-01-18 15:23:57 +11:00 committed by Daniel Stone
parent 236f04b638
commit 17d85387d1
3 changed files with 36 additions and 35 deletions

View File

@ -2,6 +2,7 @@ DIST_SUBDIRS = input config glxProxy examples doc
SUBDIRS = input config examples
bin_PROGRAMS = Xdmx
noinst_LIBRARIES = libfbcmap.a
if XINERAMA
PANORAMIX_SRCS = $(top_srcdir)/Xext/panoramiX.c
@ -16,13 +17,20 @@ GLX_INCS = -I$(top_srcdir)/hw/xfree86/dixmods/extmod \
GLX_DEFS = @GL_CFLAGS@
endif
# It's essential that fbcmap.c be compiled with this flag for DMX to work!!
DMX_CFLAGS = -DXFree86Server=1
if BUILDDOCS
SUBDIRS += doc
endif
AM_CFLAGS = \
-DHAVE_DMX_CONFIG_H \
$(DIX_CFLAGS) \
$(GLX_INCS) \
$(GLX_DEFS) \
@DMXMODULES_CFLAGS@
libfbcmap_a_SOURCES = libfbcmap.a
libfbcmap_a_CFLAGS = $(AM_CFLAGS) -DXFree86Server
Xdmx_SOURCES = dmx.c \
dmxcb.c \
dmxcb.h \
@ -67,7 +75,6 @@ Xdmx_SOURCES = dmx.c \
dmxvisual.h \
dmxwindow.c \
dmxwindow.h \
$(top_srcdir)/fb/fbcmap.c \
$(top_srcdir)/mi/miinitext.c \
$(GLX_SRCS)
@ -82,16 +89,9 @@ Xdmx_LDADD = $(XORG_CORE_LIBS) \
$(GLX_LIBS) \
input/libdmxinput.a \
config/libdmxconfig.a \
libfbcmap.a \
@DMXMODULES_LIBS@
Xdmx_CFLAGS = \
-DHAVE_DMX_CONFIG_H \
$(DIX_CFLAGS) \
$(GLX_INCS) \
$(GLX_DEFS) \
$(DMX_CFLAGS) \
@DMXMODULES_CFLAGS@
# Man page
appmandir = $(APP_MAN_DIR)

View File

@ -1,12 +1,21 @@
bin_PROGRAMS = Xvfb
noinst_LIBRARIES = libfbcmap.a
AM_CFLAGS = -DHAVE_DIX_CONFIG_H \
-DNO_HW_ONLY_EXTS \
-DNO_MODULE_EXTS \
$(XVFBMODULES_CFLAGS) \
$(DIX_CFLAGS)
SRCS = InitInput.c \
InitOutput.c \
lk201kbd.h \
$(top_srcdir)/Xext/dpmsstubs.c \
$(top_srcdir)/Xi/stubs.c \
$(top_srcdir)/mi/miinitext.c \
$(top_srcdir)/fb/fbcmap.c
$(top_srcdir)/mi/miinitext.c
libfbcmap_a_CFLAGS = $(AM_CFLAGS) -DXFree86Server
libfbcmap_a_SOURCES = $(top_srcdir)/fb/fbcmap.c
Xvfb_SOURCES = $(SRCS)
@ -14,16 +23,8 @@ Xvfb_LDADD = $(XORG_CORE_LIBS) \
$(XVFB_LIBS) \
$(XSERVER_LIBS) \
$(EXTENSION_LIBS) \
$(XVFBMODULES_LIBS)
Xvfb_LDFLAGS =
AM_CFLAGS = -DHAVE_DIX_CONFIG_H \
-DNO_HW_ONLY_EXTS \
-DNO_MODULE_EXTS \
-DXFree86Server \
$(XVFBMODULES_CFLAGS) \
$(DIX_CFLAGS)
$(XVFBMODULES_LIBS) \
libfbcmap.a
# Man page
include $(top_srcdir)/cpprules.in

View File

@ -1,4 +1,10 @@
bin_PROGRAMS = Xnest
noinst_LIBRARIES = libfbcmap.a
AM_CFLAGS = -DHAVE_XNEST_CONFIG_H \
-DNO_HW_ONLY_EXTS \
$(DIX_CFLAGS) \
$(XNESTMODULES_CFLAGS)
SRCS = Args.c \
Args.h \
@ -37,23 +43,17 @@ SRCS = Args.c \
xnest-config.h \
$(top_srcdir)/Xext/dpmsstubs.c \
$(top_srcdir)/Xi/stubs.c \
$(top_srcdir)/mi/miinitext.c \
$(top_srcdir)/fb/fbcmap.c
$(top_srcdir)/mi/miinitext.c
libfbcmap_a_SOURCES = $(top_srcdir)/fb/fbcmap.c
libfbcmap_a_CFLAGS = $(AM_CFLAGS) -DXFree86Server
Xnest_SOURCES = $(SRCS)
Xnest_LDADD = $(XORG_CORE_LIBS) \
$(XNEST_LIBS) \
$(XNESTMODULES_LIBS)
Xnest_LDFLAGS =
AM_CFLAGS = -DHAVE_XNEST_CONFIG_H \
-DNO_HW_ONLY_EXTS \
-DXFree86Server \
$(DIX_CFLAGS) \
$(XNESTMODULES_CFLAGS)
$(XNESTMODULES_LIBS) \
libfbcmap.a
EXTRA_DIST = os2Stub.c \
icon \