summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Xext/Makefile.am4
-rw-r--r--Xi/Makefile.am5
-rw-r--r--configure.ac3
-rw-r--r--dix/globals.c3
-rw-r--r--fb/Makefile.am3
-rw-r--r--hw/dmx/Makefile.am1
-rw-r--r--hw/kdrive/ephyr/hostx.c5
-rw-r--r--hw/kdrive/src/Makefile.am5
-rw-r--r--hw/vfb/Makefile.am11
-rw-r--r--hw/xfree86/dixmods/Makefile.am4
-rw-r--r--hw/xfree86/parser/DRI.c1
-rw-r--r--hw/xfree86/parser/Extensions.c1
-rw-r--r--hw/xnest/Makefile.am9
-rw-r--r--hw/xquartz/Makefile.am1
-rw-r--r--hw/xwin/Makefile.am9
-rw-r--r--include/opaque.h1
-rw-r--r--os/connection.c12
-rw-r--r--os/utils.c2
-rw-r--r--test/Makefile.am6
19 files changed, 39 insertions, 47 deletions
diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index 8e31f1367..a9a446820 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -1,4 +1,4 @@
-noinst_LTLIBRARIES = libXext.la
+noinst_LTLIBRARIES = libXext.la libXextdpmsstubs.la
AM_CFLAGS = $(DIX_CFLAGS)
@@ -96,6 +96,8 @@ endif
libXext_la_SOURCES = $(BUILTIN_SRCS)
libXext_la_LIBADD = $(BUILTIN_LIBS)
+libXextdpmsstubs_la_SOURCES = dpmsstubs.c
+
EXTRA_DIST = \
$(MITSHM_SRCS) \
$(XV_SRCS) \
diff --git a/Xi/Makefile.am b/Xi/Makefile.am
index af85bd049..6c456c4ac 100644
--- a/Xi/Makefile.am
+++ b/Xi/Makefile.am
@@ -1,4 +1,4 @@
-noinst_LTLIBRARIES = libXi.la
+noinst_LTLIBRARIES = libXi.la libXistubs.la
AM_CFLAGS = $(DIX_CFLAGS)
@@ -107,4 +107,5 @@ libXi_la_SOURCES = \
xiwarppointer.c \
xiwarppointer.h
-EXTRA_DIST = stubs.c
+libXistubs_la_SOURCES = \
+ stubs.c
diff --git a/configure.ac b/configure.ac
index a75ba8f69..f589d6d74 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2408,8 +2408,7 @@ if test "$KDRIVE" = yes; then
fi
;;
esac
- KDRIVE_STUB_LIB='$(top_builddir)/hw/kdrive/src/libkdrivestubs.la'
- KDRIVE_LOCAL_LIBS="$MAIN_LIB $DIX_LIB $KDRIVE_LIB $KDRIVE_STUB_LIB"
+ KDRIVE_LOCAL_LIBS="$MAIN_LIB $DIX_LIB $KDRIVE_LIB"
KDRIVE_LOCAL_LIBS="$KDRIVE_LOCAL_LIBS $FB_LIB $MI_LIB $KDRIVE_PURE_LIBS"
KDRIVE_LOCAL_LIBS="$KDRIVE_LOCAL_LIBS $KDRIVE_OS_LIB"
KDRIVE_LIBS="$KDRIVE_LOCAL_LIBS $XSERVER_SYS_LIBS $GLX_SYS_LIBS $DLOPEN_LIBS $TSLIB_LIBS"
diff --git a/dix/globals.c b/dix/globals.c
index 9738e9cdf..eaa2afe24 100644
--- a/dix/globals.c
+++ b/dix/globals.c
@@ -127,7 +127,8 @@ int defaultColorVisualClass = -1;
int monitorResolution = 0;
const char *display;
-int displayfd;
+int displayfd = -1;
+Bool explicit_display = FALSE;
char *ConnectionInfo;
CARD32 TimeOutValue = DEFAULT_TIMEOUT * MILLI_PER_SECOND;
diff --git a/fb/Makefile.am b/fb/Makefile.am
index 89f3babb1..752eabeb7 100644
--- a/fb/Makefile.am
+++ b/fb/Makefile.am
@@ -22,6 +22,7 @@ libfb_la_SOURCES = \
fbbits.h \
fbblt.c \
fbbltone.c \
+ fbcmap_mi.c \
fbcopy.c \
fbfill.c \
fbfillrect.c \
@@ -50,5 +51,3 @@ libfb_la_SOURCES = \
fbwindow.c
libwfb_la_SOURCES = $(libfb_la_SOURCES)
-
-EXTRA_DIST = fbcmap_mi.c
diff --git a/hw/dmx/Makefile.am b/hw/dmx/Makefile.am
index a05af139e..eef84cb66 100644
--- a/hw/dmx/Makefile.am
+++ b/hw/dmx/Makefile.am
@@ -65,7 +65,6 @@ Xdmx_SOURCES = dmx.c \
dmxwindow.c \
dmxwindow.h \
$(top_srcdir)/mi/miinitext.c \
- $(top_srcdir)/fb/fbcmap_mi.c \
$(GLX_SRCS)
diff --git a/hw/kdrive/ephyr/hostx.c b/hw/kdrive/ephyr/hostx.c
index 4f48770a6..435919e0a 100644
--- a/hw/kdrive/ephyr/hostx.c
+++ b/hw/kdrive/ephyr/hostx.c
@@ -734,13 +734,16 @@ hostx_screen_init(KdScreenInfo *screen,
scrpriv->win_width = width;
scrpriv->win_height = height;
+#ifdef GLAMOR
if (ephyr_glamor) {
*bytes_per_line = 0;
*bits_per_pixel = 0;
ephyr_glamor_set_window_size(scrpriv->glamor,
scrpriv->win_width, scrpriv->win_height);
return NULL;
- } else if (host_depth_matches_server(scrpriv)) {
+ } else
+#endif
+ if (host_depth_matches_server(scrpriv)) {
*bytes_per_line = scrpriv->ximg->stride;
*bits_per_pixel = scrpriv->ximg->bpp;
diff --git a/hw/kdrive/src/Makefile.am b/hw/kdrive/src/Makefile.am
index 5799ddbdb..d69f0dd99 100644
--- a/hw/kdrive/src/Makefile.am
+++ b/hw/kdrive/src/Makefile.am
@@ -4,7 +4,7 @@ AM_CPPFLAGS = \
AM_CFLAGS = -DHAVE_DIX_CONFIG_H
-noinst_LTLIBRARIES = libkdrive.la libkdrivestubs.la
+noinst_LTLIBRARIES = libkdrive.la
if XV
KDRIVE_XV_SOURCES = \
@@ -23,6 +23,3 @@ libkdrive_la_SOURCES = \
kshadow.c \
$(KDRIVE_XV_SOURCES) \
$(top_srcdir)/mi/miinitext.c
-
-libkdrivestubs_la_SOURCES = \
- $(top_srcdir)/fb/fbcmap_mi.c
diff --git a/hw/vfb/Makefile.am b/hw/vfb/Makefile.am
index 9f4992c8b..f0f9fee47 100644
--- a/hw/vfb/Makefile.am
+++ b/hw/vfb/Makefile.am
@@ -1,7 +1,6 @@
SUBDIRS = man
bin_PROGRAMS = Xvfb
-noinst_LIBRARIES = libfbcmap.a
AM_CFLAGS = -DHAVE_DIX_CONFIG_H \
$(XVFBMODULES_CFLAGS) \
@@ -9,20 +8,16 @@ AM_CFLAGS = -DHAVE_DIX_CONFIG_H \
SRCS = InitInput.c \
InitOutput.c \
- $(top_srcdir)/Xext/dpmsstubs.c \
- $(top_srcdir)/Xi/stubs.c \
$(top_srcdir)/mi/miinitext.c
-libfbcmap_a_CFLAGS = $(AM_CFLAGS)
-libfbcmap_a_SOURCES = $(top_srcdir)/fb/fbcmap_mi.c
-
Xvfb_SOURCES = $(SRCS)
XVFB_LIBS = \
@XVFB_LIBS@ \
- libfbcmap.a \
$(MAIN_LIB) \
- $(XSERVER_LIBS)
+ $(XSERVER_LIBS) \
+ $(top_builddir)/Xext/libXextdpmsstubs.la \
+ $(top_builddir)/Xi/libXistubs.la
Xvfb_LDADD = $(XVFB_LIBS) $(XVFB_SYS_LIBS) $(XSERVER_SYS_LIBS)
Xvfb_DEPENDENCIES = $(XVFB_LIBS)
diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
index 3c43640ec..dd076e421 100644
--- a/hw/xfree86/dixmods/Makefile.am
+++ b/hw/xfree86/dixmods/Makefile.am
@@ -19,12 +19,12 @@ AM_CPPFLAGS = @XORG_INCS@ \
libfb_la_LDFLAGS = -module -avoid-version $(LD_NO_UNDEFINED_FLAG)
libfb_la_LIBADD = $(top_builddir)/fb/libfb.la
-libfb_la_SOURCES = $(top_builddir)/fb/fbcmap_mi.c fbmodule.c
+libfb_la_SOURCES = fbmodule.c
libfb_la_CFLAGS = $(AM_CFLAGS)
libwfb_la_LDFLAGS = -module -avoid-version $(LD_NO_UNDEFINED_FLAG)
libwfb_la_LIBADD = $(top_builddir)/fb/libwfb.la
-libwfb_la_SOURCES = $(top_builddir)/fb/fbcmap_mi.c fbmodule.c
+libwfb_la_SOURCES = fbmodule.c
libwfb_la_CFLAGS = $(AM_CFLAGS) -DFB_ACCESS_WRAPPER
libglx_la_LDFLAGS = -module -avoid-version $(LD_NO_UNDEFINED_FLAG)
diff --git a/hw/xfree86/parser/DRI.c b/hw/xfree86/parser/DRI.c
index ad053f746..6be32d7ea 100644
--- a/hw/xfree86/parser/DRI.c
+++ b/hw/xfree86/parser/DRI.c
@@ -31,6 +31,7 @@
#include <xorg-config.h>
#endif
+#include "os.h"
#include "xf86Parser.h"
#include "xf86tokens.h"
#include "Configint.h"
diff --git a/hw/xfree86/parser/Extensions.c b/hw/xfree86/parser/Extensions.c
index b5ba72e5f..a6fcb56f0 100644
--- a/hw/xfree86/parser/Extensions.c
+++ b/hw/xfree86/parser/Extensions.c
@@ -35,6 +35,7 @@
#include <xorg-config.h>
#endif
+#include "os.h"
#include "xf86Parser.h"
#include "xf86tokens.h"
#include "Configint.h"
diff --git a/hw/xnest/Makefile.am b/hw/xnest/Makefile.am
index 3c099cd6b..eb550c0f7 100644
--- a/hw/xnest/Makefile.am
+++ b/hw/xnest/Makefile.am
@@ -1,7 +1,6 @@
SUBDIRS = man
bin_PROGRAMS = Xnest
-noinst_LIBRARIES = libfbcmap.a
AM_CFLAGS = -DHAVE_XNEST_CONFIG_H \
$(DIX_CFLAGS) \
@@ -42,16 +41,12 @@ SRCS = Args.c \
XNPixmap.h \
XNWindow.h \
xnest-config.h \
- $(top_srcdir)/Xext/dpmsstubs.c \
- $(top_srcdir)/Xi/stubs.c \
$(top_srcdir)/mi/miinitext.c
-libfbcmap_a_SOURCES = $(top_srcdir)/fb/fbcmap_mi.c
-libfbcmap_a_CFLAGS = $(AM_CFLAGS)
-
XNEST_LIBS = \
@XNEST_LIBS@ \
- libfbcmap.a
+ $(top_builddir)/Xext/libXextdpmsstubs.la \
+ $(top_builddir)/Xi/libXistubs.la
Xnest_SOURCES = $(SRCS)
diff --git a/hw/xquartz/Makefile.am b/hw/xquartz/Makefile.am
index 2ca953cf9..4da896d76 100644
--- a/hw/xquartz/Makefile.am
+++ b/hw/xquartz/Makefile.am
@@ -20,7 +20,6 @@ SUBDIRS = bundle . $(GL_DIR) xpr pbproxy mach-startup man
DIST_SUBDIRS = bundle . GL xpr pbproxy mach-startup man
libXquartz_la_SOURCES = \
- $(top_srcdir)/fb/fbcmap_mi.c \
$(top_srcdir)/mi/miinitext.c \
X11Application.m \
X11Controller.m \
diff --git a/hw/xwin/Makefile.am b/hw/xwin/Makefile.am
index 7f0eaf097..cf42cfd2d 100644
--- a/hw/xwin/Makefile.am
+++ b/hw/xwin/Makefile.am
@@ -127,10 +127,7 @@ SRCS = InitInput.c \
winresource.h \
winwindow.h \
XWin.rc \
- $(top_srcdir)/Xext/dpmsstubs.c \
- $(top_srcdir)/Xi/stubs.c \
$(top_srcdir)/mi/miinitext.c \
- $(top_srcdir)/fb/fbcmap_mi.c \
$(SRCS_CLIPBOARD) \
$(SRCS_MULTIWINDOW) \
$(SRCS_MULTIWINDOWEXTWM) \
@@ -153,12 +150,14 @@ XWin_SOURCES = $(SRCS)
AM_CPPFLAGS = -I$(top_srcdir)/miext/rootless
XWIN_SYS_LIBS += -ldxguid
-XWIN_LIBS += $(top_builddir)/pseudoramiX/libPseudoramiX.la
-
+XWIN_LIBS += $(top_builddir)/pseudoramiX/libPseudoramiX.la \
+ $(top_builddir)/Xext/libXextdpmsstubs.la \
+ $(top_builddir)/Xi/libXistubs.la
XWin_DEPENDENCIES = $(MULTIWINDOWEXTWM_LIBS) $(XWIN_GLX_LIBS) $(XWIN_LIBS) $(XSERVER_LIBS)
XWin_LDADD = $(MULTIWINDOW_LIBS) $(MULTIWINDOWEXTWM_LIBS) $(XWIN_GLX_LIBS) $(XWIN_GLX_LINK_FLAGS) $(XWIN_LIBS) $(MAIN_LIB) $(XSERVER_LIBS) $(XSERVER_SYS_LIBS) $(XWIN_SYS_LIBS)
XWin_LDFLAGS = -mwindows -static -Wl,--disable-stdcall-fixup
+
.rc.o:
$(AM_V_GEN)$(WINDRES) --use-temp-file -i $< --input-format=rc -o $@ -O coff -I $(top_builddir)/include
diff --git a/include/opaque.h b/include/opaque.h
index 7ec1d850f..6b8071c5b 100644
--- a/include/opaque.h
+++ b/include/opaque.h
@@ -51,6 +51,7 @@ extern _X_EXPORT int defaultScreenSaverBlanking;
extern _X_EXPORT int defaultScreenSaverAllowExposures;
extern _X_EXPORT const char *display;
extern _X_EXPORT int displayfd;
+extern _X_EXPORT Bool explicit_display;
extern _X_EXPORT int defaultBackingStore;
extern _X_EXPORT Bool disableBackingStore;
diff --git a/os/connection.c b/os/connection.c
index b3640b8e4..e914d9d94 100644
--- a/os/connection.c
+++ b/os/connection.c
@@ -352,8 +352,8 @@ void
NotifyParentProcess(void)
{
#if !defined(WIN32)
- if (dynamic_display[0]) {
- write(displayfd, dynamic_display, strlen(dynamic_display));
+ if (displayfd >= 0) {
+ write(displayfd, display, strlen(display));
write(displayfd, "\n", 1);
close(displayfd);
}
@@ -405,18 +405,18 @@ CreateWellKnownSockets(void)
FD_ZERO(&WellKnownConnections);
/* display is initialized to "0" by main(). It is then set to the display
- * number if specified on the command line, or to NULL when the -displayfd
- * option is used. */
+ * number if specified on the command line. */
+
if (NoListenAll) {
ListenTransCount = 0;
}
- else if (display) {
+ else if ((displayfd < 0) || explicit_display) {
if (TryCreateSocket(atoi(display), &partial) &&
ListenTransCount >= 1)
if (!PartialNetwork && partial)
FatalError ("Failed to establish all listening sockets");
}
- else { /* -displayfd */
+ else { /* -displayfd and no explicit display number */
Bool found = 0;
for (i = 0; i < 65535 - X_TCP_PORT; i++) {
if (TryCreateSocket(i, &partial) && !partial) {
diff --git a/os/utils.c b/os/utils.c
index c513968ad..6e6974e89 100644
--- a/os/utils.c
+++ b/os/utils.c
@@ -666,6 +666,7 @@ ProcessCommandLine(int argc, char *argv[])
else if (argv[i][0] == ':') {
/* initialize display */
display = argv[i];
+ explicit_display = TRUE;
display++;
if (!VerifyDisplayName(display)) {
ErrorF("Bad display name: %s\n", display);
@@ -736,7 +737,6 @@ ProcessCommandLine(int argc, char *argv[])
else if (strcmp(argv[i], "-displayfd") == 0) {
if (++i < argc) {
displayfd = atoi(argv[i]);
- display = NULL;
#ifdef LOCK_SERVER
nolock = TRUE;
#endif
diff --git a/test/Makefile.am b/test/Makefile.am
index 88fb6aa96..3ad24d9ec 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -70,9 +70,7 @@ endif
else
nodist_libxservertest_la_SOURCES = \
ddxstubs.c \
- $(top_srcdir)/mi/miinitext.c \
- $(top_srcdir)/Xext/dpmsstubs.c \
- $(top_srcdir)/Xi/stubs.c
+ $(top_srcdir)/mi/miinitext.c
libxservertest_la_LIBADD += \
$(top_builddir)/damageext/libdamageext.la \
@@ -83,7 +81,9 @@ libxservertest_la_LIBADD += \
$(top_builddir)/randr/librandr.la \
$(top_builddir)/render/librender.la \
$(top_builddir)/Xext/libXext.la \
+ $(top_builddir)/Xext/libXextdpmsstubs.la \
$(top_builddir)/Xi/libXi.la \
+ $(top_builddir)/Xi/libXistubs.la \
$(top_builddir)/xfixes/libxfixes.la \
$(top_builddir)/xkb/libxkb.la \
$(top_builddir)/xkb/libxkbstubs.la