diff options
author | Werner Koch <wk@gnupg.org> | 1998-02-02 14:36:04 +0000 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 1998-02-02 14:36:04 +0000 |
commit | 130bfafee91aec26bc3a3fe7563b740a199680e2 (patch) | |
tree | ae9456e04a90e089ee8bcd08e84f9cf6c889cdba | |
parent | d0810b63ea1e32a4133e84fd76581d1ab21d24ac (diff) | |
download | libgcrypt-130bfafee91aec26bc3a3fe7563b740a199680e2.tar.gz |
changed structure of trustdb
-rw-r--r-- | Makefile.am | 2 | ||||
-rw-r--r-- | acinclude.m4 | 356 | ||||
-rw-r--r-- | cipher/Makefile.am | 10 | ||||
-rw-r--r-- | cipher/Makefile.in | 266 | ||||
-rw-r--r-- | configure.in | 20 | ||||
-rw-r--r-- | mpi/Makefile.am | 8 | ||||
-rw-r--r-- | mpi/Makefile.in | 268 | ||||
-rw-r--r-- | mpi/mpicoder.c | 8 | ||||
-rw-r--r-- | mpi/mpiutil.c | 30 | ||||
-rwxr-xr-x | scripts/missing | 134 |
10 files changed, 873 insertions, 229 deletions
diff --git a/Makefile.am b/Makefile.am index 7e3529c5..dea36e96 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,6 +1,6 @@ ## Process this file with automake to produce Makefile.in -SUBDIRS = @INTLSUB@ @POSUB@ util mpi cipher tools g10 +SUBDIRS = util mpi cipher tools g10 EXTRA_DIST = VERSION diff --git a/acinclude.m4 b/acinclude.m4 new file mode 100644 index 00000000..0c30b7d6 --- /dev/null +++ b/acinclude.m4 @@ -0,0 +1,356 @@ +dnl macros to configure g10 + +AC_PREREQ(2.5) + +AC_DEFUN(md_TYPE_PTRDIFF_T, + [AC_CACHE_CHECK([for ptrdiff_t], ac_cv_type_ptrdiff_t, + [AC_TRY_COMPILE(stddef.h, [ptrdiff_t p], ac_cv_type_ptrdiff_t=yes, + ac_cv_type_ptrdiff_t=no)]) + if test $ac_cv_type_ptrdiff_t = yes; then + AC_DEFINE(HAVE_PTRDIFF_T) + fi +]) + +AC_DEFUN(md_PATH_PROG, + [AC_PATH_PROG($1,$2,$3)dnl + if echo $$1 | grep openwin > /dev/null; then + echo "WARNING: Do not use OpenWin's $2. (Better remove it.) >&AC_FD_MSG" + ac_cv_path_$1=$2 + $1=$2 + fi +]) + +dnl Check NLS options + +AC_DEFUN(ud_LC_MESSAGES, + [if test $ac_cv_header_locale_h = yes; then + AC_CACHE_CHECK([for LC_MESSAGES], ud_cv_val_LC_MESSAGES, + [AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES], + ud_cv_val_LC_MESSAGES=yes, ud_cv_val_LC_MESSAGES=no)]) + if test $ud_cv_val_LC_MESSAGES = yes; then + AC_DEFINE(HAVE_LC_MESSAGES) + fi + fi]) + +AC_DEFUN(ud_WITH_NLS, + [AC_MSG_CHECKING([whether NLS is requested]) + dnl Default is enabled NLS + AC_ARG_ENABLE(nls, + [ --disable-nls do not use Native Language Support], + nls_cv_use_nls=$enableval, nls_cv_use_nls=yes) + AC_MSG_RESULT($nls_cv_use_nls) + + dnl If we use NLS figure out what method + if test "$nls_cv_use_nls" = "yes"; then + AC_DEFINE(ENABLE_NLS) + AC_MSG_CHECKING([for explicitly using GNU gettext]) + AC_ARG_WITH(gnu-gettext, + [ --with-gnu-gettext use the GNU gettext library], + nls_cv_force_use_gnu_gettext=$withval, + nls_cv_force_use_gnu_gettext=no) + AC_MSG_RESULT($nls_cv_force_use_gnu_gettext) + + if test "$nls_cv_force_use_gnu_gettext" = "yes"; then + nls_cv_use_gnu_gettext=yes + else + dnl User does not insist on using GNU NLS library. Figure out what + dnl to use. If gettext or catgets are available (in this order) we + dnl use this. Else we have to fall back to GNU NLS library. + AC_CHECK_LIB(intl, main) + AC_CHECK_LIB(i, main) + CATOBJEXT=NONE + + dnl Debian 1.3.1 does not have libintl.h but libintl.a + AC_CHECK_HEADERS(libintl.h) + if test "$ac_cv_lib_intl_main" = yes \ + && test "$ac_cv_header_libintl_h" != "yes" ; then + nls_cv_use_gnu_gettext=yes + else + AC_CHECK_FUNC(gettext, + [AC_DEFINE(HAVE_GETTEXT) + md_PATH_PROG(MSGFMT, msgfmt, no)dnl + if test "$MSGFMT" != "no"; then + AC_CHECK_FUNCS(dcgettext) + md_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + md_PATH_PROG(XGETTEXT, xgettext, xgettext) + CATOBJEXT=.mo + INSTOBJEXT=.mo + DATADIRNAME=lib + if test "$ac_cv_lib_intl[_]main" = yes; then + INTLLIBS=-lintl + elif test "$ac_cv_lib_i[_]main" = yes; then + INTLLIBS=-li + fi + fi]) + + if test "$CATOBJEXT" = "NONE"; then + dnl No gettext in C library. Try catgets next. + AC_CHECK_FUNC(catgets, + [AC_DEFINE(HAVE_CATGETS) + INTLOBJS="\$(CATOBJS)" + AC_PATH_PROG(GENCAT, gencat, no)dnl + if test "$GENCAT" != "no"; then + AC_PATH_PROGS(GMSGFMT, [gmsgfmt msgfmt], msgfmt) + md_PATH_PROG(XGETTEXT, xgettext, xgettext) + CATOBJEXT=.cat + INSTOBJEXT=.cat + DATADIRNAME=lib + INTLDEPS="\${top_srcdir}/intl/libintl.a" + INTLLIBS=$INTLDEPS + LIBS=`echo $LIBS | sed -e 's/-lintl//'` + nls_cv_header_intl=intl/libintl.h + nls_cv_header_libgt=intl/libgettext.h + fi]) + fi + fi + + if test "$CATOBJEXT" = "NONE"; then + dnl Neither gettext nor catgets in included in the C library. + dnl Fall back on GNU gettext library. + nls_cv_use_gnu_gettext=yes + fi + fi + + if test "$nls_cv_use_gnu_gettext" = "yes"; then + dnl Mark actions used to generate GNU NLS library. + INTLOBJS="\$(GETTOBJS)" + md_PATH_PROG(MSGFMT, msgfmt, msgfmt) + md_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + md_PATH_PROG(XGETTEXT, xgettext, xgettext) + AC_SUBST(MSGFMT) + CATOBJEXT=.gmo + INSTOBJEXT=.mo + DATADIRNAME=share + INTLDEPS="\${top_srcdir}/intl/libintl.a" + INTLLIBS=$INTLDEPS + LIBS=`echo $LIBS | sed -e 's/-lintl//'` + nls_cv_header_intl=intl/libintl.h + nls_cv_header_libgt=intl/libgettext.h + fi + + # We need to process the intl/ and po/ directory. + INTLSUB=intl + POSUB=po + else + DATADIRNAME=share + nls_cv_header_intl=intl/libintl.h + nls_cv_header_libgt=intl/libgettext.h + fi + + dnl These rules are solely for the distribution goal. While doing this + dnl we only have to keep exactly one list of the available catalogs + dnl in configure.in. + for lang in $ALL_LINGUAS; do + GMOFILES="$GMOFILES $lang.gmo" + POFILES="$POFILES $lang.po" + done + + dnl Make all variables we use known to autoconf. + AC_SUBST(CATALOGS) + AC_SUBST(CATOBJEXT) + AC_SUBST(DATADIRNAME) + AC_SUBST(GMOFILES) + AC_SUBST(INSTOBJEXT) + AC_SUBST(INTLDEPS) + AC_SUBST(INTLLIBS) + AC_SUBST(INTLOBJS) + AC_SUBST(INTLSUB) + AC_SUBST(POFILES) + AC_SUBST(POSUB) + ]) + +AC_DEFUN(AM_GNU_GETTEXT, + [AC_REQUIRE([AC_PROG_MAKE_SET])dnl + AC_REQUIRE([AC_PROG_CC])dnl + AC_REQUIRE([AC_PROG_RANLIB])dnl + AC_REQUIRE([AC_HEADER_STDC])dnl + AC_REQUIRE([AC_C_CONST])dnl + AC_REQUIRE([AC_C_INLINE])dnl + AC_REQUIRE([AC_TYPE_OFF_T])dnl + AC_REQUIRE([AC_TYPE_SIZE_T])dnl + AC_REQUIRE([AC_FUNC_ALLOCA])dnl + AC_REQUIRE([AC_FUNC_MMAP])dnl + + AC_CHECK_HEADERS([limits.h locale.h nl_types.h malloc.h string.h unistd.h values.h]) + AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp]) + + if test "${ac_cv_func_stpcpy+set}" != "set"; then + AC_CHECK_FUNCS(stpcpy) + fi + if test "${ac_cv_func_stpcpy}" = "yes"; then + AC_DEFINE(HAVE_STPCPY) + fi + + ud_LC_MESSAGES + ud_WITH_NLS + + if test "x$CATOBJEXT" != "x"; then + if test "x$ALL_LINGUAS" = "x"; then + LINGUAS= + else + AC_MSG_CHECKING(for catalogs to be installed) + NEW_LINGUAS= + for lang in ${LINGUAS=$ALL_LINGUAS}; do + case "$ALL_LINGUAS" in + *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; + esac + done + LINGUAS=$NEW_LINGUAS + AC_MSG_RESULT($LINGUAS) + fi + + dnl Construct list of names of catalog files to be constructed. + if test -n "$LINGUAS"; then + for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done + fi + fi + + dnl Determine which catalog format we have (if any is needed) + dnl For now we know about two different formats: + dnl Linux and the normal X/Open format + test -d intl || mkdir intl + if test "$CATOBJEXT" = ".cat"; then + AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen) + + dnl Transform the SED scripts while copying because some dumb SEDs + dnl cannot handle comments. + sed -e '/^#/d' $srcdir/intl/$msgformat-msg.sed > intl/po2msg.sed + fi + dnl po2tbl.sed is always needed. + sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \ + $srcdir/intl/po2tbl.sed.in > intl/po2tbl.sed + + dnl Generate list of files to be processed by xgettext which will + dnl be included in po/Makefile. + test -d po || mkdir po + if test "x$srcdir" != "x."; then + if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then + posrcprefix="$srcdir/" + else + posrcprefix="../$srcdir/" + fi + else + posrcprefix="../" + fi + sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ + < $srcdir/po/POTFILES.in > po/POTFILES + ]) + + + +dnl -------------------------------------------------- +dnl G10 stuff +dnl -------------------------------------------------- + + +dnl WK_MSG_PRINT(STRING) +dnl print a message +dnl +define(WK_MSG_PRINT, + [ echo $ac_n "$1"" $ac_c" 1>&AC_FD_MSG + ]) + + +dnl WK_CHECK_TYPEDEF(TYPE, HAVE_NAME) +dnl Check wether a typedef exists and create a #define $2 if it exists +dnl +AC_DEFUN(WK_CHECK_TYPEDEF, + [ AC_MSG_CHECKING(for $1 typedef) + AC_CACHE_VAL(wk_cv_typedef_$1, + [AC_TRY_COMPILE([#include <stdlib.h> + #include <sys/types.h>], [ + #undef $1 + int a = sizeof($1); + ], wk_cv_typedef_$1=yes, wk_cv_typedef_$1=no )]) + AC_MSG_RESULT($wk_cv_typedef_$1) + if test "$wk_cv_typedef_$1" = yes; then + AC_DEFINE($2) + fi + ]) + + + +dnl WK_LINK_FILES( SRC, DEST ) +dnl same as AC_LINK_FILES, but collet the files to link in +dnl some special variables and do the link macro +dnl when WK_DO_LINK_FILES is called +dnl This is a workaround for AC_LINK_FILES, because it does not work +dnl correct when using a caching scheme +dnl +define(WK_LINK_FILES, + [ if test "x$wk_link_files_src" = "x"; then + wk_link_files_src="$1" + wk_link_files_dst="$2" + else + wk_link_files_src="$wk_link_files_src $1" + wk_link_files_dst="$wk_link_files_dst $2" + fi + ]) +define(WK_DO_LINK_FILES, + [ AC_LINK_FILES( $wk_link_files_src, $wk_link_files_dst ) + ]) + + +dnl WK_CHECK_ENDIAN +dnl define either LITTLE_ENDIAN_HOST or BIG_ENDIAN_HOST +dnl +define(WK_CHECK_ENDIAN, + [ if test "$cross_compiling" = yes; then + AC_MSG_WARN(cross compiling; assuming little endianess) + fi + AC_MSG_CHECKING(endianess) + AC_CACHE_VAL(wk_cv_c_endian, + [ wk_cv_c_endian=unknown + # See if sys/param.h defines the BYTE_ORDER macro. + AC_TRY_COMPILE([#include <sys/types.h> + #include <sys/param.h>], [ + #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN + bogus endian macros + #endif], [# It does; now see whether it defined to BIG_ENDIAN or not. + AC_TRY_COMPILE([#include <sys/types.h> + #include <sys/param.h>], [ + #if BYTE_ORDER != BIG_ENDIAN + not big endian + #endif], wk_cv_c_endian=big, wk_cv_c_endian=big)]) + if test "$wk_cv_c_endian" = unknown; then + AC_TRY_RUN([main () { + /* Are we little or big endian? From Harbison&Steele. */ + union + { + long l; + char c[sizeof (long)]; + } u; + u.l = 1; + exit (u.c[sizeof (long) - 1] == 1); + }], + wk_cv_c_endian=little, + wk_cv_c_endian=big, + wk_cv_c_endian=little + ) + fi + ]) + AC_MSG_RESULT([$wk_cv_c_endian]) + if test "$wk_cv_c_endian" = little; then + AC_DEFINE(LITTLE_ENDIAN_HOST) + else + AC_DEFINE(BIG_ENDIAN_HOST) + fi + ]) + +dnl WK_CHECK_CACHE +dnl +define(WK_CHECK_CACHE, + [ AC_MSG_CHECKING(cached information) + wk_hostcheck="$target" + AC_CACHE_VAL(wk_cv_hostcheck, [ wk_cv_hostcheck="$wk_hostcheck" ]) + if test "$wk_cv_hostcheck" != "$wk_hostcheck"; then + AC_MSG_RESULT(changed) + AC_MSG_WARN(config.cache exists!) + AC_MSG_ERROR(you must do 'make distclean' first to compile for + different target or different parameters.) + else + AC_MSG_RESULT(ok) + fi + ]) + + diff --git a/cipher/Makefile.am b/cipher/Makefile.am index ecd91a73..ad672287 100644 --- a/cipher/Makefile.am +++ b/cipher/Makefile.am @@ -1,12 +1,12 @@ ## Process this file with automake to produce Makefile.in -INCLUDES = -I$(top_srcdir)/include +INCLUDES = -I$(top_srcdir)/include EXTRA_DIST = @CIPHER_EXTRA_DIST@ -noinst_LIBRARIES = cipher +noinst_LIBRARIES = libcipher.a -cipher_SOURCES = blowfish.c \ +libcipher_a_SOURCES = blowfish.c \ blowfish.h \ elgamal.c \ elgamal.h \ @@ -27,6 +27,8 @@ cipher_SOURCES = blowfish.c \ misc.c \ smallprime.c -cipher_LIBADD = @CIPHER_EXTRA_OBJS@ +libcipher_a_LIBADD = @CIPHER_EXTRA_OBJS@ + +$(LIBRARIES): @CIPHER_EXTRA_OBJS@ diff --git a/cipher/Makefile.in b/cipher/Makefile.in index 221efdd2..a1cfa5ac 100644 --- a/cipher/Makefile.in +++ b/cipher/Makefile.in @@ -1,8 +1,14 @@ -# Makefile.in generated automatically by automake 1.0 from Makefile.am +# Makefile.in generated automatically by automake 1.2d from Makefile.am -# Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc. +# Copyright (C) 1994, 1995, 1996, 1997 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. SHELL = /bin/sh @@ -32,18 +38,59 @@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. +ACLOCAL = @ACLOCAL@ +AUTOCONF = @AUTOCONF@ +AUTOMAKE = @AUTOMAKE@ +AUTOHEADER = @AUTOHEADER@ + INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ transform = @program_transform_name@ -INCLUDES = -I$(top_srcdir)/include +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_alias = @build_alias@ +build_triplet = @build@ +host_alias = @host_alias@ +host_triplet = @host@ +target_alias = @target_alias@ +target_triplet = @target@ +CATALOGS = @CATALOGS@ +CATOBJEXT = @CATOBJEXT@ +CC = @CC@ +CIPHER_EXTRA_DIST = @CIPHER_EXTRA_DIST@ +CIPHER_EXTRA_OBJS = @CIPHER_EXTRA_OBJS@ +CPP = @CPP@ +DATADIRNAME = @DATADIRNAME@ +G10_LOCALEDIR = @G10_LOCALEDIR@ +GENCAT = @GENCAT@ +GMOFILES = @GMOFILES@ +GMSGFMT = @GMSGFMT@ +INSTOBJEXT = @INSTOBJEXT@ +INTLDEPS = @INTLDEPS@ +INTLLIBS = @INTLLIBS@ +INTLOBJS = @INTLOBJS@ +INTLSUB = @INTLSUB@ +MPI_EXTRA_ASM_OBJS = @MPI_EXTRA_ASM_OBJS@ +MSGFMT = @MSGFMT@ +PACKAGE = @PACKAGE@ +POFILES = @POFILES@ +POSUB = @POSUB@ +RANLIB = @RANLIB@ +VERSION = @VERSION@ + +INCLUDES = -I$(top_srcdir)/include EXTRA_DIST = @CIPHER_EXTRA_DIST@ -noinst_LIBRARIES = cipher +noinst_LIBRARIES = libcipher.a -cipher_SOURCES = blowfish.c \ +libcipher_a_SOURCES = blowfish.c \ blowfish.h \ elgamal.c \ elgamal.h \ @@ -64,190 +111,196 @@ cipher_SOURCES = blowfish.c \ misc.c \ smallprime.c -cipher_LIBADD = @CIPHER_EXTRA_OBJS@ -mkinstalldirs = $(top_srcdir)/scripts/mkinstalldirs +libcipher_a_LIBADD = @CIPHER_EXTRA_OBJS@ +mkinstalldirs = $(SHELL) $(top_srcdir)/scripts/mkinstalldirs CONFIG_HEADER = ../config.h -LIBRARIES = $(noinst_LIBRARIES) +CONFIG_CLEAN_FILES = +LIBRARIES = $(noinst_LIBRARIES) -noinst_LIBFILES = libcipher.a - -CC = @CC@ -LEX = @LEX@ -YACC = @YACC@ DEFS = @DEFS@ -I. -I$(srcdir) -I.. CPPFLAGS = @CPPFLAGS@ -CFLAGS = @CFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ - -COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) -LINK = $(CC) $(LDFLAGS) -o $@ -cipher_OBJECTS = blowfish.o elgamal.o gost.o md5.o primegen.o random.o \ -rmd160.o sha1.o dsa.o md.o misc.o smallprime.o -EXTRA_cipher_SOURCES = -LIBFILES = libcipher.a +libcipher_a_DEPENDENCIES = +libcipher_a_OBJECTS = blowfish.o elgamal.o gost.o md5.o primegen.o \ +random.o rmd160.o sha1.o dsa.o md.o misc.o smallprime.o AR = ar -RANLIB = @RANLIB@ -DIST_COMMON = Makefile.am Makefile.in +CFLAGS = @CFLAGS@ +COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) +LINK = $(CC) $(CFLAGS) $(LDFLAGS) -o $@ +DIST_COMMON = Makefile.am Makefile.in -PACKAGE = @PACKAGE@ -VERSION = @VERSION@ - -DISTFILES = $(DIST_COMMON) $(SOURCES) $(BUILT_SOURCES) $(HEADERS) \ - $(TEXINFOS) $(INFOS) $(MANS) $(EXTRA_DIST) $(DATA) -DEP_DISTFILES = $(DIST_COMMON) $(SOURCES) $(BUILT_SOURCES) $(HEADERS) \ - $(TEXINFOS) $(INFO_DEPS) $(MANS) $(EXTRA_DIST) $(DATA) +DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) TAR = tar -DEP_FILES = $(srcdir)/.deps/blowfish.P $(srcdir)/.deps/dsa.P \ -$(srcdir)/.deps/elgamal.P $(srcdir)/.deps/gost.P $(srcdir)/.deps/md.P \ -$(srcdir)/.deps/md5.P $(srcdir)/.deps/misc.P $(srcdir)/.deps/primegen.P \ -$(srcdir)/.deps/random.P $(srcdir)/.deps/rmd160.P \ -$(srcdir)/.deps/sha1.P $(srcdir)/.deps/smallprime.P -SOURCES = $(cipher_SOURCES) -OBJECTS = $(cipher_OBJECTS) +GZIP = --best +DEP_FILES = .deps/blowfish.P .deps/dsa.P .deps/elgamal.P .deps/gost.P \ +.deps/md.P .deps/md5.P .deps/misc.P .deps/primegen.P .deps/random.P \ +.deps/rmd160.P .deps/sha1.P .deps/smallprime.P +SOURCES = $(libcipher_a_SOURCES) +OBJECTS = $(libcipher_a_OBJECTS) default: all +.SUFFIXES: +.SUFFIXES: .S .c .o .s +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) + cd $(top_srcdir) && $(AUTOMAKE) --gnu cipher/Makefile -$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in - cd $(top_srcdir) && automake $(subdir)/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) + cd $(top_builddir) \ + && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status -Makefile: $(top_builddir)/config.status Makefile.in - cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status mostlyclean-noinstLIBRARIES: clean-noinstLIBRARIES: - rm -f $(noinst_LIBFILES) + -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) distclean-noinstLIBRARIES: maintainer-clean-noinstLIBRARIES: .c.o: - $(COMPILE) $< + $(COMPILE) -c $< + +.s.o: + $(COMPILE) -c $< + +.S.o: + $(COMPILE) -c $< mostlyclean-compile: - rm -f *.o core + -rm -f *.o core clean-compile: distclean-compile: - rm -f *.tab.c + -rm -f *.tab.c maintainer-clean-compile: -$(cipher_OBJECTS): ../config.h -libcipher.a: $(cipher_OBJECTS) $(cipher_LIBADD) - rm -f libcipher.a - $(AR) cru libcipher.a $(cipher_OBJECTS) $(cipher_LIBADD) +libcipher.a: $(libcipher_a_OBJECTS) $(libcipher_a_DEPENDENCIES) + -rm -f libcipher.a + $(AR) cru libcipher.a $(libcipher_a_OBJECTS) $(libcipher_a_LIBADD) $(RANLIB) libcipher.a -ID: $(HEADERS) $(SOURCES) - here=`pwd` && cd $(srcdir) && mkid -f$$here/ID $(SOURCES) $(HEADERS) - tags: TAGS -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) - here=`pwd` && cd $(srcdir) && etags $(ETAGS_ARGS) $(SOURCES) $(HEADERS) -o $$here/TAGS +ID: $(HEADERS) $(SOURCES) $(LISP) + here=`pwd` && cd $(srcdir) \ + && mkid -f$$here/ID $(SOURCES) $(HEADERS) $(LISP) + +TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP) + tags=; \ + here=`pwd`; \ + test -z "$(ETAGS_ARGS)$(SOURCES)$(HEADERS)$(LISP)$$tags" \ + || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $(SOURCES) $(HEADERS) $(LISP) -o $$here/TAGS) mostlyclean-tags: clean-tags: distclean-tags: - rm -f TAGS ID + -rm -f TAGS ID maintainer-clean-tags: -subdir = cipher distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) -distdir: $(DEP_DISTFILES) - @for file in `cd $(srcdir) && echo $(DISTFILES)`; do \ + +subdir = cipher + +distdir: $(DISTFILES) + here=`cd $(top_builddir) && pwd`; \ + top_distdir=`cd $(top_distdir) && pwd`; \ + distdir=`cd $(distdir) && pwd`; \ + cd $(top_srcdir) \ + && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu cipher/Makefile + @for file in $(DISTFILES); do \ + d=$(srcdir); \ test -f $(distdir)/$$file \ - || ln $(srcdir)/$$file $(distdir)/$$file 2> /dev/null \ - || cp -p $(srcdir)/$$file $(distdir)/$$file; \ + || ln $$d/$$file $(distdir)/$$file 2> /dev/null \ + || cp -p $$d/$$file $(distdir)/$$file; \ done -# This fragment is probably only useful for maintainers. It relies on -# GNU make and gcc. It is only included in the generated Makefile.in -# if `automake' is not passed the `--include-deps' flag. - -MKDEP = gcc -MM $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) +MKDEP = $(CC) -M $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) --include $(srcdir)/.deps/.P -$(srcdir)/.deps/.P: $(BUILT_SOURCES) - cd $(srcdir) && test -d .deps || mkdir .deps +DEPS_MAGIC := $(shell mkdir .deps > /dev/null 2>&1 || :) +-include .deps/.P +.deps/.P: $(BUILT_SOURCES) echo > $@ -include $(DEP_FILES) -$(DEP_FILES): $(srcdir)/.deps/.P - -$(srcdir)/.deps/%.P: $(srcdir)/%.c - @echo "mkdeps $< > $@" - @re=`echo 's,^$(srcdir)//*,,g;s, $(srcdir)//*, ,g' | sed 's,\.,\\\\.,g'`; \ - $(MKDEP) $< | sed "$$re" > $@-tmp - @if test -n "$o"; then \ - sed 's/\.o:/$$o:/' $@-tmp > $@; \ - rm $@-tmp; \ - else \ - mv $@-tmp $@; \ - fi - -# End of maintainer-only section -info: -dvi: +mostlyclean-depend: -check: all +clean-depend: -installcheck: +distclean-depend: + +maintainer-clean-depend: + -rm -rf .deps +.deps/%.P: %.c + @echo "Computing dependencies for $<..." + @o='o'; \ + test -n "$o" && o='$$o'; \ + $(MKDEP) $< >$@.tmp \ + && sed "s,^\(.*\)\.o:,\1.$$o \1.l$$o $@:," < $@.tmp > $@ \ + && rm -f $@.tmp +info: +dvi: +check: all + $(MAKE) +installcheck: install-exec: + @$(NORMAL_INSTALL) install-data: + @$(NORMAL_INSTALL) install: install-exec install-data all @: uninstall: -all: $(LIBFILES) Makefile +all: Makefile $(LIBRARIES) install-strip: - $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' INSTALL_SCRIPT='$(INSTALL_PROGRAM)' install installdirs: mostlyclean-generic: - test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) + -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) clean-generic: - test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: - rm -f Makefile $(DISTCLEANFILES) - rm -f config.cache config.log $(CONFIG_HEADER) stamp-h + -rm -f Makefile $(DISTCLEANFILES) + -rm -f config.cache config.log stamp-h stamp-h[0-9]* + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: - test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) - test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) + -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) mostlyclean: mostlyclean-noinstLIBRARIES mostlyclean-compile \ - mostlyclean-tags mostlyclean-generic + mostlyclean-tags mostlyclean-depend mostlyclean-generic -clean: clean-noinstLIBRARIES clean-compile clean-tags clean-generic \ - mostlyclean +clean: clean-noinstLIBRARIES clean-compile clean-tags clean-depend \ + clean-generic mostlyclean distclean: distclean-noinstLIBRARIES distclean-compile distclean-tags \ - distclean-generic clean - rm -f config.status + distclean-depend distclean-generic clean + -rm -f config.status maintainer-clean: maintainer-clean-noinstLIBRARIES \ maintainer-clean-compile maintainer-clean-tags \ - maintainer-clean-generic distclean + maintainer-clean-depend maintainer-clean-generic \ + distclean @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." @@ -255,13 +308,14 @@ maintainer-clean: maintainer-clean-noinstLIBRARIES \ clean-noinstLIBRARIES maintainer-clean-noinstLIBRARIES \ mostlyclean-compile distclean-compile clean-compile \ maintainer-clean-compile tags mostlyclean-tags distclean-tags \ -clean-tags maintainer-clean-tags distdir info dvi check installcheck \ -install-exec install-data install uninstall all installdirs \ -mostlyclean-generic distclean-generic clean-generic \ +clean-tags maintainer-clean-tags distdir mostlyclean-depend \ +distclean-depend clean-depend maintainer-clean-depend info dvi \ +installcheck install-exec install-data install uninstall all \ +installdirs mostlyclean-generic distclean-generic clean-generic \ maintainer-clean-generic clean mostlyclean distclean maintainer-clean -.SUFFIXES: -.SUFFIXES: .c .o + +$(LIBRARIES): @CIPHER_EXTRA_OBJS@ # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/configure.in b/configure.in index 7017948d..e83e10d5 100644 --- a/configure.in +++ b/configure.in @@ -5,7 +5,10 @@ dnl (Process this file with autoconf to produce a configure script.) AC_INIT(g10/g10.c) AC_CONFIG_AUX_DIR(scripts) -AC_CONFIG_HEADER(config.h) +dnl Ooops: automake 1.2d looks for AC_CONFIG_HEADER (and not AM_..) +dnl to decide where config.h is - so we have to add it to +dnl every makefile.am +AM_CONFIG_HEADER(config.h) if test "x$exec_prefix" = xNONE ; then @@ -45,6 +48,14 @@ WK_CHECK_CACHE dnl Checks for programs. AC_PROG_MAKE_SET +AC_ARG_PROGRAM + +missing_dir=`cd $ac_aux_dir && pwd` +AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir) +AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir) +AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir) +AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir) +dnl AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir) case "${target}" in i386--mingw32) @@ -64,16 +75,15 @@ AC_PROG_CPP esac -AC_ARG_PROGRAM - dnl Checks for libraries. dnl Checks for header files. AC_HEADER_STDC AC_CHECK_HEADERS(unistd.h) -ud_GNU_GETTEXT -WK_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl ) +dnl AM_GNU_GETTEXT +dnl WK_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl ) +AC_MSG_WARN([i18n disabled for this release - sorry]) dnl Checks for typedefs, structures, and compiler characteristics. diff --git a/mpi/Makefile.am b/mpi/Makefile.am index 18b5581a..11b15dd3 100644 --- a/mpi/Makefile.am +++ b/mpi/Makefile.am @@ -1,6 +1,6 @@ ## Process this file with automake to produce Makefile.in -INCLUDES = -I$(top_srcdir)/include +INCLUDES = -I.. -I$(top_srcdir)/include CFLAGS += -O2 SUFFIXES = .S .s @@ -8,10 +8,10 @@ SUFFIXES = .S .s EXTRA_DIST = config.links -noinst_LIBRARIES = mpi +noinst_LIBRARIES = libmpi.a # noinst_HEADERS = -mpi_SOURCES = longlong.h \ +libmpi_a_SOURCES = longlong.h \ mpi-add.c \ mpi-bit.c \ mpi-cmp.c \ @@ -31,7 +31,7 @@ mpi_SOURCES = longlong.h \ mpih-mul.c \ mpiutil.c -mpi_LIBADD = mpih-mul1.o \ +libmpi_a_LIBADD = mpih-mul1.o \ mpih-mul2.o \ mpih-mul3.o \ mpih-add1.o \ diff --git a/mpi/Makefile.in b/mpi/Makefile.in index 81910ff2..98b42753 100644 --- a/mpi/Makefile.in +++ b/mpi/Makefile.in @@ -1,8 +1,14 @@ -# Makefile.in generated automatically by automake 1.0 from Makefile.am +# Makefile.in generated automatically by automake 1.2d from Makefile.am -# Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc. +# Copyright (C) 1994, 1995, 1996, 1997 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. SHELL = /bin/sh @@ -32,22 +38,63 @@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. +ACLOCAL = @ACLOCAL@ +AUTOCONF = @AUTOCONF@ +AUTOMAKE = @AUTOMAKE@ +AUTOHEADER = @AUTOHEADER@ + INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ transform = @program_transform_name@ -INCLUDES = -I$(top_srcdir)/include +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_alias = @build_alias@ +build_triplet = @build@ +host_alias = @host_alias@ +host_triplet = @host@ +target_alias = @target_alias@ +target_triplet = @target@ +CATALOGS = @CATALOGS@ +CATOBJEXT = @CATOBJEXT@ +CC = @CC@ +CIPHER_EXTRA_DIST = @CIPHER_EXTRA_DIST@ +CIPHER_EXTRA_OBJS = @CIPHER_EXTRA_OBJS@ +CPP = @CPP@ +DATADIRNAME = @DATADIRNAME@ +G10_LOCALEDIR = @G10_LOCALEDIR@ +GENCAT = @GENCAT@ +GMOFILES = @GMOFILES@ +GMSGFMT = @GMSGFMT@ +INSTOBJEXT = @INSTOBJEXT@ +INTLDEPS = @INTLDEPS@ +INTLLIBS = @INTLLIBS@ +INTLOBJS = @INTLOBJS@ +INTLSUB = @INTLSUB@ +MPI_EXTRA_ASM_OBJS = @MPI_EXTRA_ASM_OBJS@ +MSGFMT = @MSGFMT@ +PACKAGE = @PACKAGE@ +POFILES = @POFILES@ +POSUB = @POSUB@ +RANLIB = @RANLIB@ +VERSION = @VERSION@ + +INCLUDES = -I.. -I$(top_srcdir)/include SUFFIXES = .S .s EXTRA_DIST = config.links -noinst_LIBRARIES = mpi +noinst_LIBRARIES = libmpi.a # noinst_HEADERS = -mpi_SOURCES = longlong.h \ +libmpi_a_SOURCES = longlong.h \ mpi-add.c \ mpi-bit.c \ mpi-cmp.c \ @@ -67,199 +114,205 @@ mpi_SOURCES = longlong.h \ mpih-mul.c \ mpiutil.c -mpi_LIBADD = mpih-mul1.o \ +libmpi_a_LIBADD = mpih-mul1.o \ mpih-mul2.o \ mpih-mul3.o \ mpih-add1.o \ mpih-sub1.o \ mpih-shift.o @MPI_EXTRA_ASM_OBJS@ -mkinstalldirs = $(top_srcdir)/scripts/mkinstalldirs +mkinstalldirs = $(SHELL) $(top_srcdir)/scripts/mkinstalldirs CONFIG_HEADER = ../config.h -LIBRARIES = $(noinst_LIBRARIES) +CONFIG_CLEAN_FILES = +LIBRARIES = $(noinst_LIBRARIES) -noinst_LIBFILES = libmpi.a - -CC = @CC@ -LEX = @LEX@ -YACC = @YACC@ DEFS = @DEFS@ -I. -I$(srcdir) -I.. CPPFLAGS = @CPPFLAGS@ -CFLAGS = @CFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ - -COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) -LINK = $(CC) $(LDFLAGS) -o $@ -mpi_OBJECTS = mpi-add.o mpi-bit.o mpi-cmp.o mpi-div.o mpi-gcd.o \ +libmpi_a_DEPENDENCIES = mpih-mul1.o mpih-mul2.o mpih-mul3.o mpih-add1.o \ +mpih-sub1.o mpih-shift.o +libmpi_a_OBJECTS = mpi-add.o mpi-bit.o mpi-cmp.o mpi-div.o mpi-gcd.o \ mpi-inv.o mpi-mul.o mpi-pow.o mpi-scan.o mpicoder.o mpih-cmp.o \ mpih-add.o mpih-sub.o mpih-div.o mpih-mul.o mpiutil.o -EXTRA_mpi_SOURCES = -LIBFILES = libmpi.a AR = ar -RANLIB = @RANLIB@ -DIST_COMMON = Makefile.am Makefile.in +CFLAGS = @CFLAGS@ +COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) +LINK = $(CC) $(CFLAGS) $(LDFLAGS) -o $@ +DIST_COMMON = Makefile.am Makefile.in -PACKAGE = @PACKAGE@ -VERSION = @VERSION@ - -DISTFILES = $(DIST_COMMON) $(SOURCES) $(BUILT_SOURCES) $(HEADERS) \ - $(TEXINFOS) $(INFOS) $(MANS) $(EXTRA_DIST) $(DATA) -DEP_DISTFILES = $(DIST_COMMON) $(SOURCES) $(BUILT_SOURCES) $(HEADERS) \ - $(TEXINFOS) $(INFO_DEPS) $(MANS) $(EXTRA_DIST) $(DATA) +DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) TAR = tar -DEP_FILES = $(srcdir)/.deps/mpi-add.P $(srcdir)/.deps/mpi-bit.P \ -$(srcdir)/.deps/mpi-cmp.P $(srcdir)/.deps/mpi-div.P \ -$(srcdir)/.deps/mpi-gcd.P $(srcdir)/.deps/mpi-inv.P \ -$(srcdir)/.deps/mpi-mul.P $(srcdir)/.deps/mpi-pow.P \ -$(srcdir)/.deps/mpi-scan.P $(srcdir)/.deps/mpicoder.P \ -$(srcdir)/.deps/mpih-add.P $(srcdir)/.deps/mpih-cmp.P \ -$(srcdir)/.deps/mpih-div.P $(srcdir)/.deps/mpih-mul.P \ -$(srcdir)/.deps/mpih-sub.P $(srcdir)/.deps/mpiutil.P -SOURCES = $(mpi_SOURCES) -OBJECTS = $(mpi_OBJECTS) +GZIP = --best +DEP_FILES = .deps/mpi-add.P .deps/mpi-bit.P .deps/mpi-cmp.P \ +.deps/mpi-div.P .deps/mpi-gcd.P .deps/mpi-inv.P .deps/mpi-mul.P \ +.deps/mpi-pow.P .deps/mpi-scan.P .deps/mpicoder.P .deps/mpih-add.P \ +.deps/mpih-cmp.P .deps/mpih-div.P .deps/mpih-mul.P .deps/mpih-sub.P \ +.deps/mpiutil.P +SOURCES = $(libmpi_a_SOURCES) +OBJECTS = $(libmpi_a_OBJECTS) default: all +.SUFFIXES: +.SUFFIXES: .S .c .o .s +$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) + cd $(top_srcdir) && $(AUTOMAKE) --gnu mpi/Makefile -$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in - cd $(top_srcdir) && automake $(subdir)/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) + cd $(top_builddir) \ + && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status -Makefile: $(top_builddir)/config.status Makefile.in - cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status mostlyclean-noinstLIBRARIES: clean-noinstLIBRARIES: - rm -f $(noinst_LIBFILES) + -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) distclean-noinstLIBRARIES: maintainer-clean-noinstLIBRARIES: .c.o: - $(COMPILE) $< + $(COMPILE) -c $< + +.s.o: + $(COMPILE) -c $< + +.S.o: + $(COMPILE) -c $< mostlyclean-compile: - rm -f *.o core + -rm -f *.o core clean-compile: distclean-compile: - rm -f *.tab.c + -rm -f *.tab.c maintainer-clean-compile: -$(mpi_OBJECTS): ../config.h -libmpi.a: $(mpi_OBJECTS) $(mpi_LIBADD) - rm -f libmpi.a - $(AR) cru libmpi.a $(mpi_OBJECTS) $(mpi_LIBADD) +libmpi.a: $(libmpi_a_OBJECTS) $(libmpi_a_DEPENDENCIES) + -rm -f libmpi.a + $(AR) cru libmpi.a $(libmpi_a_OBJECTS) $(libmpi_a_LIBADD) $(RANLIB) libmpi.a -ID: $(HEADERS) $(SOURCES) - here=`pwd` && cd $(srcdir) && mkid -f$$here/ID $(SOURCES) $(HEADERS) - tags: TAGS -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) - here=`pwd` && cd $(srcdir) && etags $(ETAGS_ARGS) $(SOURCES) $(HEADERS) -o $$here/TAGS +ID: $(HEADERS) $(SOURCES) $(LISP) + here=`pwd` && cd $(srcdir) \ + && mkid -f$$here/ID $(SOURCES) $(HEADERS) $(LISP) + +TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP) + tags=; \ + here=`pwd`; \ + test -z "$(ETAGS_ARGS)$(SOURCES)$(HEADERS)$(LISP)$$tags" \ + || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $(SOURCES) $(HEADERS) $(LISP) -o $$here/TAGS) mostlyclean-tags: clean-tags: distclean-tags: - rm -f TAGS ID + -rm -f TAGS ID maintainer-clean-tags: -subdir = mpi distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) -distdir: $(DEP_DISTFILES) - @for file in `cd $(srcdir) && echo $(DISTFILES)`; do \ + +subdir = mpi + +distdir: $(DISTFILES) + here=`cd $(top_builddir) && pwd`; \ + top_distdir=`cd $(top_distdir) && pwd`; \ + distdir=`cd $(distdir) && pwd`; \ + cd $(top_srcdir) \ + && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu mpi/Makefile + @for file in $(DISTFILES); do \ + d=$(srcdir); \ test -f $(distdir)/$$file \ - || ln $(srcdir)/$$file $(distdir)/$$file 2> /dev/null \ - || cp -p $(srcdir)/$$file $(distdir)/$$file; \ + || ln $$d/$$file $(distdir)/$$file 2> /dev/null \ + || cp -p $$d/$$file $(distdir)/$$file; \ done -# This fragment is probably only useful for maintainers. It relies on -# GNU make and gcc. It is only included in the generated Makefile.in -# if `automake' is not passed the `--include-deps' flag. +MKDEP = $(CC) -M $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) -MKDEP = gcc -MM $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) - --include $(srcdir)/.deps/.P -$(srcdir)/.deps/.P: $(BUILT_SOURCES) - cd $(srcdir) && test -d .deps || mkdir .deps +DEPS_MAGIC := $(shell mkdir .deps > /dev/null 2>&1 || :) +-include .deps/.P +.deps/.P: $(BUILT_SOURCES) echo > $@ -include $(DEP_FILES) -$(DEP_FILES): $(srcdir)/.deps/.P - -$(srcdir)/.deps/%.P: $(srcdir)/%.c - @echo "mkdeps $< > $@" - @re=`echo 's,^$(srcdir)//*,,g;s, $(srcdir)//*, ,g' | sed 's,\.,\\\\.,g'`; \ - $(MKDEP) $< | sed "$$re" > $@-tmp - @if test -n "$o"; then \ - sed 's/\.o:/$$o:/' $@-tmp > $@; \ - rm $@-tmp; \ - else \ - mv $@-tmp $@; \ - fi - -# End of maintainer-only section -info: -dvi: +mostlyclean-depend: -check: all +clean-depend: -installcheck: +distclean-depend: +maintainer-clean-depend: + -rm -rf .deps + +.deps/%.P: %.c + @echo "Computing dependencies for $<..." + @o='o'; \ + test -n "$o" && o='$$o'; \ + $(MKDEP) $< >$@.tmp \ + && sed "s,^\(.*\)\.o:,\1.$$o \1.l$$o $@:," < $@.tmp > $@ \ + && rm -f $@.tmp +info: +dvi: +check: all + $(MAKE) +installcheck: install-exec: + @$(NORMAL_INSTALL) install-data: + @$(NORMAL_INSTALL) install: install-exec install-data all @: uninstall: -all: $(LIBFILES) Makefile +all: Makefile $(LIBRARIES) install-strip: - $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' INSTALL_SCRIPT='$(INSTALL_PROGRAM)' install installdirs: mostlyclean-generic: - test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) + -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) clean-generic: - test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: - rm -f Makefile $(DISTCLEANFILES) - rm -f config.cache config.log $(CONFIG_HEADER) stamp-h + -rm -f Makefile $(DISTCLEANFILES) + -rm -f config.cache config.log stamp-h stamp-h[0-9]* + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: - test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) - test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) + -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) mostlyclean: mostlyclean-noinstLIBRARIES mostlyclean-compile \ - mostlyclean-tags mostlyclean-generic + mostlyclean-tags mostlyclean-depend mostlyclean-generic -clean: clean-noinstLIBRARIES clean-compile clean-tags clean-generic \ - mostlyclean +clean: clean-noinstLIBRARIES clean-compile clean-tags clean-depend \ + clean-generic mostlyclean distclean: distclean-noinstLIBRARIES distclean-compile distclean-tags \ - distclean-generic clean - rm -f config.status + distclean-depend distclean-generic clean + -rm -f config.status maintainer-clean: maintainer-clean-noinstLIBRARIES \ maintainer-clean-compile maintainer-clean-tags \ - maintainer-clean-generic distclean + maintainer-clean-depend maintainer-clean-generic \ + distclean @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." @@ -267,14 +320,13 @@ maintainer-clean: maintainer-clean-noinstLIBRARIES \ clean-noinstLIBRARIES maintainer-clean-noinstLIBRARIES \ mostlyclean-compile distclean-compile clean-compile \ maintainer-clean-compile tags mostlyclean-tags distclean-tags \ -clean-tags maintainer-clean-tags distdir info dvi check installcheck \ -install-exec install-data install uninstall all installdirs \ -mostlyclean-generic distclean-generic clean-generic \ +clean-tags maintainer-clean-tags distdir mostlyclean-depend \ +distclean-depend clean-depend maintainer-clean-depend info dvi \ +installcheck install-exec install-data install uninstall all \ +installdirs mostlyclean-generic distclean-generic clean-generic \ maintainer-clean-generic clean mostlyclean distclean maintainer-clean CFLAGS += -O2 -.SUFFIXES: -.SUFFIXES: .c .o $(SUFFIXES) # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/mpi/mpicoder.c b/mpi/mpicoder.c index b371fa64..efb5d090 100644 --- a/mpi/mpicoder.c +++ b/mpi/mpicoder.c @@ -326,6 +326,14 @@ mpi_set_buffer( MPI a, const byte *buffer, unsigned nbytes, int sign ) alimb |= *p-- << 16 ; alimb |= *p-- << 24 ; #elif BYTES_PER_MPI_LIMB == 8 + alimb = *p-- ; + alimb |= *p-- << 8 ; + alimb |= *p-- << 16 ; + alimb |= *p-- << 24 ; + alimb |= *p-- << 32 ; + alimb |= *p-- << 40 ; + alimb |= *p-- << 48 ; + alimb |= *p-- << 56 ; #else #error please implement for this limb size. #endif diff --git a/mpi/mpiutil.c b/mpi/mpiutil.c index 068a9a39..7515eafd 100644 --- a/mpi/mpiutil.c +++ b/mpi/mpiutil.c @@ -1,4 +1,4 @@ -/* mpiutil.c - Utility functions for MPI +/* mpiutilac - Utility functions for MPI * Copyright (c) 1997 by Werner Koch (dd9jn) * * This file is part of G10. @@ -192,6 +192,34 @@ mpi_free( MPI a ) } +void +mpi_set_secure( MPI a ) +{ + mpi_ptr_t ap, bp; + + if( a->secure ) + return; + a->secure = 1; + ap = a->d; + if( !a->nlimbs ) { + assert(!ap); + return; + } + #ifdef M_DEBUG + bp = mpi_debug_alloc_limb_space( a->nlimbs, 1, "set_secure" ); + #else + bp = mpi_alloc_limb_space( a->nlimbs, 1 ); + #endif + MPN_COPY( bp, ap, a->nlimbs ); + a->d = bp; + #ifdef M_DEBUG + mpi_debug_free_limb_space(ap, "set_secure"); + #else + mpi_free_limb_space(ap); + #endif +} + + /**************** * Note: This copy function shpould not interpret the MPI * but copy it transparently. diff --git a/scripts/missing b/scripts/missing new file mode 100755 index 00000000..a6abd069 --- /dev/null +++ b/scripts/missing @@ -0,0 +1,134 @@ +#! /bin/sh +# Common stub for a few missing GNU programs while installing. +# Copyright (C) 1996, 1997 Free Software Foundation, Inc. +# Franc,ois Pinard <pinard@iro.umontreal.ca>, 1996. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. + +# This program 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 General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA +# 02111-1307, USA. + +if test $# -eq 0; then + echo 1>&2 "Try \`$0 --help' for more information" + exit 1 +fi + +case "$1" in + + -h|--h|--he|--hel|--help) + echo "\ +$0 [OPTION]... PROGRAM [ARGUMENT]... + +Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an +error status if there is no known handling for PROGRAM. + +Options: + -h, --help display this help and exit + -v, --version output version information and exit + +Supported PROGRAM values: + aclocal touch file \`aclocal.m4' + autoconf touch file \`configure' + autoheader touch file \`config.h.in' + automake touch all \`Makefile.in' files + bison touch file \`y.tab.c' + makeinfo touch the output file + yacc touch file \`y.tab.c'" + ;; + + -v|--v|--ve|--ver|--vers|--versi|--versio|--version) + echo "missing - GNU libit 0.0" + ;; + + -*) + echo 1>&2 "$0: Unknown \`$1' option" + echo 1>&2 "Try \`$0 --help' for more information" + exit 1 + ;; + + aclocal) + echo 1>&2 "\ +WARNING: \`$1' is missing on your system. You should only need it if + you modified \`acinclude.m4' or \`configure.in'. You might want + to install the \`Automake' and \`Perl' packages. Grab them from + any GNU archive site." + touch aclocal.m4 + ;; + + autoconf) + echo 1>&2 "\ +WARNING: \`$1' is missing on your system. You should only need it if + you modified \`configure.in'. You might want to install the + \`Autoconf' and \`GNU m4' packages. Grab them from any GNU + archive site." + touch configure + ;; + + autoheader) + echo 1>&2 "\ +WARNING: \`$1' is missing on your system. You should only need it if + you modified \`acconfig.h' or \`configure.in'. You might want + to install the \`Autoconf' and \`GNU m4' packages. Grab them + from any GNU archive site." + touch config.h.in + ;; + + automake) + echo 1>&2 "\ +WARNING: \`$1' is missing on your system. You should only need it if + you modified \`Makefile.am', \`acinclude.m4' or \`configure.in'. + You might want to install the \`Automake' and \`Perl' packages. + Grab them from any GNU archive site." + find . -type f -name Makefile.am -print \ + | sed 's/^\(.*\).am$/touch \1.in/' \ + | sh + ;; + + bison|yacc) + echo 1>&2 "\ +WARNING: \`$1' is missing on your system. You should only need it if + you modified a \`.y' file. You may need the \`Bison' package + in order for those modifications to take effect. You can get + \`Bison' from any GNU archive site." + touch y.tab.c + ;; + + makeinfo) + echo 1>&2 "\ +WARNING: \`$1' is missing on your system. You should only need it if + you modified a \`.texi' or \`.texinfo' file, or any other file + indirectly affecting the aspect of the manual. The spurious + call might also be the consequence of using a buggy \`make' (AIX, + DU, IRIX). You might want to install the \`Texinfo' package or + the \`GNU make' package. Grab either from any GNU archive site." + file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` + if test -z "$file"; then + file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` + file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file` + fi + touch $file + ;; + + *) + echo 1>&2 "\ +WARNING: \`$1' is needed, and you do not seem to have it handy on your + system. You might have modified some files without having the + proper tools for further handling them. Check the \`README' file, + it often tells you about the needed prerequirements for installing + this package. You may also peek at any GNU archive site, in case + some other package would contain this missing \`$1' program." + exit 1 + ;; +esac + +exit 0 |