From 5a9491f84a37e7f1e963a9813ee6de10179a9da5 Mon Sep 17 00:00:00 2001 From: Tobias Johansson Date: Thu, 12 Dec 2024 17:15:58 +0100 Subject: [PATCH] Add C++20 support for AndroidAgde platform --- .../Android/AndroidAgdePlatform.cs | 4 +++- Sharpmake/Options.Agde.cs | 18 +++++++++++++++++- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/Sharpmake.Platforms/Sharpmake.CommonPlatforms/Android/AndroidAgdePlatform.cs b/Sharpmake.Platforms/Sharpmake.CommonPlatforms/Android/AndroidAgdePlatform.cs index 8e0126fa1..2ed826aa9 100644 --- a/Sharpmake.Platforms/Sharpmake.CommonPlatforms/Android/AndroidAgdePlatform.cs +++ b/Sharpmake.Platforms/Sharpmake.CommonPlatforms/Android/AndroidAgdePlatform.cs @@ -398,12 +398,14 @@ public override void SelectCompilerOptions(IGenerationContext context) Options.Option(Options.Agde.Compiler.CppLanguageStandard.Cpp14, () => { options["CppLanguageStandard"] = "cpp14"; cmdLineOptions["CppLanguageStd"] = "-std=c++14"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Cpp1z, () => { options["CppLanguageStandard"] = "cpp1z"; cmdLineOptions["CppLanguageStd"] = "-std=c++1z"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Cpp17, () => { options["CppLanguageStandard"] = "cpp17"; cmdLineOptions["CppLanguageStd"] = "-std=c++17"; }), + Options.Option(Options.Agde.Compiler.CppLanguageStandard.Cpp20, () => { options["CppLanguageStandard"] = "cpp20"; cmdLineOptions["CppLanguageStd"] = "-std=c++20"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp98, () => { options["CppLanguageStandard"] = "gnupp98"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++98"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp03, () => { options["CppLanguageStandard"] = "gnupp03"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++03"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp11, () => { options["CppLanguageStandard"] = "gnupp11"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++11"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp14, () => { options["CppLanguageStandard"] = "gnupp14"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++14"; }), Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp1z, () => { options["CppLanguageStandard"] = "gnupp1z"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++1z"; }), - Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp17, () => { options["CppLanguageStandard"] = "gnupp17"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++17"; }) + Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp17, () => { options["CppLanguageStandard"] = "gnupp17"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++17"; }), + Options.Option(Options.Agde.Compiler.CppLanguageStandard.Gnupp20, () => { options["CppLanguageStandard"] = "gnupp20"; cmdLineOptions["CppLanguageStd"] = "-std=gnu++20"; }) ); context.SelectOption diff --git a/Sharpmake/Options.Agde.cs b/Sharpmake/Options.Agde.cs index ab2acf846..b0d17acfa 100644 --- a/Sharpmake/Options.Agde.cs +++ b/Sharpmake/Options.Agde.cs @@ -436,6 +436,14 @@ public enum CppLanguageStandard /// Cpp17, + /// + /// C++20 + /// + /// + /// C++20 Language Standard. + /// + Cpp20, + /// /// C++98 (GNU Dialect) /// @@ -482,7 +490,15 @@ public enum CppLanguageStandard /// /// C++17 (GNU Dialect) Language Standard. /// - Gnupp17 + Gnupp17, + + /// + /// C++20 (GNU Dialect) + /// + /// + /// C++20 (GNU Dialect) Language Standard. + /// + Gnupp20 } ///