diff --git a/.tarball-version b/.tarball-version index 7c89eb42b..cdf962560 100644 --- a/.tarball-version +++ b/.tarball-version @@ -1 +1 @@ -1.21.3-at.20231213.02 +1.21.3-at.20231213.03 diff --git a/.version b/.version index 7c89eb42b..cdf962560 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -1.21.3-at.20231213.02 +1.21.3-at.20231213.03 diff --git a/configure.ac b/configure.ac index 09047d0df..8e0a8a9b7 100644 --- a/configure.ac +++ b/configure.ac @@ -57,11 +57,39 @@ AC_USE_SYSTEM_EXTENSIONS AC_PROG_CC dnl -dnl Get canonical host +dnl Get canonical host system dnl AC_CANONICAL_HOST AC_DEFINE_UNQUOTED([OS_TYPE], "$host_os", [Define to be the name of the operating system.]) +AC_DEFINE_UNQUOTED([SYSTEM_HOST_OS], "$host_os", + [Define to be the name of the host operating system.]) +AC_DEFINE_UNQUOTED([SYSTEM_HOST_CPU], "$host_cpu", + [Define to be the name of the host CPU.]) +AC_DEFINE_UNQUOTED([SYSTEM_HOST_VENDOR], "$host_vendor", + [Define to be the name of the host vendor.]) + +dnl +dnl Get canonical build system +dnl +AC_CANONICAL_BUILD +AC_DEFINE_UNQUOTED([SYSTEM_BUILD_OS], "$build_os", + [Define to be the name of the build operating system.]) +AC_DEFINE_UNQUOTED([SYSTEM_BUILD_CPU], "$build_cpu", + [Define to be the name of the build CPU.]) +AC_DEFINE_UNQUOTED([SYSTEM_BUILD_VENDOR], "$build_vendor", + [Define to be the name of the build vendor.]) + +dnl +dnl Get canonical target system +dnl +AC_CANONICAL_TARGET +AC_DEFINE_UNQUOTED([SYSTEM_TARGET_OS], "$target_os", + [Define to be the name of the target operating system.]) +AC_DEFINE_UNQUOTED([SYSTEM_TARGET_CPU], "$target_cpu", + [Define to be the name of the target CPU.]) +AC_DEFINE_UNQUOTED([SYSTEM_TARGET_VENDOR], "$target_vendor", + [Define to be the name of the target vendor.]) dnl Non-verbose make m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) diff --git a/src/main.c b/src/main.c index 7a2883ee3..d10e13fe9 100644 --- a/src/main.c +++ b/src/main.c @@ -1101,9 +1101,11 @@ Recursive accept/reject:\n"), -np, --no-parent don't ascend to the parent directory\n"), "\n", N_("Email bug reports, questions, discussions to \n" - "and/or open issues at https://savannah.gnu.org/bugs/?func=additem&group=wget.\n") + "and/or open issues at https://savannah.gnu.org/bugs/?func=additem&group=wget.\n"), + "\n", N_("For the additions in Wget-AT over Wget please open an issue at\n" - "https://github.com/ArchiveTeam/wget-lua.\n") + "https://github.com/ArchiveTeam/wget-lua, send an email to\n" + ", or visit #archiveteam-dev on hackint IRC.\n") }; size_t i; @@ -1417,7 +1419,12 @@ There is NO WARRANTY, to the extent permitted by law.\n"), stdout) < 0) if (fputs (_("\nOriginally written by Hrvoje Niksic .\n"), stdout) < 0) exit (WGET_EXIT_IO_FAIL); - if (fputs (_("Please send bug reports and questions to .\n"), + if (fputs (_("For original Wget please send bug reports and questions to\n.\n"), + stdout) < 0) + exit (WGET_EXIT_IO_FAIL); + if (fputs (_("\nFor the additions in Wget-AT over Wget please open an issue at\n" + "https://github.com/ArchiveTeam/wget-lua, send an email to\n" + ", or visit #archiveteam-dev on hackint IRC.\n"), stdout) < 0) exit (WGET_EXIT_IO_FAIL); diff --git a/src/warc.c b/src/warc.c index 419450f82..416217a88 100644 --- a/src/warc.c +++ b/src/warc.c @@ -989,6 +989,7 @@ warc_write_warcinfo_record (const char *filename) FILE *warc_tmp; char timestamp[22]; char *filename_basename; + int i; /* Write warc-info record as the first record of the file. */ /* We add the record id of this info record to the other records in the @@ -1015,17 +1016,39 @@ warc_write_warcinfo_record (const char *filename) return false; } - if (fprintf (warc_tmp, "software: Wget/%s (%s)\r\n", version_string, OS_TYPE) < 0 + if (fprintf (warc_tmp, "operator: Archive Team \r\n") < 0 + || fprintf (warc_tmp, "software: Wget/%s (%s)\r\n", version_string, OS_TYPE) < 0 || fprintf (warc_tmp, "format: WARC File Format 1.1\r\n") < 0 || fprintf (warc_tmp, "conformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1-1_latestdraft.pdf\r\n") < 0 || fprintf (warc_tmp, "robots: %s\r\n", (opt.use_robots ? "classic" : "off")) < 0 - || fprintf (warc_tmp, "wget-arguments: %s\r\n", program_argstring) < 0) + || fprintf (warc_tmp, "wget-arguments: %s\r\n", program_argstring) < 0 + || fprintf (warc_tmp, "wget-build-version: %s\r\n", version_string) < 0 + || fprintf (warc_tmp, "wget-build-system-host: %s-%s-%s\r\n", + SYSTEM_HOST_CPU, SYSTEM_HOST_VENDOR, SYSTEM_HOST_OS) < 0 + || fprintf (warc_tmp, "wget-build-system-build: %s-%s-%s\r\n", + SYSTEM_BUILD_CPU, SYSTEM_BUILD_VENDOR, SYSTEM_BUILD_OS) < 0 + || fprintf (warc_tmp, "wget-build-system-target: %s-%s-%s\r\n", + SYSTEM_TARGET_CPU, SYSTEM_TARGET_VENDOR, SYSTEM_TARGET_OS) < 0 + || fprintf (warc_tmp, "wget-build-compilation-string: %s\r\n", compilation_string) < 0 + || fprintf (warc_tmp, "wget-build-link-string: %s\r\n", link_string) < 0 + || fprintf (warc_tmp, "wget-build-features: ") < 0) { warc_write_ok = false; return false; } + for (i = 0; compiled_features[i]; i++) + { + if (fprintf (warc_tmp, "%s", compiled_features[i]) < 0 + || (compiled_features[i+1] != NULL && fprintf (warc_tmp, " ") < 0) + || (compiled_features[i+1] == NULL && fprintf (warc_tmp, "\r\n") < 0)) + { + warc_write_ok = false; + return false; + } + } + /* Add the user headers, if any. */ if (opt.warc_user_headers) {