Mounir IDRASSI : winscard: Small initial stub implementation.
Alexandre Julliard
julliard at wine.codeweavers.com
Wed May 23 08:10:56 CDT 2007
Module: wine
Branch: master
Commit: 23df68d8f96d2c4f6f6a0bf522c5bce77fb51c97
URL: http://source.winehq.org/git/wine.git/?a=commit;h=23df68d8f96d2c4f6f6a0bf522c5bce77fb51c97
Author: Mounir IDRASSI <mounir.idrassi at idrix.fr>
Date: Wed May 23 00:51:46 2007 +0200
winscard: Small initial stub implementation.
---
.gitignore | 2 +
Makefile.in | 2 +
configure | 3 ++
configure.ac | 1 +
dlls/Makefile.in | 5 +++
dlls/winscard/Makefile.in | 17 +++++++++++
dlls/winscard/rsrc.rc | 33 ++++++++++++++++++++++
dlls/winscard/winscard.c | 52 +++++++++++++++++++++++++++++++++++
dlls/winscard/winscard.spec | 63 +++++++++++++++++++++++++++++++++++++++++++
9 files changed, 178 insertions(+), 0 deletions(-)
diff --git a/.gitignore b/.gitignore
index af69a26..be4fb6f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -652,6 +652,8 @@ dlls/winmm/tests/winmm_crosstest.exe
dlls/winmm/winmm_res.res
dlls/winnls.dll16
dlls/winnls32/libwinnls32.def
+dlls/winscard/libwinscard.def
+dlls/winscard/rsrc.res
dlls/winsock.dll16
dlls/winspool.drv/libwinspool.def
dlls/winspool.drv/tests/*.ok
diff --git a/Makefile.in b/Makefile.in
index 3b16428..6c9bdef 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -419,6 +419,7 @@ ALL_MAKEFILES = \
dlls/winmm/Makefile \
dlls/winmm/tests/Makefile \
dlls/winnls32/Makefile \
+ dlls/winscard/Makefile \
dlls/winspool.drv/Makefile \
dlls/winspool.drv/tests/Makefile \
dlls/wintab32/Makefile \
@@ -768,6 +769,7 @@ dlls/wininet/tests/Makefile: dlls/wininet/tests/Makefile.in dlls/Maketest.rules
dlls/winmm/Makefile: dlls/winmm/Makefile.in dlls/Makedll.rules
dlls/winmm/tests/Makefile: dlls/winmm/tests/Makefile.in dlls/Maketest.rules
dlls/winnls32/Makefile: dlls/winnls32/Makefile.in dlls/Makedll.rules
+dlls/winscard/Makefile: dlls/winscard/Makefile.in dlls/Makedll.rules
dlls/winspool.drv/Makefile: dlls/winspool.drv/Makefile.in dlls/Makedll.rules
dlls/winspool.drv/tests/Makefile: dlls/winspool.drv/tests/Makefile.in dlls/Maketest.rules
dlls/wintab32/Makefile: dlls/wintab32/Makefile.in dlls/Makedll.rules
diff --git a/configure b/configure
index f6034fe..822c1bc 100755
--- a/configure
+++ b/configure
@@ -20907,6 +20907,8 @@ ac_config_files="$ac_config_files dlls/winmm/tests/Makefile"
ac_config_files="$ac_config_files dlls/winnls32/Makefile"
+ac_config_files="$ac_config_files dlls/winscard/Makefile"
+
ac_config_files="$ac_config_files dlls/winspool.drv/Makefile"
ac_config_files="$ac_config_files dlls/winspool.drv/tests/Makefile"
@@ -21880,6 +21882,7 @@ do
"dlls/winmm/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/Makefile" ;;
"dlls/winmm/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/tests/Makefile" ;;
"dlls/winnls32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winnls32/Makefile" ;;
+ "dlls/winscard/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winscard/Makefile" ;;
"dlls/winspool.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winspool.drv/Makefile" ;;
"dlls/winspool.drv/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winspool.drv/tests/Makefile" ;;
"dlls/wintab32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wintab32/Makefile" ;;
diff --git a/configure.ac b/configure.ac
index 22de21f..8c9b427 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1749,6 +1749,7 @@ AC_CONFIG_FILES([dlls/wininet/tests/Makefile])
AC_CONFIG_FILES([dlls/winmm/Makefile])
AC_CONFIG_FILES([dlls/winmm/tests/Makefile])
AC_CONFIG_FILES([dlls/winnls32/Makefile])
+AC_CONFIG_FILES([dlls/winscard/Makefile])
AC_CONFIG_FILES([dlls/winspool.drv/Makefile])
AC_CONFIG_FILES([dlls/winspool.drv/tests/Makefile])
AC_CONFIG_FILES([dlls/wintab32/Makefile])
diff --git a/dlls/Makefile.in b/dlls/Makefile.in
index 159bb2d..5bb4e3a 100644
--- a/dlls/Makefile.in
+++ b/dlls/Makefile.in
@@ -207,6 +207,7 @@ BASEDIRS = \
wininet \
winmm \
winnls32 \
+ winscard \
winspool.drv \
wintab32 \
wintrust \
@@ -574,6 +575,7 @@ IMPORT_LIBS = \
wininet/libwininet.$(IMPLIBEXT) \
winmm/libwinmm.$(IMPLIBEXT) \
winnls32/libwinnls32.$(IMPLIBEXT) \
+ winscard/libwinscard.$(IMPLIBEXT) \
winspool.drv/libwinspool.$(IMPLIBEXT) \
wintab32/libwintab32.$(IMPLIBEXT) \
wintrust/libwintrust.$(IMPLIBEXT) \
@@ -927,6 +929,9 @@ winmm/libwinmm.$(IMPLIBEXT): winmm/winmm.spec $(WINEBUILD)
winnls32/libwinnls32.$(IMPLIBEXT): winnls32/winnls32.spec $(WINEBUILD)
@cd winnls32 && $(MAKE) libwinnls32.$(IMPLIBEXT)
+winscard/libwinscard.$(IMPLIBEXT): winscard/winscard.spec $(WINEBUILD)
+ @cd winscard && $(MAKE) libwinscard.$(IMPLIBEXT)
+
winspool.drv/libwinspool.$(IMPLIBEXT): winspool.drv/winspool.drv.spec $(WINEBUILD)
@cd winspool.drv && $(MAKE) libwinspool.$(IMPLIBEXT)
diff --git a/dlls/winscard/Makefile.in b/dlls/winscard/Makefile.in
new file mode 100644
index 0000000..de8a2b6
--- /dev/null
+++ b/dlls/winscard/Makefile.in
@@ -0,0 +1,17 @@
+TOPSRCDIR = @top_srcdir@
+TOPOBJDIR = ../..
+SRCDIR = @srcdir@
+VPATH = @srcdir@
+MODULE = winscard.dll
+IMPORTLIB = libwinscard.$(IMPLIBEXT)
+IMPORTS = kernel32
+
+C_SRCS = \
+ winscard.c
+
+RC_SRCS = \
+ rsrc.rc
+
+ at MAKE_DLL_RULES@
+
+ at DEPENDENCIES@ # everything below this line is overwritten by make depend
diff --git a/dlls/winscard/rsrc.rc b/dlls/winscard/rsrc.rc
new file mode 100644
index 0000000..8226e9d
--- /dev/null
+++ b/dlls/winscard/rsrc.rc
@@ -0,0 +1,33 @@
+/*
+ * Top level resource file for winscard.dll
+ *
+ * Copyright 2007 Mounir IDRASSI (mounir.idrassi at idrix.fr, for IDRIX)
+ *
+ * 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
+ */
+
+#include "windef.h"
+#include "winbase.h"
+#include "winuser.h"
+#include "winver.h"
+
+LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
+
+#define WINE_FILEDESCRIPTION_STR "Wine Smart Card API"
+#define WINE_FILENAME_STR "winscard.dll"
+#define WINE_FILEVERSION 5,1,2600,2180
+#define WINE_FILEVERSION_STR "5.1.2600.2180"
+
+#include "wine/wine_common_ver.rc"
diff --git a/dlls/winscard/winscard.c b/dlls/winscard/winscard.c
new file mode 100644
index 0000000..d24e0f9
--- /dev/null
+++ b/dlls/winscard/winscard.c
@@ -0,0 +1,52 @@
+/*
+ * Copyright 2007 Mounir IDRASSI (mounir.idrassi at idrix.fr, for IDRIX)
+ *
+ * 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
+ */
+
+#include "config.h"
+#include <stdarg.h>
+#include "windef.h"
+#include "winbase.h"
+#include "wine/debug.h"
+#include <winscard.h>
+
+WINE_DEFAULT_DEBUG_CHANNEL(winscard);
+
+static HMODULE WINSCARD_hModule;
+
+const SCARD_IO_REQUEST g_rgSCardT0Pci = { SCARD_PROTOCOL_T0, 8 };
+const SCARD_IO_REQUEST g_rgSCardT1Pci = { SCARD_PROTOCOL_T1, 8 };
+const SCARD_IO_REQUEST g_rgSCardRawPci = { SCARD_PROTOCOL_RAW, 8 };
+
+
+BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
+{
+ TRACE("%p,%x,%p\n", hinstDLL, fdwReason, lpvReserved);
+
+ switch (fdwReason)
+ {
+ case DLL_PROCESS_ATTACH:
+ {
+ DisableThreadLibraryCalls(hinstDLL);
+ WINSCARD_hModule = hinstDLL;
+ break;
+ }
+ case DLL_PROCESS_DETACH:
+ break;
+ }
+
+ return TRUE;
+}
diff --git a/dlls/winscard/winscard.spec b/dlls/winscard/winscard.spec
new file mode 100644
index 0000000..6dd83d8
--- /dev/null
+++ b/dlls/winscard/winscard.spec
@@ -0,0 +1,63 @@
+@ stub ClassInstall32
+@ stub SCardAccessNewReaderEvent
+@ stub SCardReleaseAllEvents
+@ stub SCardReleaseNewReaderEvent
+@ stub SCardAccessStartedEvent
+@ stub SCardAddReaderToGroupA
+@ stub SCardAddReaderToGroupW
+@ stub SCardBeginTransaction
+@ stub SCardCancel
+@ stub SCardConnectA
+@ stub SCardConnectW
+@ stub SCardControl
+@ stub SCardDisconnect
+@ stub SCardEndTransaction
+@ stub SCardEstablishContext
+@ stub SCardForgetCardTypeA
+@ stub SCardForgetCardTypeW
+@ stub SCardForgetReaderA
+@ stub SCardForgetReaderGroupA
+@ stub SCardForgetReaderGroupW
+@ stub SCardForgetReaderW
+@ stub SCardFreeMemory
+@ stub SCardGetAttrib
+@ stub SCardGetCardTypeProviderNameA
+@ stub SCardGetCardTypeProviderNameW
+@ stub SCardGetProviderIdA
+@ stub SCardGetProviderIdW
+@ stub SCardGetStatusChangeA
+@ stub SCardGetStatusChangeW
+@ stub SCardIntroduceCardTypeA
+@ stub SCardIntroduceCardTypeW
+@ stub SCardIntroduceReaderA
+@ stub SCardIntroduceReaderGroupA
+@ stub SCardIntroduceReaderGroupW
+@ stub SCardIntroduceReaderW
+@ stub SCardIsValidContext
+@ stub SCardListCardsA
+@ stub SCardListCardsW
+@ stub SCardListInterfacesA
+@ stub SCardListInterfacesW
+@ stub SCardListReaderGroupsA
+@ stub SCardListReaderGroupsW
+@ stub SCardListReadersA
+@ stub SCardListReadersW
+@ stub SCardLocateCardsA
+@ stub SCardLocateCardsByATRA
+@ stub SCardLocateCardsByATRW
+@ stub SCardLocateCardsW
+@ stub SCardReconnect
+@ stub SCardReleaseContext
+@ stub SCardReleaseStartedEvent
+@ stub SCardRemoveReaderFromGroupA
+@ stub SCardRemoveReaderFromGroupW
+@ stub SCardSetAttrib
+@ stub SCardSetCardTypeProviderNameA
+@ stub SCardSetCardTypeProviderNameW
+@ stub SCardState
+@ stub SCardStatusA
+@ stub SCardStatusW
+@ stub SCardTransmit
+@ extern g_rgSCardRawPci
+@ extern g_rgSCardT0Pci
+@ extern g_rgSCardT1Pci
More information about the wine-cvs
mailing list