updates submodules
This commit is contained in:
parent
b48d2b76d2
commit
864ccd9165
96
.clang-format
Normal file
96
.clang-format
Normal file
@ -0,0 +1,96 @@
|
||||
Language: Cpp
|
||||
# BasedOnStyle: LLVM
|
||||
# should be in line with IndentWidth
|
||||
AccessModifierOffset: -4
|
||||
AlignAfterOpenBracket: Align
|
||||
AlignConsecutiveAssignments: false
|
||||
AlignConsecutiveDeclarations: false
|
||||
AlignEscapedNewlinesLeft: false
|
||||
AlignOperands: true
|
||||
AlignTrailingComments: true
|
||||
AllowAllParametersOfDeclarationOnNextLine: true
|
||||
AllowShortBlocksOnASingleLine: false
|
||||
AllowShortCaseLabelsOnASingleLine: false
|
||||
AllowShortFunctionsOnASingleLine: All
|
||||
AllowShortIfStatementsOnASingleLine: false
|
||||
AllowShortLoopsOnASingleLine: false
|
||||
AlwaysBreakAfterDefinitionReturnType: None
|
||||
AlwaysBreakAfterReturnType: None
|
||||
AlwaysBreakBeforeMultilineStrings: false
|
||||
AlwaysBreakTemplateDeclarations: false
|
||||
BinPackArguments: true
|
||||
BinPackParameters: true
|
||||
BraceWrapping:
|
||||
AfterClass: false
|
||||
AfterControlStatement: false
|
||||
AfterEnum: false
|
||||
AfterFunction: false
|
||||
AfterNamespace: false
|
||||
AfterObjCDeclaration: false
|
||||
AfterStruct: false
|
||||
AfterUnion: false
|
||||
BeforeCatch: false
|
||||
BeforeElse: false
|
||||
IndentBraces: false
|
||||
BreakBeforeBinaryOperators: None
|
||||
BreakBeforeBraces: Attach
|
||||
BreakBeforeTernaryOperators: true
|
||||
BreakConstructorInitializersBeforeComma: true
|
||||
BreakAfterJavaFieldAnnotations: false
|
||||
BreakStringLiterals: true
|
||||
ColumnLimit: 140
|
||||
CommentPragmas: '^( IWYU pragma:| @suppress)'
|
||||
ConstructorInitializerAllOnOneLineOrOnePerLine: false
|
||||
ConstructorInitializerIndentWidth: 0
|
||||
ContinuationIndentWidth: 4
|
||||
Cpp11BracedListStyle: true
|
||||
DerivePointerAlignment: false
|
||||
DisableFormat: false
|
||||
ExperimentalAutoDetectBinPacking: false
|
||||
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
|
||||
IncludeCategories:
|
||||
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
|
||||
Priority: 2
|
||||
- Regex: '^(<|"(gtest|isl|json)/)'
|
||||
Priority: 3
|
||||
- Regex: '.*'
|
||||
Priority: 1
|
||||
IncludeIsMainRegex: '$'
|
||||
IndentCaseLabels: false
|
||||
IndentWidth: 4
|
||||
IndentWrappedFunctionNames: false
|
||||
JavaScriptQuotes: Leave
|
||||
JavaScriptWrapImports: true
|
||||
KeepEmptyLinesAtTheStartOfBlocks: true
|
||||
MacroBlockBegin: ''
|
||||
MacroBlockEnd: ''
|
||||
MaxEmptyLinesToKeep: 1
|
||||
NamespaceIndentation: None
|
||||
ObjCBlockIndentWidth: 2
|
||||
ObjCSpaceAfterProperty: false
|
||||
ObjCSpaceBeforeProtocolList: true
|
||||
PenaltyBreakBeforeFirstCallParameter: 19
|
||||
PenaltyBreakComment: 300
|
||||
PenaltyBreakFirstLessLess: 120
|
||||
PenaltyBreakString: 1000
|
||||
PenaltyExcessCharacter: 1000000
|
||||
PenaltyReturnTypeOnItsOwnLine: 60
|
||||
PointerAlignment: Left
|
||||
ReflowComments: true
|
||||
SortIncludes: true
|
||||
SpaceAfterCStyleCast: false
|
||||
SpaceAfterTemplateKeyword: true
|
||||
SpaceBeforeAssignmentOperators: true
|
||||
SpaceBeforeParens: Never
|
||||
SpaceInEmptyParentheses: false
|
||||
SpacesBeforeTrailingComments: 1
|
||||
SpacesInAngles: false
|
||||
SpacesInContainerLiterals: true
|
||||
SpacesInCStyleCastParentheses: false
|
||||
SpacesInParentheses: false
|
||||
SpacesInSquareBrackets: false
|
||||
Standard: Cpp11
|
||||
TabWidth: 4
|
||||
UseTab: Never
|
||||
...
|
||||
|
@ -48,13 +48,14 @@
|
||||
<def name="CMAKE_BUILD_TYPE" type="STRING" val="${ConfigName}"/>
|
||||
</defs>
|
||||
</storageModule>
|
||||
<storageModule buildDir="build/${ConfigName}" dirtyTs="1697917985878" moduleId="de.marw.cmake4eclipse.mbs.settings">
|
||||
<storageModule buildDir="build/${ConfigName}" dirtyTs="1698593487517" moduleId="de.marw.cmake4eclipse.mbs.settings">
|
||||
<options/>
|
||||
<defs>
|
||||
<def name="CMAKE_BUILD_TYPE" type="STRING" val="RelWithDebInfo"/>
|
||||
<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
|
||||
<def name="WITH_TCC" type="BOOL" val="ON"/>
|
||||
<def name="FW_BUILD" type="BOOL" val="ON"/>
|
||||
<def name="ENABLE_CLANG_TIDY" type="BOOL" val="ON"/>
|
||||
</defs>
|
||||
</storageModule>
|
||||
</cconfiguration>
|
||||
@ -127,7 +128,7 @@
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactName="${ProjName}" buildProperties="" description="" id="cdt.managedbuild.toolchain.gnu.base.1336041151.1605951382" name="RelWithDebInfo" optionalBuildProperties="org.eclipse.cdt.docker.launcher.containerbuild.property.selectedvolumes=,org.eclipse.cdt.docker.launcher.containerbuild.property.volumes=" parent="org.eclipse.cdt.build.core.emptycfg">
|
||||
<configuration artifactName="${ProjName}" buildProperties="" description="" id="cdt.managedbuild.toolchain.gnu.base.1336041151.1605951382" name="RelWithDebInfo" optionalBuildProperties="org.eclipse.cdt.docker.launcher.containerbuild.property.volumes=,org.eclipse.cdt.docker.launcher.containerbuild.property.selectedvolumes=" parent="org.eclipse.cdt.build.core.emptycfg">
|
||||
<folderInfo id="cdt.managedbuild.toolchain.gnu.base.1336041151.1605951382." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.base.1009994445" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.base">
|
||||
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.GNU_ELF" id="cdt.managedbuild.target.gnu.platform.base.1023431687" name="Debug Platform" osList="linux,hpux,aix,qnx" superClass="cdt.managedbuild.target.gnu.platform.base"/>
|
||||
@ -163,13 +164,14 @@
|
||||
<def name="CMAKE_BUILD_TYPE" type="STRING" val="${ConfigName}"/>
|
||||
</defs>
|
||||
</storageModule>
|
||||
<storageModule buildDir="build/${ConfigName}" dirtyTs="1697917985878" moduleId="de.marw.cmake4eclipse.mbs.settings">
|
||||
<storageModule buildDir="build/${ConfigName}" dirtyTs="1698593290265" moduleId="de.marw.cmake4eclipse.mbs.settings">
|
||||
<options/>
|
||||
<defs>
|
||||
<def name="CMAKE_BUILD_TYPE" type="STRING" val="RelWithDebInfo"/>
|
||||
<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
|
||||
<def name="WITH_TCC" type="BOOL" val="ON"/>
|
||||
<def name="FW_BUILD" type="BOOL" val="ON"/>
|
||||
<def name="ENABLE_CLANG_TIDY" type="BOOL" val="ON"/>
|
||||
</defs>
|
||||
</storageModule>
|
||||
</cconfiguration>
|
||||
|
@ -11,6 +11,7 @@ if(CMAKE_PROJECT_NAME STREQUAL "TGC-ISS")
|
||||
set(CORE_NAME TGC5C CACHE STRING "The core to build the ISS for" )
|
||||
option(FW_BUILD "Enable the automatic download and build of some firmware to run on the ISS" OFF)
|
||||
option(ENABLE_SANITIZER "Enable address sanitizer" OFF)
|
||||
option(ENABLE_CLANG_TIDY "Add clang-tidy and clang-format automatically to builds" OFF)
|
||||
option(WITH_TCC "Build TCC backend" ON)
|
||||
option(WITH_LLVM "Build LLVM backend" OFF)
|
||||
option(WITH_ASMJIT "Build ASMJIT backend" ON)
|
||||
@ -155,6 +156,48 @@ if(CMAKE_PROJECT_NAME STREQUAL "TGC-ISS")
|
||||
if(USE_CWR_SYSTEMC)
|
||||
include(SystemCPackage)
|
||||
endif()
|
||||
###############################################################################
|
||||
# setup clang-format and clang-tidy
|
||||
###############################################################################
|
||||
if (ENABLE_CLANG_TIDY)
|
||||
set(CLANG_FORMAT_EXCLUDE_PATTERNS "scc" "install")
|
||||
find_package(ClangFormat)
|
||||
find_program (CLANG_TIDY_EXE NAMES "clang-tidy" PATHS /usr/bin )
|
||||
if (CLANG_TIDY_EXE)
|
||||
message(STATUS "clang-tidy found: ${CLANG_TIDY_EXE}")
|
||||
set(CLANG_TIDY_CHECKS "-*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-avoid-bind.PermissiveParameterList")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-loop-convert.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-make-shared.")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-make-unique.")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-pass-by-value.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-raw-string-literal.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-replace-auto-ptr.IncludeStyle")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-replace-disallow-copy-and-assign-macro.MacroName")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-replace-random-shuffle.IncludeStyle")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-auto.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-bool-literals.IgnoreMacros")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-default-member-init.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-emplace.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-equals-default.IgnoreMacros")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-equals-delete.IgnoreMacros")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-nodiscard.ReplacementString")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-noexcept.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-nullptr.NullMacros")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-override.*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-transparent-functors.SafeMode")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},modernize-use-using.IgnoreMacros")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},cppcoreguidelines-explicit-virtual-functions.IgnoreDestructors")
|
||||
#set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},cppcoreguidelines-*")
|
||||
set(CLANG_TIDY_CHECKS "${CLANG_TIDY_CHECKS},clang-diagnostic-*,clang-analyzer-*")
|
||||
set(DO_CLANG_TIDY "${CLANG_TIDY_EXE};-checks=${CLANG_TIDY_CHECKS};-header-filter='${CMAKE_SOURCE_DIR}/*';-fix"
|
||||
CACHE STRING "" FORCE)
|
||||
else()
|
||||
message(WARNING "clang-tidy not found!")
|
||||
set(CMAKE_CXX_CLANG_TIDY "" CACHE STRING "" FORCE) # delete it
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(FW_BUILD)
|
||||
include(FetchContent)
|
||||
set(FETCHCONTENT_BASE_DIR ${CMAKE_CURRENT_BINARY_DIR}/..)
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit 99eea614f5cc4e6cc74f671aab2bfa54b941d185
|
||||
Subproject commit 95e3ccb2241ef3c7aed7c15452fd1309d225ec58
|
@ -1 +1 @@
|
||||
Subproject commit 2115e9ceaea9540b8998080213b1a79725f5c878
|
||||
Subproject commit 6419ad471e3048463084c6a0fbfcf3bedef7bf9d
|
2
scc
2
scc
@ -1 +1 @@
|
||||
Subproject commit 609bbbb41a2ae9a5c179e7ae0c4d8fccf7eaac29
|
||||
Subproject commit b8d4cf0c034147b68038e682dbbd6a59a108434f
|
Loading…
Reference in New Issue
Block a user