[PATCH 11/37] Move DPMS from extmod to built-in

Daniel Stone daniel at fooishbar.org
Tue Jun 28 12:27:27 PDT 2011


From: Tomas Carnecky <tom at dbservice.com>

Always build DPMS support into the core server, rather than letting it
languish in extmod.

Signed-off-by: Tomas Carnecky <tom at dbservice.com>
Reviewed-by: Daniel Stone <daniel at fooishbar.org>
---
 Xext/Makefile.am                    |    2 +-
 Xext/dpms.c                         |    2 ++
 hw/xfree86/dixmods/extmod/modinit.c |    9 ---------
 mi/miinitext.c                      |    6 ++++++
 4 files changed, 9 insertions(+), 10 deletions(-)

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index a443a64..adea06e 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -103,7 +103,7 @@ endif
 # DPMS extension
 DPMS_SRCS = dpms.c dpmsproc.h
 if DPMSExtension
-MODULE_SRCS += $(DPMS_SRCS)
+BUILTIN_SRCS += $(DPMS_SRCS)
 endif
 
 # Now take all of the above, mix well, bake for 10 minutes and get libXext*.la
diff --git a/Xext/dpms.c b/Xext/dpms.c
index 32f33b3..d09fd0a 100644
--- a/Xext/dpms.c
+++ b/Xext/dpms.c
@@ -41,6 +41,8 @@ Equipment Corporation.
 #include "dpmsproc.h"
 #include "modinit.h"
 
+extern void DPMSExtensionInit(void);
+
 static int
 ProcDPMSGetVersion(ClientPtr client)
 {
diff --git a/hw/xfree86/dixmods/extmod/modinit.c b/hw/xfree86/dixmods/extmod/modinit.c
index 4441899..6625f26 100644
--- a/hw/xfree86/dixmods/extmod/modinit.c
+++ b/hw/xfree86/dixmods/extmod/modinit.c
@@ -65,15 +65,6 @@ static ExtensionModule extensionModules[] = {
 	NULL
     },
 #endif
-#ifdef DPMSExtension
-    {
-	DPMSExtensionInit,
-	DPMSExtensionName,
-	&noDPMSExtension,
-	NULL,
-	NULL
-    },
-#endif
 #ifdef XV
     {
 	XvExtensionInit,
diff --git a/mi/miinitext.c b/mi/miinitext.c
index c75c140..79786aa 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -186,6 +186,9 @@ typedef void (*InitExtension)(void);
 #ifdef SCREENSAVER
 #include <X11/extensions/saver.h>
 #endif
+#ifdef DPMSExtension
+#include <X11/extensions/dpmsconst.h>
+#endif
 
 /* FIXME: this whole block of externs should be from the appropriate headers */
 #ifdef MITSHM
@@ -524,6 +527,9 @@ static ExtensionModule staticExtensions[] = {
 #ifdef XRECORD
     { RecordExtensionInit, "RECORD", &noTestExtensions, NULL },
 #endif
+#ifdef DPMSExtension
+    { DPMSExtensionInit, DPMSExtensionName, &noDPMSExtension, NULL },
+#endif
     { NULL, NULL, NULL, NULL, NULL }
 };
     
-- 
1.7.5.4



More information about the xorg-devel mailing list