From cd46068a07318446454cc03298a239c16a66f57a Mon Sep 17 00:00:00 2001 From: Eduardo Chappa Date: Tue, 21 Nov 2017 10:28:57 -0700 Subject: * Add --with-date-stamp and --with-host-stamp to modify the datestamp[] and hoststamp[] default variables when building Alpine. --- alpine/Makefile.am | 4 ++-- alpine/Makefile.in | 44 ++++++++++++++----------------------------- configure | 36 +++++++++++++++++++++++++++++++++++ configure.ac | 21 +++++++++++++++++++++ pith/pine.hlp | 2 +- web/src/alpined.d/Makefile.am | 4 ++-- web/src/alpined.d/Makefile.in | 44 ++++++++++++++----------------------------- 7 files changed, 90 insertions(+), 65 deletions(-) diff --git a/alpine/Makefile.am b/alpine/Makefile.am index 3dab9c5e..e1de6093 100644 --- a/alpine/Makefile.am +++ b/alpine/Makefile.am @@ -49,5 +49,5 @@ AM_LDFLAGS = `cat @top_srcdir@/c-client/LDFLAGS` CLEANFILES = date.c date.c: - echo "char datestamp[]="\"`date`\"";" > date.c - echo "char hoststamp[]="\"`hostname`\"";" >> date.c + echo "char datestamp[]="\"$(ALPINE_DATESTAMP)\"";" > date.c + echo "char hoststamp[]="\"$(ALPINE_HOSTSTAMP)\"";" >> date.c diff --git a/alpine/Makefile.in b/alpine/Makefile.in index 0a694ab3..449efa3f 100644 --- a/alpine/Makefile.in +++ b/alpine/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.15 from Makefile.am. +# Makefile.in generated by automake 1.13.4 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2014 Free Software Foundation, Inc. +# Copyright (C) 1994-2013 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -27,17 +27,7 @@ # ======================================================================== VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} +am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)' am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ @@ -102,6 +92,8 @@ build_triplet = @build@ host_triplet = @host@ bin_PROGRAMS = alpine$(EXEEXT) rpdump$(EXEEXT) rpload$(EXEEXT) subdir = alpine +DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ + $(top_srcdir)/mkinstalldirs $(top_srcdir)/depcomp ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/acx_pthread.m4 \ $(top_srcdir)/m4/gettext.m4 $(top_srcdir)/m4/iconv.m4 \ @@ -110,16 +102,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acx_pthread.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ - $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/configure.ac + $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/config.h CONFIG_CLEAN_FILES = @@ -231,8 +216,6 @@ am__define_uniq_tagged_files = \ ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) -am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \ - $(top_srcdir)/mkinstalldirs DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) am__relativize = \ dir0=`pwd`; \ @@ -260,6 +243,8 @@ am__relativize = \ done; \ reldir="$$dir2" ACLOCAL = @ACLOCAL@ +ALPINE_DATESTAMP = @ALPINE_DATESTAMP@ +ALPINE_HOSTSTAMP = @ALPINE_HOSTSTAMP@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ @@ -276,6 +261,7 @@ CP = @CP@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CYGPATH_W = @CYGPATH_W@ +C_CLIENT_AUTHS = @C_CLIENT_AUTHS@ C_CLIENT_CFLAGS = @C_CLIENT_CFLAGS@ C_CLIENT_GCCOPTLEVEL = @C_CLIENT_GCCOPTLEVEL@ C_CLIENT_LDFLAGS = @C_CLIENT_LDFLAGS@ @@ -319,7 +305,6 @@ LS = @LS@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKE = @MAKE@ MAKEINFO = @MAKEINFO@ @@ -459,6 +444,7 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__confi echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign alpine/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign alpine/Makefile +.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -592,14 +578,14 @@ distclean-compile: @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -898,12 +884,10 @@ uninstall-am: uninstall-binPROGRAMS mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ uninstall-am uninstall-binPROGRAMS -.PRECIOUS: Makefile - date.c: - echo "char datestamp[]="\"`date`\"";" > date.c - echo "char hoststamp[]="\"`hostname`\"";" >> date.c + echo "char datestamp[]="\"$(ALPINE_DATESTAMP)\"";" > date.c + echo "char hoststamp[]="\"$(ALPINE_HOSTSTAMP)\"";" >> date.c # 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 b/configure index 839abe69..2ef7b09a 100755 --- a/configure +++ b/configure @@ -664,6 +664,8 @@ SPELLPROG PWPROG NPA_PROG SENDMAIL +ALPINE_HOSTSTAMP +ALPINE_DATESTAMP POSUB LTLIBINTL LIBINTL @@ -819,6 +821,8 @@ with_libiconv_prefix with_libintl_prefix enable_dmalloc with_dmalloc_dir +with_date_stamp +with_host_stamp with_ps_cmd with_localedir enable_osx_universal_binaries @@ -1589,6 +1593,10 @@ Optional Packages: --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib --without-libintl-prefix don't search for libintl in includedir and libdir --with-dmalloc-dir=DIR Root of dmalloc lib/include path + --with-date-stamp=DATE Set this as the date this program was built. + Default: output of `date` + --with-host-stamp=HOST Set name of computer for compilation. Default: + output of `hostname` --with-ps-cmd="CMD" Use this command to check running commands. Default: /bin/ps auxww --with-localedir=DIR Name of gettext locale directory @@ -14372,6 +14380,34 @@ $as_echo "#define ENABLE_DMALLOC 1" >>confdefs.h fi +ALPINE_datestamp=`date` + +# Check whether --with-date-stamp was given. +if test "${with_date_stamp+set}" = set; then : + withval=$with_date_stamp; + if test "x$withval" != "xno" ; then + ALPINE_datestamp=$withval + fi + +fi + +ALPINE_DATESTAMP=$ALPINE_datestamp + + +ALPINE_hoststamp=`hostname` + +# Check whether --with-host-stamp was given. +if test "${with_host_stamp+set}" = set; then : + withval=$with_host_stamp; + if test "x$withval" != "xno" ; then + ALPINE_hoststamp="$withval" + fi + +fi + +ALPINE_HOSTSTAMP=$ALPINE_hoststamp + + ALPINE_psefcmd="/bin/ps auxww" ALPINE_psfailed="0" ALPINE_PSTEST="-" diff --git a/configure.ac b/configure.ac index f72532f9..d4720188 100644 --- a/configure.ac +++ b/configure.ac @@ -84,6 +84,27 @@ if test x$enable_dmalloc = "xyes" ; then AC_DEFINE(ENABLE_DMALLOC, 1, [Define enable dmalloc debugging]) fi +dnl set date and hostname +ALPINE_datestamp=`date` +AC_ARG_WITH(date-stamp, + AS_HELP_STRING([--with-date-stamp=DATE],[Set this as the date this program was built. Default: output of `date`]), + [ + if test "x$withval" != "xno" ; then + ALPINE_datestamp=$withval + fi + ]) +AC_SUBST([ALPINE_DATESTAMP], $ALPINE_datestamp) + +ALPINE_hoststamp=`hostname` +AC_ARG_WITH(host-stamp, + AS_HELP_STRING([--with-host-stamp=HOST],[Set name of computer for compilation. Default: output of `hostname`]), + [ + if test "x$withval" != "xno" ; then + ALPINE_hoststamp="$withval" + fi + ]) +AC_SUBST([ALPINE_HOSTSTAMP], $ALPINE_hoststamp) + dnl set ps command, this test is fragile, but it should mostly work ALPINE_psefcmd="/bin/ps auxww" ALPINE_psfailed="0" diff --git a/pith/pine.hlp b/pith/pine.hlp index 453eba97..027783b6 100644 --- a/pith/pine.hlp +++ b/pith/pine.hlp @@ -140,7 +140,7 @@ with help text for the config screen and the composer that didn't have any reasonable place to be called from. Dummy change to get revision in pine.hlp ============= h_revision ================= -Alpine Commit 230 2017-11-20 23:24:51 +Alpine Commit 231 2017-11-21 10:28:38 ============= h_news ================= diff --git a/web/src/alpined.d/Makefile.am b/web/src/alpined.d/Makefile.am index 524cb7e1..91b9acc3 100644 --- a/web/src/alpined.d/Makefile.am +++ b/web/src/alpined.d/Makefile.am @@ -52,5 +52,5 @@ CLEANFILES = local.c local.c: alpineldap.c color.c imap.c ldap.c remote.c signal.c \ debug.c status.c stubs.c alpined.h color.h ldap.h - echo "char datestamp[]="\"`date`\"";" > local.c - echo "char hoststamp[]="\"`hostname`\"";" >> local.c + echo "char datestamp[]="\"$(ALPINE_DATESTAMP)\"";" > local.c + echo "char hoststamp[]="\"$(ALPINE_HOSTSTAMP)\"";" >> local.c diff --git a/web/src/alpined.d/Makefile.in b/web/src/alpined.d/Makefile.in index 14da8e79..266a8569 100644 --- a/web/src/alpined.d/Makefile.in +++ b/web/src/alpined.d/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.15 from Makefile.am. +# Makefile.in generated by automake 1.13.4 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2014 Free Software Foundation, Inc. +# Copyright (C) 1994-2013 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -27,17 +27,7 @@ VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} +am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)' am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ @@ -102,6 +92,8 @@ build_triplet = @build@ host_triplet = @host@ locbin_PROGRAMS = alpined$(EXEEXT) alpineldap$(EXEEXT) subdir = web/src/alpined.d +DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ + $(top_srcdir)/mkinstalldirs $(top_srcdir)/depcomp ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/acx_pthread.m4 \ $(top_srcdir)/m4/gettext.m4 $(top_srcdir)/m4/iconv.m4 \ @@ -110,16 +102,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acx_pthread.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ - $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/VERSION $(top_srcdir)/VERSION \ - $(top_srcdir)/configure.ac + $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/config.h CONFIG_CLEAN_FILES = @@ -243,10 +228,10 @@ am__define_uniq_tagged_files = \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags -am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \ - $(top_srcdir)/mkinstalldirs DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALPINE_DATESTAMP = @ALPINE_DATESTAMP@ +ALPINE_HOSTSTAMP = @ALPINE_HOSTSTAMP@ AMTAR = @AMTAR@ AM_CFLAGS = @AM_CFLAGS@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ @@ -263,6 +248,7 @@ CP = @CP@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CYGPATH_W = @CYGPATH_W@ +C_CLIENT_AUTHS = @C_CLIENT_AUTHS@ C_CLIENT_CFLAGS = @C_CLIENT_CFLAGS@ C_CLIENT_GCCOPTLEVEL = @C_CLIENT_GCCOPTLEVEL@ C_CLIENT_LDFLAGS = @C_CLIENT_LDFLAGS@ @@ -306,7 +292,6 @@ LS = @LS@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAINT = @MAINT@ MAKE = @MAKE@ MAKEINFO = @MAKEINFO@ @@ -451,6 +436,7 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__confi echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign web/src/alpined.d/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign web/src/alpined.d/Makefile +.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -588,14 +574,14 @@ distclean-compile: @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -819,13 +805,11 @@ uninstall-am: uninstall-locbinPROGRAMS uninstall-loclibLTLIBRARIES tags tags-am uninstall uninstall-am uninstall-locbinPROGRAMS \ uninstall-loclibLTLIBRARIES -.PRECIOUS: Makefile - local.c: alpineldap.c color.c imap.c ldap.c remote.c signal.c \ debug.c status.c stubs.c alpined.h color.h ldap.h - echo "char datestamp[]="\"`date`\"";" > local.c - echo "char hoststamp[]="\"`hostname`\"";" >> local.c + echo "char datestamp[]="\"$(ALPINE_DATESTAMP)\"";" > local.c + echo "char hoststamp[]="\"$(ALPINE_HOSTSTAMP)\"";" >> local.c # 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. -- cgit v1.2.3-70-g09d2