From 56b7a9d701ba181e373f58f9ed5ab65368e87407 Mon Sep 17 00:00:00 2001 From: serge-sans-paille Date: Thu, 29 Aug 2024 07:42:33 +0000 Subject: [PATCH] Bug 1907180 - Remove obsolete AC_CANONICAL_SYSTEM from old-configure r=glandium Differential Revision: https://phabricator.services.mozilla.com/D216219 --- build/moz.configure/init.configure | 14 ++------------ build/moz.configure/old.configure | 8 +++----- js/src/old-configure.in | 1 - old-configure.in | 1 - toolkit/mozapps/installer/informulate.py | 8 ++++---- 5 files changed, 9 insertions(+), 23 deletions(-) diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure index df621905dae5..47280f3f60f6 100644 --- a/build/moz.configure/init.configure +++ b/build/moz.configure/init.configure @@ -802,18 +802,8 @@ set_define( "WORDS_BIGENDIAN", True, when=depends(target.endianness)(lambda e: e == "big") ) - -# Autoconf needs these set - - -@depends(host) -def host_for_sub_configure(host): - return "--host=%s" % host.sub_configure_alias - - -@depends(target) -def target_for_sub_configure(target): - return "--target=%s" % target.sub_configure_alias +set_config("host", host.sub_configure_alias) +set_config("target", target.sub_configure_alias) # These variables are for compatibility with the current moz.builds and diff --git a/build/moz.configure/old.configure b/build/moz.configure/old.configure index 579dc0d8d123..c99dabc0fb23 100644 --- a/build/moz.configure/old.configure +++ b/build/moz.configure/old.configure @@ -89,9 +89,7 @@ def old_configure_options(*options): def all_options(): return list(options) - return depends( - host_for_sub_configure, target_for_sub_configure, all_options, *options - ) + return depends(all_options, *options) @old_configure_options( @@ -101,7 +99,7 @@ def old_configure_options(*options): "--x-includes", "--x-libraries", ) -def prepare_configure_options(host, target, all_options, *options): +def prepare_configure_options(all_options, *options): # old-configure only supports the options listed in @old_configure_options # so we don't need to pass it every single option we've been passed. Only # the ones that are not supported by python configure need to. @@ -109,7 +107,7 @@ def prepare_configure_options(host, target, all_options, *options): value.format(name) for name, value in zip(all_options, options) if value.origin != "default" - ] + [host, target] + ] return namespace(options=options, all_options=all_options) diff --git a/js/src/old-configure.in b/js/src/old-configure.in index f018ac989ccd..415cb44b465c 100644 --- a/js/src/old-configure.in +++ b/js/src/old-configure.in @@ -9,7 +9,6 @@ dnl ======================================================== AC_PREREQ(2.13) AC_INIT(js/src/jsapi.h) AC_CONFIG_AUX_DIR(${srcdir}/build/autoconf) -AC_CANONICAL_SYSTEM dnl ======================================================== dnl = diff --git a/old-configure.in b/old-configure.in index edbb689c45ab..036734708f20 100644 --- a/old-configure.in +++ b/old-configure.in @@ -9,7 +9,6 @@ dnl ======================================================== AC_PREREQ(2.13) AC_INIT(config/config.mk) AC_CONFIG_AUX_DIR(${srcdir}/build/autoconf) -AC_CANONICAL_SYSTEM dnl ======================================================== dnl = diff --git a/toolkit/mozapps/installer/informulate.py b/toolkit/mozapps/installer/informulate.py index 0f646450c5be..1d3472eb30dc 100644 --- a/toolkit/mozapps/installer/informulate.py +++ b/toolkit/mozapps/installer/informulate.py @@ -30,8 +30,8 @@ def main(): mozinfo.find_and_update_from_json() important_substitutions = [ - "target_alias", - "host_alias", + "target", + "host", "MOZ_UPDATE_CHANNEL", "MOZ_APP_VENDOR", "MOZ_APP_NAME", @@ -81,8 +81,8 @@ def main(): "as": all_key_value_pairs["as"], "cc": all_key_value_pairs["cc"], "cxx": all_key_value_pairs["cxx"], - "host": s["host_alias"], - "target": s["target_alias"], + "host": s["host"], + "target": s["target"], }, "source": { "product": s["MOZ_APP_NAME"],