From 7e209886c6c1c3bbfcf154f871f2a14e45e1bbc5 Mon Sep 17 00:00:00 2001 From: Supakorn 'Jamie' Rassameemasmuang Date: Sun, 4 Feb 2024 13:05:39 -0700 Subject: [PATCH 1/4] CMAKE: Remove redundant asy-base-file target. (cherry picked from commit fda3082675200917795903267d3db07f284dad41) --- cmake-scripts/asy-base-files.cmake | 3 --- 1 file changed, 3 deletions(-) diff --git a/cmake-scripts/asy-base-files.cmake b/cmake-scripts/asy-base-files.cmake index 790d30a15..b74788bfd 100644 --- a/cmake-scripts/asy-base-files.cmake +++ b/cmake-scripts/asy-base-files.cmake @@ -27,9 +27,6 @@ configure_file(${ASY_RESOURCE_DIR}/versionTemplate.asy.in ${ASY_BUILD_BASE_DIR}/ list(APPEND ASY_OUTPUT_BASE_FILES ${ASY_BUILD_BASE_DIR}/version.asy) # copy base files to build dir - -add_custom_target(asy_base_files) - macro (copy_base_file base_file_name) add_custom_command( COMMAND ${CMAKE_COMMAND} -E copy From 569a4000a422d2fcce5bb2063fe30aebf3344761 Mon Sep 17 00:00:00 2001 From: Supakorn 'Jamie' Rassameemasmuang Date: Tue, 9 Jan 2024 02:05:12 -0700 Subject: [PATCH 2/4] clang-format: Use C++17 as formatting standard. (cherry picked from commit 0ea0878a89bff32ca48b94629c51516e9a0b7e1d) --- .clang-format | 1 + 1 file changed, 1 insertion(+) diff --git a/.clang-format b/.clang-format index f0af5c4b0..b5ade5dde 100644 --- a/.clang-format +++ b/.clang-format @@ -1,6 +1,7 @@ # Generated from CLion C/C++ Code Style settings BasedOnStyle: LLVM AccessModifierOffset: -2 +Standard: c++17 AlignAfterOpenBracket: BlockIndent AlignConsecutiveAssignments: None AlignOperands: Align From a01f322b53d6f1162e3ff06d8c3d47aa3e909ee5 Mon Sep 17 00:00:00 2001 From: Supakorn 'Jamie' Rassameemasmuang Date: Tue, 9 Jan 2024 02:46:25 -0700 Subject: [PATCH 3/4] clang-format: Add BreakAttributes to formatting. (cherry picked from commit 9c3bccfe8508a0eb425228b1cc63bd010aeb460f) --- .clang-format | 1 + 1 file changed, 1 insertion(+) diff --git a/.clang-format b/.clang-format index b5ade5dde..226ed0e85 100644 --- a/.clang-format +++ b/.clang-format @@ -16,6 +16,7 @@ AllowShortLambdasOnASingleLine: All AllowShortLoopsOnASingleLine: true AlwaysBreakAfterReturnType: None AlwaysBreakTemplateDeclarations: Yes +BreakAfterAttributes: Always BreakBeforeBraces: Custom BraceWrapping: AfterCaseLabel: false From 28027e8fdec3389e229fa784c713b9d5f87487fa Mon Sep 17 00:00:00 2001 From: Supakorn 'Jamie' Rassameemasmuang Date: Mon, 15 Jan 2024 23:30:45 -0700 Subject: [PATCH 4/4] CMAKE: Add Debug compile flag to all debug builds. (cherry picked from commit ccc94a2ac66f88850d6295686701ff1c3cadab81) --- cmake-scripts/asy-macro.cmake | 4 ++++ cmake-scripts/common.cmake | 1 + 2 files changed, 5 insertions(+) diff --git a/cmake-scripts/asy-macro.cmake b/cmake-scripts/asy-macro.cmake index 8c0b2564e..d393db61d 100644 --- a/cmake-scripts/asy-macro.cmake +++ b/cmake-scripts/asy-macro.cmake @@ -24,3 +24,7 @@ endif() if (CMAKE_SYSTEM_NAME STREQUAL "Linux") list(APPEND ASY_MACROS LINUX_SYSTEM) endif() + +if (CMAKE_BUILD_TYPE IN_LIST cmake_debug_build_types) + list(APPEND ASY_MACROS DEBUG) +endif() diff --git a/cmake-scripts/common.cmake b/cmake-scripts/common.cmake index e2bab8497..8316f7182 100644 --- a/cmake-scripts/common.cmake +++ b/cmake-scripts/common.cmake @@ -3,3 +3,4 @@ macro(TODO_NOTIMPL message) endmacro() set(cmake_release_build_types Release RelWithDebInfo MinSizeRel) +set(cmake_debug_build_types Debug)