1
0
mirror of git://git.gnupg.org/gnupg.git synced 2025-01-03 12:11:33 +01:00

Some cleanup so we don't build files that are completely ifdeffed out.

This causes a warning on Sun's cc.  Do the internal regex code as well for
consistency.
This commit is contained in:
David Shaw 2005-12-06 20:54:05 +00:00
parent 8a0cf1d2a3
commit bc1c4af8c3
4 changed files with 37 additions and 22 deletions

View File

@ -469,6 +469,8 @@ case "${host}" in
need_dlopen=no need_dlopen=no
try_gettext="no" try_gettext="no"
agent_support=no agent_support=no
use_simple_gettext=yes
have_w32_system=yes
;; ;;
i?86-emx-os2 | i?86-*-os2*emx ) i?86-emx-os2 | i?86-*-os2*emx )
# OS/2 with the EMX environment # OS/2 with the EMX environment
@ -523,6 +525,9 @@ if test "$have_dosish_system" = yes; then
fi fi
AM_CONDITIONAL(HAVE_DOSISH_SYSTEM, test "$have_dosish_system" = yes) AM_CONDITIONAL(HAVE_DOSISH_SYSTEM, test "$have_dosish_system" = yes)
AM_CONDITIONAL(USE_SIMPLE_GETTEXT, test x"$use_simple_gettext" = xyes)
AM_CONDITIONAL(HAVE_W32_SYSTEM, test x"$have_w32_system" = xyes)
if test "$disable_keyserver_path" = yes; then if test "$disable_keyserver_path" = yes; then
AC_DEFINE(DISABLE_KEYSERVER_PATH,1, AC_DEFINE(DISABLE_KEYSERVER_PATH,1,
[define to disable exec-path for keyserver helpers]) [define to disable exec-path for keyserver helpers])
@ -786,7 +791,7 @@ AC_CHECK_SIZEOF(unsigned long long)
# Ensure that we have UINT64_C before we bother to check for uint64_t # Ensure that we have UINT64_C before we bother to check for uint64_t
gt_HEADER_INTTYPES_H gt_HEADER_INTTYPES_H
AC_CACHE_CHECK([for UINT64_C], [gnupg_cv_uint64_c_works], AC_CACHE_CHECK([for UINT64_C], [gnupg_cv_uint64_c_works],
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([ AC_COMPILE_IFELSE(AC_LANG_PROGRAM([#include <inttypes.h>],[
uint64_t foo=UINT64_C(42);]),gnupg_cv_uint64_c_works=yes,gnupg_cv_uint64_c_works=no)) uint64_t foo=UINT64_C(42);]),gnupg_cv_uint64_c_works=yes,gnupg_cv_uint64_c_works=no))
if test "$gnupg_cv_uint64_c_works" = "yes" ; then if test "$gnupg_cv_uint64_c_works" = "yes" ; then
@ -1070,14 +1075,14 @@ main() { regex_t blah ; regmatch_t p; p.rm_eo = p.rm_eo; return regcomp(&blah, "
fi fi
if test $gnupg_cv_included_regex = yes; then if test $gnupg_cv_included_regex = yes; then
AC_DEFINE(USE_GNU_REGEX,1,[ Define if you want to use the included regex lib ]) AC_DEFINE(USE_INTERNAL_REGEX,1,[ Define if you want to use the included regex lib ])
AC_SUBST(REGEX_O,regex.o)
fi fi
else else
AC_DEFINE(DISABLE_REGEX,1,[ Define to disable regular expression support ]) AC_DEFINE(DISABLE_REGEX,1,[ Define to disable regular expression support ])
fi fi
AM_CONDITIONAL(USE_INTERNAL_REGEX, test x"$gnupg_cv_included_regex" = xyes)
dnl Do we have zlib? Must do it here because Solaris failed dnl Do we have zlib? Must do it here because Solaris failed
dnl when compiling a conftest (due to the "-lz" from LIBS). dnl when compiling a conftest (due to the "-lz" from LIBS).
use_local_zlib=yes use_local_zlib=yes

View File

@ -28,7 +28,7 @@
#ifndef DISABLE_REGEX #ifndef DISABLE_REGEX
#include <sys/types.h> #include <sys/types.h>
#ifdef USE_GNU_REGEX #ifdef USE_INTERNAL_REGEX
#include "_regex.h" #include "_regex.h"
#else #else
#include <regex.h> #include <regex.h>

View File

@ -1,5 +1,9 @@
2005-12-06 David Shaw <dshaw@jabberwocky.com> 2005-12-06 David Shaw <dshaw@jabberwocky.com>
* Makefile.am: Some cleanup so we don't build files that are
completely ifdeffed out. This causes a warning on Sun's cc. Do
the internal regex code as well for consistency.
* mkdtemp.c (mkdtemp): Fix warning. * mkdtemp.c (mkdtemp): Fix warning.
* secmem.c, assuan-buffer.c, dotlock.c: Fix a few warnings from * secmem.c, assuan-buffer.c, dotlock.c: Fix a few warnings from

View File

@ -22,28 +22,35 @@ INCLUDES = -I.. -I$(top_srcdir)/include -I$(top_srcdir)/intl
noinst_LIBRARIES = libutil.a noinst_LIBRARIES = libutil.a
EXTRA_libutil_a_SOURCES = regcomp.c regex.c regexec.c regex_internal.c \ libutil_a_SOURCES = logger.c fileutil.c miscutil.c strgutil.c \
regex_internal.h ttyio.c argparse.c memory.c secmem.c errors.c iobuf.c \
dotlock.c http.c srv.h srv.c pka.c membuf.c
# We build the assuan support only if it has been requested. if USE_SIMPLE_GETTEXT
if ENABLE_AGENT_SUPPORT libutil_a_SOURCES+=simple-gettext.c
assuan_source = assuan-buffer.c assuan-client.c assuan-defs.h \
assuan-errors.c assuan-logging.c assuan-socket-connect.c \
assuan-connect.c assuan-socket.c assuan-util.c
else
assuan_source =
endif endif
if HAVE_W32_SYSTEM
libutil_a_SOURCES+=w32reg.c
endif
#libutil_a_LDFLAGS = if ENABLE_AGENT_SUPPORT
libutil_a_SOURCES = logger.c fileutil.c miscutil.c strgutil.c \ libutil_a_SOURCES+=assuan-buffer.c assuan-client.c assuan-defs.h \
ttyio.c argparse.c memory.c secmem.c errors.c iobuf.c \ assuan-errors.c assuan-logging.c assuan-socket-connect.c \
dotlock.c http.c srv.h srv.c pka.c simple-gettext.c \ assuan-connect.c assuan-socket.c assuan-util.c
membuf.c w32reg.c $(assuan_source) endif
if USE_INTERNAL_REGEX
libutil_a_SOURCES+=regex.c
endif
# The internal regex code #includes these.
EXTRA_libutil_a_SOURCES = regcomp.c regexec.c regex_internal.c \
regex_internal.h
libutil_a_DEPENDENCIES = @LIBOBJS@ @REGEX_O@
# LIBOBJS is for the replacement functions # LIBOBJS is for the replacement functions
libutil_a_LIBADD = @LIBOBJS@ @REGEX_O@ libutil_a_DEPENDENCIES = @LIBOBJS@
libutil_a_LIBADD = @LIBOBJS@
http-test: http.c http-test: http.c
cc -DHAVE_CONFIG_H -I. -I. -I.. $(INCLUDES) $(LDFLAGS) -g -Wall \ cc -DHAVE_CONFIG_H -I. -I. -I.. $(INCLUDES) $(LDFLAGS) -g -Wall \
@ -56,4 +63,3 @@ srv-test: srv.c
pka-test: pka.c pka-test: pka.c
cc -DHAVE_CONFIG_H -I. -I. -I.. $(INCLUDES) $(LDFLAGS) -g -Wall \ cc -DHAVE_CONFIG_H -I. -I. -I.. $(INCLUDES) $(LDFLAGS) -g -Wall \
-DTEST -o pka-test pka.c libutil.a @LIBINTL@ @SRVLIBS@ @CAPLIBS@ -DTEST -o pka-test pka.c libutil.a @LIBINTL@ @SRVLIBS@ @CAPLIBS@