Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change So That Tinyxml2 Is Integrated Using Git Submodule #67

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[submodule "external/tinyxml2"]
path = external/tinyxml2
url = https://github.com/leethomason/tinyxml2.git
branch = v10.0.0
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -70,6 +70,8 @@ install(
CODE "file( INSTALL \${HEADERS} DESTINATION \"${INSTALL_INCLUDE_DIR}\" )"
)

add_subdirectory(external/tinyxml2)

# ----------- EXAMPLES -----------

# example: RigidBodyStreaming
@@ -79,6 +81,7 @@ if (${PROJECT_NAME}_BUILD_EXAMPLES)
)
target_link_libraries(RigidBodyStreaming
qualisys_cpp_sdk
tinyxml2
)
endif ()

37 changes: 23 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,36 +1,45 @@
# Qualisys Realtime SDK

C++ package with SDK and examples
C++ package with SDK and examples.

## Build with Visual Studio

Build RTClientSDK solution in Visual Studio 2017.

## Build with CMake (Windows & Linux)

* _Tested with GCC 7._
* _Tested with VS 2017._
* Tested with GCC 7.
* Tested with VS 2017.

### Cloning the Repository

This project uses Git submodules. Ensure submodules are initialized after cloning:

`git clone --recursive <repository-url>`

If already cloned, initialize and update submodules:

`git submodule update --init --recursive`

### Build Examples
```
cmake -S . -B build -Dqualisys_cpp_sdk_BUILD_EXAMPLES=ON
cmake --build build
cmake -S . -B build -Dqualisys_cpp_sdk_BUILD_EXAMPLES=ON
cmake --build build
```

### Build & Run Tests
### Build & Run Tests
```cmake
cmake -S . -B build -Dqualisys_cpp_sdk_BUILD_TESTS=ON
cmake --build build
ctest --test-dir build
cmake -S . -B build -Dqualisys_cpp_sdk_BUILD_TESTS=ON
cmake --build build
ctest --test-dir build
```

## Usage

Include the Qualisys SDK in your cmake application with:
Include the Qualisys SDK in your CMake application:

```cmake
find_package(qualisys_cpp_sdk REQUIRED)
find_package(qualisys_cpp_sdk REQUIRED)

target_link_libraries(myapplication
qualisys_cpp_sdk)
```
target_link_libraries(myapplication PRIVATE qualisys_cpp_sdk)
```
3 changes: 1 addition & 2 deletions Tests/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -2,7 +2,6 @@ cmake_minimum_required(VERSION 3.27.1)

project(qualisys_cpp_sdk_tests LANGUAGES CXX)

include(tinyxml2)
include(doctest)

set(SOURCE_LIST
@@ -33,7 +32,7 @@ target_link_libraries(${PROJECT_NAME}
PRIVATE
qualisys_cpp_sdk
doctest::doctest
tinyxml2::tinyxml2
tinyxml2
)

target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_17)
15 changes: 0 additions & 15 deletions cmake/tinyxml2.cmake

This file was deleted.

1 change: 1 addition & 0 deletions external/tinyxml2
Submodule tinyxml2 added at 57ec94