-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build(all): extern liburingcxx; use configure, no
-D
- Loading branch information
1 parent
9278e4f
commit 21e3d25
Showing
75 changed files
with
1,557 additions
and
284 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -74,7 +74,7 @@ draft/ | |
*.rdb | ||
*.svg | ||
/perf/ | ||
perf.data* | ||
/perf.* | ||
*.data | ||
*.perf | ||
*.folded | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
configure_file( | ||
${PROJECT_SOURCE_DIR}/include/co_context/config/config.hpp.in | ||
${PROJECT_SOURCE_DIR}/include/co_context/config/config.hpp | ||
@ONLY | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
--- | ||
BasedOnStyle: LLVM | ||
IndentWidth: 4 | ||
TabWidth: 4 | ||
Language: Cpp | ||
AlignAfterOpenBracket: BlockIndent # BlockIndent | ||
AlignArrayOfStructures: Right | ||
AlignConsecutiveBitFields: "Consecutive" | ||
AlignConsecutiveMacros: "Consecutive" | ||
AlignEscapedNewlines: Left | ||
AlignOperands: "Align" | ||
AlignTrailingComments: true | ||
AllowAllArgumentsOnNextLine: true | ||
AllowAllConstructorInitializersOnNextLine: true | ||
AllowAllParametersOfDeclarationOnNextLine: true | ||
AlignConsecutiveShortCaseStatements: # clang-format 17 | ||
Enabled: true | ||
AcrossEmptyLines: true | ||
AcrossComments: true | ||
AlignCaseColons: false | ||
AllowShortBlocksOnASingleLine: Empty | ||
AllowShortCaseLabelsOnASingleLine: true | ||
AllowShortEnumsOnASingleLine: true | ||
AllowShortFunctionsOnASingleLine: InlineOnly | ||
AllowShortIfStatementsOnASingleLine: WithoutElse | ||
AllowShortLambdasOnASingleLine: Inline | ||
AllowShortLoopsOnASingleLine: false | ||
AlwaysBreakBeforeMultilineStrings: false | ||
AlwaysBreakTemplateDeclarations: Yes | ||
BinPackArguments: true | ||
BinPackParameters: false | ||
BreakAfterAttributes: Leave # clang-format 16 | ||
BreakBeforeBinaryOperators: NonAssignment | ||
BreakBeforeBraces: Attach | ||
BreakBeforeConceptDeclarations: true | ||
BreakBeforeTernaryOperators: true | ||
BreakConstructorInitializers: BeforeComma | ||
BreakInheritanceList: BeforeComma | ||
BreakStringLiterals: false | ||
ColumnLimit: 80 | ||
CompactNamespaces: false | ||
ConstructorInitializerAllOnOneLineOrOnePerLine: true | ||
ConstructorInitializerIndentWidth: 4 | ||
ContinuationIndentWidth: 4 | ||
Cpp11BracedListStyle: true | ||
EmptyLineBeforeAccessModifier: Always | ||
FixNamespaceComments: true | ||
IndentCaseLabels: true | ||
IndentExternBlock: Indent | ||
IndentGotoLabels: true | ||
IndentPPDirectives: None | ||
IndentRequires: true # clang-format 14 | ||
IndentWrappedFunctionNames: false | ||
InsertBraces: true # clang-format 15 | ||
InsertNewlineAtEOF: true # clang-format 16 | ||
IntegerLiteralSeparator: # clang-format 16 | ||
Binary: 8 | ||
Decimal: 0 | ||
Hex: 2 | ||
HexMinDigits: 8 | ||
LambdaBodyIndentation: Signature | ||
LineEnding: LF # clang-format 16 | ||
KeepEmptyLinesAtEOF: false # clang-format 17 | ||
KeepEmptyLinesAtTheStartOfBlocks: false | ||
MaxEmptyLinesToKeep: 1 | ||
NamespaceIndentation: Inner | ||
PackConstructorInitializers: CurrentLine # clang-format 14 | ||
PointerAlignment: Right | ||
QualifierAlignment: Left | ||
ReflowComments: true | ||
RequiresClausePosition: OwnLine # clang-format 15 | ||
RequiresExpressionIndentation: OuterScope # clang-format 16 | ||
SeparateDefinitionBlocks: Always | ||
ShortNamespaceLines: 5 | ||
SortIncludes: "CaseSensitive" | ||
SortUsingDeclarations: false | ||
SpaceAfterCStyleCast: false | ||
SpaceAfterLogicalNot: false | ||
SpaceAfterTemplateKeyword: false | ||
SpaceBeforeAssignmentOperators: true | ||
SpaceBeforeCpp11BracedList: false | ||
SpaceBeforeCtorInitializerColon: true | ||
SpaceBeforeInheritanceColon: true | ||
SpaceBeforeParens: ControlStatements | ||
SpaceBeforeRangeBasedForLoopColon: true | ||
SpaceBeforeSquareBrackets: false | ||
SpaceInEmptyBlock: false | ||
SpaceInEmptyParentheses: false | ||
SpacesBeforeTrailingComments: 1 | ||
SpacesInAngles: "Never" | ||
SpacesInCStyleCastParentheses: false | ||
SpacesInConditionalStatement: false | ||
SpacesInContainerLiterals: true | ||
SpacesInParentheses: false | ||
SpacesInSquareBrackets: false | ||
Standard: Latest | ||
UseCRLF: false | ||
UseTab: Never | ||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
# Prerequisites | ||
*.d | ||
|
||
# Compiled Object files | ||
*.slo | ||
*.lo | ||
*.o | ||
*.obj | ||
|
||
# Precompiled Headers | ||
*.gch | ||
*.pch | ||
|
||
# Compiled Dynamic libraries | ||
*.so | ||
*.dylib | ||
*.dll | ||
|
||
# Fortran module files | ||
*.mod | ||
*.smod | ||
|
||
# Compiled Static libraries | ||
*.lai | ||
*.la | ||
*.a | ||
*.lib | ||
|
||
# Executables | ||
*.exe | ||
*.out | ||
*.app | ||
|
||
# CMake | ||
build/ | ||
CMakeLists.txt.user | ||
CMakeCache.txt | ||
CMakeFiles | ||
CMakeScripts | ||
Testing | ||
Makefile | ||
cmake_install.cmake | ||
install_manifest.txt | ||
compile_commands.json | ||
CTestTestfile.cmake | ||
_deps | ||
|
||
# Visual Studio Code | ||
.vscode/ | ||
|
||
# Local History for Visual Studio Code | ||
.history/ | ||
|
||
# clangd | ||
.cache/ | ||
|
||
# Built Visual Studio Code Extensions | ||
*.vsix | ||
|
||
draft/ | ||
|
||
perf.data* | ||
*.data | ||
|
||
# log for perf | ||
log | ||
tmp | ||
*.rdb | ||
*.svg | ||
|
||
# public/index.html for httpd | ||
public/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
cmake_minimum_required(VERSION 3.10.0) | ||
|
||
set(CMAKE_CXX_STANDARD 20) | ||
set(CMAKE_CXX_STANDARD_REQUIRED ON) | ||
|
||
project(liburingcxx VERSION 0.9.0 LANGUAGES CXX) | ||
|
||
if (NOT "${CMAKE_SYSTEM_NAME}" STREQUAL "Linux") | ||
message(WARNING "io_uring is only supported by Linux, but the target OS is ${CMAKE_SYSTEM_NAME}.") | ||
endif() | ||
|
||
add_library(liburingcxx INTERFACE) | ||
add_library(liburingcxx::liburingcxx ALIAS liburingcxx) | ||
|
||
target_include_directories( | ||
liburingcxx | ||
INTERFACE | ||
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>" | ||
"$<INSTALL_INTERFACE:include>" | ||
) | ||
|
||
include(./cmake/option.cmake) | ||
include(./cmake/configure.cmake) | ||
include(./cmake/install.cmake) | ||
|
||
if (LIBURINGCXX_BUILD_EXAMPLE OR LIBURINGCXX_BUILD_TEST) | ||
if (NOT CMAKE_BUILD_TYPE) | ||
set(CMAKE_BUILD_TYPE Release) | ||
message("liburingcxx: Setting default CMAKE_BUILD_TYPE to Release.") | ||
endif() | ||
|
||
if(LIBURINGCXX_BUILD_TEST) | ||
add_subdirectory(./test) | ||
endif() | ||
|
||
if(LIBURINGCXX_BUILD_EXAMPLE) | ||
add_subdirectory(./example) | ||
endif() | ||
endif() |
Oops, something went wrong.