2005-04-15 Marcus Brinkmann <marcus@g10code.de>
authorMarcus Brinkmann <mb@g10code.com>
Fri, 15 Apr 2005 01:33:46 +0000 (01:33 +0000)
committerMarcus Brinkmann <mb@g10code.com>
Fri, 15 Apr 2005 01:33:46 +0000 (01:33 +0000)
* configure.ac: Add --enable-symcryptrun, disabled by default.
Define automake variable BUILD_SYMCRYPTRUN.
Check for openpty -lutil, define LIBUTIL_LIBS.

tools/
2005-04-15  Marcus Brinkmann  <marcus@g10code.de>

* Makefile.am: Define symcryptrun make variable depending on
BUILD_SYMCRYPTUN.
(bin_PROGRAMS): Add ${symcryptrun} instead symcryptrun.
(symcryptrun_LDADD): Use $(LIBUTIL_LIBS) instead of -lutil.

ChangeLog
configure.ac
tools/ChangeLog
tools/Makefile.am

index c9f9fe3..8e23a3d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2005-04-15  Marcus Brinkmann  <marcus@g10code.de>
+
+       * configure.ac: Add --enable-symcryptrun, disabled by default.
+       Define automake variable BUILD_SYMCRYPTRUN.
+       Check for openpty -lutil, define LIBUTIL_LIBS.
+
 2005-03-03  Werner Koch  <wk@g10code.com>
 
        * acinclude.m4 (GNUPG_PTH_VERSION_CHECK): Accidently used
index 7462a75..34463da 100644 (file)
@@ -66,6 +66,7 @@ GNUPG_BUILD_PROGRAM(gpg, yes)
 GNUPG_BUILD_PROGRAM(gpgsm, yes)
 GNUPG_BUILD_PROGRAM(agent, yes)
 GNUPG_BUILD_PROGRAM(scdaemon, yes)
+GNUPG_BUILD_PROGRAM(symcryptrun, no)
 
 
 AC_SUBST(PACKAGE)
@@ -469,6 +470,16 @@ AC_SUBST(LIBUSB_LIBS)
 AC_CHECK_FUNCS(usb_create_match)
 
 #
+# libutil has openpty() and login_tty().
+#
+AC_CHECK_LIB(util, openpty,
+              [ LIBUTIL_LIBS="$LIBUTIL_LIBS -lutil"
+                AC_DEFINE(HAVE_LIBUTIL,1,
+                         [defined if libutil is available])
+             ])
+AC_SUBST(LIBUTIL_LIBS)
+
+#
 # Check wether it is necessary to link against libdl.
 #
 LIBS=""
@@ -1046,6 +1057,7 @@ AM_CONDITIONAL(BUILD_GPG,   test "$build_gpg" = "yes")
 AM_CONDITIONAL(BUILD_GPGSM, test "$build_gpgsm" = "yes")
 AM_CONDITIONAL(BUILD_AGENT, test "$build_agent" = "yes")
 AM_CONDITIONAL(BUILD_SCDAEMON, test "$build_scdaemon" = "yes")
+AM_CONDITIONAL(BUILD_SYMCRYPTRUN, test "$build_symcryptrun" = "yes")
 
 
 
index 82f26d0..d6280b7 100644 (file)
@@ -1,3 +1,10 @@
+2005-04-15  Marcus Brinkmann  <marcus@g10code.de>
+
+       * Makefile.am: Define symcryptrun make variable depending on
+       BUILD_SYMCRYPTUN.
+       (bin_PROGRAMS): Add ${symcryptrun} instead symcryptrun.
+       (symcryptrun_LDADD): Use $(LIBUTIL_LIBS) instead of -lutil.
+
 2005-04-11  Werner Koch  <wk@g10code.com>
 
        * symcryptrun.c (confucius_mktmpdir): Changed to use mkdtmp(3).
index 2616d69..b0a4779 100644 (file)
@@ -30,7 +30,13 @@ sbin_SCRIPTS = addgnupghome
 
 bin_SCRIPTS = gpgsm-gencert.sh
 
-bin_PROGRAMS = gpgconf gpg-connect-agent symcryptrun
+if BUILD_SYMCRYPTRUN
+  symcryptrun = symcryptrun
+else
+  symcryptrun =
+endif
+
+bin_PROGRAMS = gpgconf gpg-connect-agent ${symcryptrun}
 if !HAVE_W32_SYSTEM
 bin_PROGRAMS += watchgnupg
 endif
@@ -40,7 +46,7 @@ gpgconf_SOURCES = gpgconf.c gpgconf.h gpgconf-comp.c no-libgcrypt.c
 gpgconf_LDADD = ../jnlib/libjnlib.a ../common/libcommon.a @LIBINTL@
 
 symcryptrun_SOURCES = symcryptrun.c
-symcryptrun_LDADD = -lutil ../jnlib/libjnlib.a ../common/libcommon.a \
+symcryptrun_LDADD = $(LIBUTIL_LIBS) ../jnlib/libjnlib.a ../common/libcommon.a \
                    ../common/libsimple-pwquery.a $(LIBGCRYPT_LIBS) \
                    $(GPG_ERROR_LIBS) $(LIBINTL)