summaryrefslogtreecommitdiffstats
path: root/scd/scdaemon.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2004-07-22 12:52:56 +0200
committerWerner Koch <wk@gnupg.org>2004-07-22 12:52:56 +0200
commit44bf2d0ae4adbcf5b6b404bfc6526c461ae6a92a (patch)
tree6f2a43756a965f1c36194b4c91781555ba4701a0 /scd/scdaemon.c
parent* trustlist.c (read_list): Allow colons in the fingerprint. (diff)
downloadgnupg2-44bf2d0ae4adbcf5b6b404bfc6526c461ae6a92a.tar.xz
gnupg2-44bf2d0ae4adbcf5b6b404bfc6526c461ae6a92a.zip
* configure.ac: Define AM conditional HAVE_OPENSC.V1-9-10
* Makefile.am: Make OpenSC lib link after libgcrypt. Do not link to pth. * apdu.c: Don't use Pth if we use OpenSC. * sc-investigate.c, scdaemon.c: Disable use of pth if OpenSC is used. * scdaemon.c (main): Bumbed thread stack size up to 512k.
Diffstat (limited to 'scd/scdaemon.c')
-rw-r--r--scd/scdaemon.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/scd/scdaemon.c b/scd/scdaemon.c
index b0038de16..f647aecc2 100644
--- a/scd/scdaemon.c
+++ b/scd/scdaemon.c
@@ -144,13 +144,14 @@ static int maybe_setuid = 1;
static char socket_name[128];
+#ifndef HAVE_OPENSC
#ifdef USE_GNU_PTH
/* Pth wrapper function definitions. */
GCRY_THREAD_OPTION_PTH_IMPL;
static void *ticker_thread (void *arg);
#endif /*USE_GNU_PTH*/
-
+#endif /*!HAVE_OPENSC*/
static const char *
my_strusage (int level)
@@ -336,6 +337,7 @@ main (int argc, char **argv )
/* Libgcrypt requires us to register the threading model first.
Note that this will also do the pth_init. */
+#ifndef HAVE_OPENSC
#ifdef USE_GNU_PTH
err = gcry_control (GCRYCTL_SET_THREAD_CBS, &gcry_threads_pth);
if (err)
@@ -344,6 +346,7 @@ main (int argc, char **argv )
gpg_strerror (err));
}
#endif /*USE_GNU_PTH*/
+#endif /*!HAVE_OPENSC*/
/* Check that the libraries are suitable. Do it here because
the option parsing may need services of the library */
@@ -598,6 +601,7 @@ main (int argc, char **argv )
if (pipe_server)
{ /* This is the simple pipe based server */
+#ifndef HAVE_OPENSC
#ifdef USE_GNU_PTH
pth_attr_t tattr;
@@ -612,6 +616,7 @@ main (int argc, char **argv )
scd_exit (2);
}
#endif /*USE_GNU_PTH*/
+#endif /*!HAVE_OPENSC*/
scd_command_handler (-1);
}
else if (!is_daemon)
@@ -827,6 +832,7 @@ scd_init_default_ctrl (CTRL ctrl)
}
+#ifndef HAVE_OPENSC
#ifdef USE_GNU_PTH
static void
@@ -931,3 +937,4 @@ ticker_thread (void *dummy_arg)
pth_event_free (sigs_ev, PTH_FREE_ALL);
}
#endif /*USE_GNU_PTH*/
+#endif /*!HAVE_OPENSC*/