Author: jmagne
Update of /cvs/dirsec/esc/src/lib/coolkey
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv22673/src/lib/coolkey
Modified Files:
CoolKey.cpp Mac-universal.mk SmartCardMonitoringThread.cpp
common.mk
Log Message:
Bug 369031 - ESC incompatible with OS X Leopard.
Index: CoolKey.cpp
===================================================================
RCS file: /cvs/dirsec/esc/src/lib/coolkey/CoolKey.cpp,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- CoolKey.cpp 19 Jun 2009 21:03:40 -0000 1.11
+++ CoolKey.cpp 17 Mar 2010 00:43:54 -0000 1.12
@@ -1107,9 +1107,7 @@
goto done;
}
-#ifndef DARWIN
CKYCardConnection_BeginTransaction(conn);
-#endif
apduRC = 0;
status = CKYApplet_SelectCoolKeyManager(conn, &apduRC);
if (status != CKYSUCCESS) {
@@ -1154,9 +1152,7 @@
done:
if (conn) {
-#ifndef DARWIN
CKYCardConnection_EndTransaction(conn);
-#endif
CKYCardConnection_Disconnect(conn);
CKYCardConnection_Destroy(conn);
}
Index: Mac-universal.mk
===================================================================
RCS file: /cvs/dirsec/esc/src/lib/coolkey/Mac-universal.mk,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- Mac-universal.mk 19 Jan 2007 22:29:24 -0000 1.2
+++ Mac-universal.mk 17 Mar 2010 00:43:54 -0000 1.3
@@ -31,14 +31,13 @@
mkdir -p $(UNIVERSAL_OFFSET_PPC)
mkdir -p $(UNIVERSAL_OFFSET_386)
- sudo gcc_select 4.0
+
echo "Build i386."
make -f common.mk OSX_ARCH_FLAGS="-arch i386 -isysroot
/Developer/SDKs/MacOSX10.4u.sdk"
cp $(OBJDIR)/$(DARWIN_LIB_NAME) $(UNIVERSAL_OFFSET_386)
make -f common.mk clean
- sudo gcc_select 3.3
echo "Build ppc."
make -f common.mk OSX_ARCH_FLAGS="-arch ppc"
cp $(OBJDIR)/$(DARWIN_LIB_NAME) $(UNIVERSAL_OFFSET_PPC)
@@ -48,8 +47,6 @@
ranlib $(OBJDIR)/$(DARWIN_LIB_NAME)
make -f common.mk install
- sudo gcc_select 4.0
-
clean:
"Darwing clean."
make -f common.mk clean
Index: SmartCardMonitoringThread.cpp
===================================================================
RCS file: /cvs/dirsec/esc/src/lib/coolkey/SmartCardMonitoringThread.cpp,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- SmartCardMonitoringThread.cpp 17 Nov 2009 23:44:37 -0000 1.6
+++ SmartCardMonitoringThread.cpp 17 Mar 2010 00:43:54 -0000 1.7
@@ -159,6 +159,12 @@
PR_LOG( coolKeyLogSC, PR_LOG_DEBUG,
("%s SmartCardMonitoringThread::info %p :
\n",GetTStamp(tBuff,56),info));
+ // On Mac give the tokend a chance before hitting PK11_IsPresent
+
+ #ifdef DARWIN
+ PR_Sleep(PR_SecondsToInterval(1));
+ #endif
+
PRBool isPresent = PK11_IsPresent(slot);
PR_LOG( coolKeyLogSC, PR_LOG_DEBUG,
Index: common.mk
===================================================================
RCS file: /cvs/dirsec/esc/src/lib/coolkey/common.mk,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- common.mk 2 Feb 2007 23:56:45 -0000 1.2
+++ common.mk 17 Mar 2010 00:43:54 -0000 1.3
@@ -43,10 +43,6 @@
DEFINES += -DDLL_PREFIX=\"$(DLL_PREFIX)\"
DEFINES += -DDLL_SUFFIX=\"$(DLL_SUFFIX)\"
-ifdef DARWIN_GCC_VERSION
- echo "blooie"
- sudo gcc_select $(GCC_VERSION)
-endif
#######################################################################
# (4) Include "local" platform-dependent assignments (OPTIONAL). #