dxdiag: add stub implementation

Austin English austinenglish at gmail.com
Mon Aug 24 11:18:26 CDT 2009


Clean approach to bug 14118. This simply adds a stub exe which returns
0. I've tested GameShadow, which seems to be a bit happier when this
is added. To verify, I added tracing in the stub exe and verified that
GameShadow does indeed call it.

-- 
-Austin
-------------- next part --------------
diff --git a/configure.ac b/configure.ac
index 4b37e5f..015f6ba 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2517,6 +2517,7 @@ WINE_CONFIG_MAKEFILE([programs/clock/Makefile],[programs/Makeprog.rules],[progra
 WINE_CONFIG_MAKEFILE([programs/cmd/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS,ALL_PROGRAM_INSTALL_DIRS])
 WINE_CONFIG_MAKEFILE([programs/cmdlgtst/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS])
 WINE_CONFIG_MAKEFILE([programs/control/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS,ALL_PROGRAM_INSTALL_DIRS])
+WINE_CONFIG_MAKEFILE([programs/dxdiag/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS,ALL_PROGRAM_INSTALL_DIRS])
 WINE_CONFIG_MAKEFILE([programs/eject/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS,ALL_PROGRAM_INSTALL_DIRS])
 WINE_CONFIG_MAKEFILE([programs/expand/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS,ALL_PROGRAM_INSTALL_DIRS])
 WINE_CONFIG_MAKEFILE([programs/explorer/Makefile],[programs/Makeprog.rules],[programs],[ALL_PROGRAM_DIRS,ALL_PROGRAM_INSTALL_DIRS])
diff --git a/programs/dxdiag/Makefile.in b/programs/dxdiag/Makefile.in
new file mode 100644
index 0000000..2e7e7b0
--- /dev/null
+++ b/programs/dxdiag/Makefile.in
@@ -0,0 +1,15 @@
+EXTRADEFS = -DWINE_NO_UNICODE_MACROS
+TOPSRCDIR = @top_srcdir@
+TOPOBJDIR = ../..
+SRCDIR    = @srcdir@
+VPATH     = @srcdir@
+MODULE    = dxdiag.exe
+APPMODE   = -mwindows
+IMPORTS   = kernel32
+
+C_SRCS = \
+	main.c
+
+ at MAKE_PROG_RULES@
+
+ at DEPENDENCIES@  # everything below this line is overwritten by make depend
diff --git a/programs/dxdiag/main.c b/programs/dxdiag/main.c
new file mode 100644
index 0000000..dbff571
--- /dev/null
+++ b/programs/dxdiag/main.c
@@ -0,0 +1,28 @@
+/*
+ * DxDiag Implementation
+ *
+ * Copyright 2009 Austin English
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#define WIN32_LEAN_AND_MEAN
+#include <windows.h>
+
+int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR cmdline, int cmdshow)
+{
+    return 0;
+}
+
-- 
1.5.6.3


More information about the wine-patches mailing list