Project setups
This commit is contained in:
@@ -8,3 +8,6 @@ log_subdir/
|
|||||||
coverage/
|
coverage/
|
||||||
install/
|
install/
|
||||||
libucore-*
|
libucore-*
|
||||||
|
src/version.c
|
||||||
|
.cache/
|
||||||
|
compile_commands.json
|
||||||
|
|||||||
Vendored
+15
@@ -0,0 +1,15 @@
|
|||||||
|
{
|
||||||
|
"configurations": [
|
||||||
|
{
|
||||||
|
"name": "Mac",
|
||||||
|
"includePath": [
|
||||||
|
"${default}",
|
||||||
|
"${workspaceFolder}/include"
|
||||||
|
],
|
||||||
|
"defines": [],
|
||||||
|
"compilerPath": "/usr/bin/clang",
|
||||||
|
"intelliSenseMode": "macos-clang-arm64"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"version": 4
|
||||||
|
}
|
||||||
Vendored
+14
@@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
"files.associations": {
|
||||||
|
"ringbuf.h": "c",
|
||||||
|
"seq.h": "c",
|
||||||
|
"stdint.h": "c",
|
||||||
|
"stdio.h": "c"
|
||||||
|
},
|
||||||
|
"C_Cpp.default.includePath": [
|
||||||
|
"/opt/homebrew/include/",
|
||||||
|
"$(workspaceFolder)/include/",
|
||||||
|
|
||||||
|
|
||||||
|
]
|
||||||
|
}
|
||||||
Vendored
+19
@@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
"version": "2.0.0",
|
||||||
|
"tasks": [
|
||||||
|
{
|
||||||
|
"type": "cmake",
|
||||||
|
"label": "CMake: build",
|
||||||
|
"command": "build",
|
||||||
|
"targets": [
|
||||||
|
"all"
|
||||||
|
],
|
||||||
|
"group": {
|
||||||
|
"kind": "build",
|
||||||
|
"isDefault": true
|
||||||
|
},
|
||||||
|
"problemMatcher": [],
|
||||||
|
"detail": "CMake template build task"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
+2
-2
@@ -12,9 +12,9 @@ set(libucore_VERSION ${libucore_VERSION_MAJOR}.${libucore_VERSION_MINOR}.${libuc
|
|||||||
set(CMAKE_VERBOSE_MAKEFILE ON)
|
set(CMAKE_VERBOSE_MAKEFILE ON)
|
||||||
|
|
||||||
set(CMAKE_C_STANDARD 99)
|
set(CMAKE_C_STANDARD 99)
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wundef -Wcast-qual -Wshadow -Wcast-align -pipe -Wno-unused-parameter -Werror=implicit-function-declaration -Winit-self -pthread")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wundef -Wcast-qual -Wshadow -Wcast-align -pipe -Wno-unused-parameter -Werror=implicit-function-declaration -Winit-self")
|
||||||
add_definitions(-D_FILE_OFFSET_BITS=64)
|
add_definitions(-D_FILE_OFFSET_BITS=64)
|
||||||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -O2 -pthread")
|
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -O2")
|
||||||
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
||||||
find_package(Threads REQUIRED)
|
find_package(Threads REQUIRED)
|
||||||
option(CODE_COVERAGE "build with code coverage intrumentation" OFF)
|
option(CODE_COVERAGE "build with code coverage intrumentation" OFF)
|
||||||
|
|||||||
+1
-1
@@ -10,5 +10,5 @@ ${SOURCE_FILES}
|
|||||||
"${PROJECT_BINARY_DIR}/src/version.c"
|
"${PROJECT_BINARY_DIR}/src/version.c"
|
||||||
)
|
)
|
||||||
set_target_properties(ucore PROPERTIES SOVERSION 1 VERSION 1.0.0)
|
set_target_properties(ucore PROPERTIES SOVERSION 1 VERSION 1.0.0)
|
||||||
target_link_libraries(ucore pthread)
|
target_link_libraries(ucore Threads::Threads)
|
||||||
install (TARGETS ucore DESTINATION lib)
|
install (TARGETS ucore DESTINATION lib)
|
||||||
|
|||||||
BIN
Binary file not shown.
Reference in New Issue
Block a user