From 986a7d71b21058876183347ae84c35665aa563ee Mon Sep 17 00:00:00 2001 From: Alejandro R Mosteo Date: Tue, 1 Aug 2023 12:24:36 +0200 Subject: [PATCH] Don't treat warnings as erros when no style checks (#1412) --- alire_common.gpr | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/alire_common.gpr b/alire_common.gpr index fe3e9e00..ef341d56 100644 --- a/alire_common.gpr +++ b/alire_common.gpr @@ -2,9 +2,9 @@ abstract project Alire_Common is for Create_Missing_Dirs use "True"; - type Host_OSes is ("linux", - "freebsd", - "macos", + type Host_OSes is ("linux", + "freebsd", + "macos", "windows"); Host_OS : Host_OSes := external ("ALIRE_OS"); @@ -23,7 +23,8 @@ abstract project Alire_Common is Style_Check_Switches := (); case Style_Check_Mode is when "enabled" => Style_Check_Switches := - ("-gnatyg", -- Standard checks + ("-gnatwe", -- Warnings as errors + "-gnatyg", -- Standard checks "-gnatyI", -- no IN mode "-gnatyO", -- all overrides "-gnaty-s"); -- relax fwd decl @@ -52,8 +53,8 @@ abstract project Alire_Common is -- Report Elaboration Circularity Details "-gnatd_F", - -- Enable all warnings and treat them as errors - "-gnatwae") + -- Enable all warnings + "-gnatwa") & Style_Check_Switches; for Default_Switches ("C") use ("-g", "-O0", "-Wall"); -- 2.39.5