From 5b35d59e236519b7934e22ea7fd857ccf536eec7 Mon Sep 17 00:00:00 2001
From: Olivier Hainque <hainque@adacore.com>
Date: Wed, 5 Jan 2022 09:07:33 +0000
Subject: [PATCH] State --sysroot option as validated once processed

Since we now save the option in the "switches" table
to let specs use it more generally, we need to explicitly
state that the option was validated else the driver
will consider it "unrecognized".

2022-01-05  Olivier Hainque  <hainque@adacore.com>

	* gcc.c (driver_handle_option): State --sysroot as
	validated.
---
 gcc/gcc.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gcc/gcc.c b/gcc/gcc.c
index d4c8746b0aa..29fa0f7ddce 100644
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -4495,6 +4495,7 @@ driver_handle_option (struct gcc_options *opts,
       /* Saving this option is useful to let self-specs decide to
 	 provide a default one.  */
       do_save = true;
+      validated = true;
       break;
 
     case OPT_time_:
-- 
2.25.1

