Author: ekohl
Date: Wed Sep 3 15:57:51 2008
New Revision: 35916
URL:
http://svn.reactos.org/svn/reactos?rev=35916&view=rev
Log:
Add a spooler service skeleton. Now the Service-Winetests can be used unmodified.
Added:
trunk/reactos/base/services/spoolsv/ (with props)
trunk/reactos/base/services/spoolsv/spoolsv.c (with props)
trunk/reactos/base/services/spoolsv/spoolsv.rbuild (with props)
trunk/reactos/base/services/spoolsv/spoolsv.rc (with props)
Modified:
trunk/reactos/base/services/services.rbuild
Modified: trunk/reactos/base/services/services.rbuild
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/services/services.rbu…
==============================================================================
--- trunk/reactos/base/services/services.rbuild [iso-8859-1] (original)
+++ trunk/reactos/base/services/services.rbuild [iso-8859-1] Wed Sep 3 15:57:51 2008
@@ -13,6 +13,9 @@
<directory name="rpcss">
<xi:include href="rpcss/rpcss.rbuild" />
</directory>
+ <directory name="spoolsv">
+ <xi:include href="spoolsv/spoolsv.rbuild" />
+ </directory>
<directory name="svchost">
<xi:include href="svchost/svchost.rbuild" />
</directory>
Propchange: trunk/reactos/base/services/spoolsv/
------------------------------------------------------------------------------
--- bugtraq:logregex (added)
+++ bugtraq:logregex Wed Sep 3 15:57:51 2008
@@ -1,0 +1,2 @@
+([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))?
+(\d+)
Propchange: trunk/reactos/base/services/spoolsv/
------------------------------------------------------------------------------
bugtraq:message = See issue #%BUGID% for more details.
Propchange: trunk/reactos/base/services/spoolsv/
------------------------------------------------------------------------------
bugtraq:url =
http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: trunk/reactos/base/services/spoolsv/
------------------------------------------------------------------------------
tsvn:logminsize = 10
Added: trunk/reactos/base/services/spoolsv/spoolsv.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/services/spoolsv/spoo…
==============================================================================
--- trunk/reactos/base/services/spoolsv/spoolsv.c (added)
+++ trunk/reactos/base/services/spoolsv/spoolsv.c [iso-8859-1] Wed Sep 3 15:57:51 2008
@@ -1,0 +1,87 @@
+/*
+ * COPYRIGHT: See COPYING in the top level directory
+ * PROJECT: ReactOS kernel
+ * FILE: services/spoolsv/spoolsv.c
+ * PURPOSE: Printer spooler
+ * PROGRAMMER: Eric Kohl
+ */
+
+/* INCLUDES *****************************************************************/
+
+#define WIN32_NO_STATUS
+#include <windows.h>
+
+#define NDEBUG
+#include <debug.h>
+
+/* GLOBALS ******************************************************************/
+
+#define SERVICE_NAME TEXT("Spooler")
+
+SERVICE_STATUS_HANDLE ServiceStatusHandle;
+
+
+/* FUNCTIONS *****************************************************************/
+
+
+static DWORD WINAPI
+ServiceControlHandler(DWORD dwControl,
+ DWORD dwEventType,
+ LPVOID lpEventData,
+ LPVOID lpContext)
+{
+ switch (dwControl)
+ {
+ case SERVICE_CONTROL_STOP:
+ case SERVICE_CONTROL_SHUTDOWN:
+ return ERROR_SUCCESS;
+
+ default :
+ return ERROR_CALL_NOT_IMPLEMENTED;
+ }
+}
+
+
+
+static VOID CALLBACK
+ServiceMain(DWORD argc, LPTSTR *argv)
+{
+ UNREFERENCED_PARAMETER(argc);
+ UNREFERENCED_PARAMETER(argv);
+
+ DPRINT("ServiceMain() called\n");
+
+ ServiceStatusHandle = RegisterServiceCtrlHandlerExW(SERVICE_NAME,
+ ServiceControlHandler,
+ NULL);
+
+
+
+ DPRINT("ServiceMain() done\n");
+}
+
+
+int
+wmain(int argc, WCHAR *argv[])
+{
+ SERVICE_TABLE_ENTRY ServiceTable[2] =
+ {
+ {SERVICE_NAME, ServiceMain},
+ {NULL, NULL}
+ };
+
+ UNREFERENCED_PARAMETER(argc);
+ UNREFERENCED_PARAMETER(argv);
+
+ DPRINT("Spoolsv: main() started\n");
+
+ StartServiceCtrlDispatcher(ServiceTable);
+
+ DPRINT("Spoolsv: main() done\n");
+
+ ExitThread(0);
+
+ return 0;
+}
+
+/* EOF */
Propchange: trunk/reactos/base/services/spoolsv/spoolsv.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: trunk/reactos/base/services/spoolsv/spoolsv.rbuild
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/services/spoolsv/spoo…
==============================================================================
--- trunk/reactos/base/services/spoolsv/spoolsv.rbuild (added)
+++ trunk/reactos/base/services/spoolsv/spoolsv.rbuild [iso-8859-1] Wed Sep 3 15:57:51
2008
@@ -1,0 +1,13 @@
+<?xml version="1.0"?>
+<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
+<module name="spoolsv" type="win32cui"
installbase="system32" installname="spoolsv.exe"
unicode="yes">
+ <include base="spoolsv">.</include>
+ <define name="WINVER">0x600</define>
+ <define name="_WIN32_IE">0x0500</define>
+ <define name="_WIN32_WINNT">0x0600</define>
+ <library>ntdll</library>
+ <library>kernel32</library>
+ <library>advapi32</library>
+ <file>spoolsv.c</file>
+ <file>spoolsv.rc</file>
+</module>
Propchange: trunk/reactos/base/services/spoolsv/spoolsv.rbuild
------------------------------------------------------------------------------
svn:eol-style = native
Added: trunk/reactos/base/services/spoolsv/spoolsv.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/services/spoolsv/spoo…
==============================================================================
--- trunk/reactos/base/services/spoolsv/spoolsv.rc (added)
+++ trunk/reactos/base/services/spoolsv/spoolsv.rc [iso-8859-1] Wed Sep 3 15:57:51 2008
@@ -1,0 +1,4 @@
+#define REACTOS_STR_FILE_DESCRIPTION "Spooler-Service\0"
+#define REACTOS_STR_INTERNAL_NAME "Spoolsv\0"
+#define REACTOS_STR_ORIGINAL_FILENAME "Spoolsv.exe\0"
+#include <reactos/version.rc>
Propchange: trunk/reactos/base/services/spoolsv/spoolsv.rc
------------------------------------------------------------------------------
svn:eol-style = native