+2013-08-27 Keith Marshall <keithmarshall@users.sourceforge.net>
+
+ Add support for automated catalogue publication.
+
+ * Makefile.comm.in (published): New build goal; it redirects to the
+ new primary goal implemented...
+
+ * Makefile.in: ...here.
+ (published): New primary build goal; implement it, using...
+ (frs-username-check, frs-publish): ...these new internal build goals;
+ implement them; they should not normally be invoked directly.
+ (FRS_USERNAME, FRS_CATALOGUE): New macros; define them.
+ (FRS_CATALOGUE_HOST, FRS_CATALOGUE_ROOT, FRS_CATALOGUE_PATH):
+ (MAKE_RECURSIVE, PRIMARY_GOALS): Likewise.
+
+ * configure.ac (AC_INIT): Bump version number to 2.2
+ (FRS_USERNAME): Declare it as precious; assign "anonymous" as default.
+
2013-08-26 Keith Marshall <keithmarshall@users.sourceforge.net>
Correct a catalogue publication anomaly.
# Package lists are dynamically updated, to record the latest issues of each
# referenced package catalogue; the "sed" script used to accomplish this must
-# be generated, and driven from, within the top build directory.
+# be generated, and driven from, within the top build directory. Similarly,
+# the procedure for publishing updated catalogues to the file release system
+# must be directed to the top build directory, to process the entire tree.
#
-update-references issue.sed: FORCE
+published update-references issue.sed: FORCE
cd ${top_builddir}; $(MAKE) $@
# Requests to update references will be redirected back to each sub-directory
#
update-local-references: @mingw_ac_subdirs@
+# Approiately authenticated users may publish updated catalogues
+# via the SourceForge file release system.
+#
+FRS_CATALOGUE_HOST = frs.sourceforge.net
+FRS_CATALOGUE_ROOT = /home/frs/project/mingw
+FRS_CATALOGUE_PATH = $(FRS_CATALOGUE_ROOT)/Installer/mingw-get/catalogue
+
+FRS_CATALOGUE = $(FRS_CATALOGUE_HOST):$(FRS_CATALOGUE_PATH)
+
+published:
+ rm -rf tmp; mkdir tmp
+ cd tmp; @LN_S@ ../*/unpublished/* .
+ @test "x`cd tmp; echo *`x" = 'x*x' \
+ && echo "NOTE: there are no catalogue files awaiting publication" \
+ || $(MAKE_RECURSIVE) frs-publish
+ rm -rf tmp
+
+# Publication of updated catalogues, to the file release system,
+# requires an authorised SourceForge user name specification.
+#
+FRS_USERNAME = @FRS_USERNAME@
+MAKE_RECURSIVE = $(MAKE)@NO_PRINT_DIRECTORY@ PRIMARY_GOALS=$(MAKECMDGOALS)
+frs-username-check:
+ @test "x$(FRS_USERNAME)" = "xanonymous" && \
+ { echo 'ERROR: "$(FRS_USERNAME)" is not a valid FRS_USERNAME'; \
+ echo 'please try "make FRS_USERNAME=username $(PRIMARY_GOALS)"'; \
+ exit 1; \
+ } || true
+
+# For potentially valid user names, publication entails an sftp
+# upload of all staged catalogues, to the file release system.
+#
+frs-publish: frs-username-check
+ cd tmp; echo 'put *' | sftp $(FRS_USERNAME)@$(FRS_CATALOGUE)
+ rm -f */unpublished/*
+
# The following goals may be specified, when building as a sub-project
# of mingw-get-setup; pass each request to all designated subdirectories,
# in each of which it will become a no-op.
# MinGW Project, accept liability for any damages, however caused,
# arising from the use of this software.
#
- AC_INIT([mingw-dist],[2.1],[http://mingw.org/reporting_bugs])
+ AC_INIT([mingw-dist],[2.2],[http://mingw.org/reporting_bugs])
+
+# Specify a default (invalid) user name, for authentication to FRS.
+#
+ : ${FRS_USERNAME="anonymous"}
+ AC_ARG_VAR([FRS_USERNAME],[user name for FRS authentication [anonymous]])
# Check for required tools.
#