Skip to content

Commit 7a042e3

Browse files
authored
1 parent 0e73e2e commit 7a042e3

File tree

65 files changed

+719
-396
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+719
-396
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 0 additions & 31 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/feature_request.md

Lines changed: 0 additions & 23 deletions
This file was deleted.
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: "[BUG]"
5+
labels: bug
6+
assignees: pzhu-flexiv
7+
8+
---
9+
10+
## Version info
11+
12+
- RDK: [e.g. v1.5]
13+
- Robot software: [e.g. v3.7]
14+
- OS: [e.g. Ubuntu 20.04, x86_64]
15+
16+
## How urgent is this bug? Have you found any workarounds?
17+
18+
On a scale of 1 to 10.
19+
20+
## Describe the issue and expected behavior
21+
22+
The issue is ...
23+
The correct behavior you expect is ...
24+
25+
## Steps to reproduce
26+
27+
1. '....'
28+
2. '....'
29+
3. '....'
30+
4. See error
31+
32+
## Screenshots
33+
34+
If applicable, add screenshots to help explain your issue.
35+
36+
## Additional context
37+
38+
Add any other context about the issue.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
name: Feature request
3+
about: Suggest a new feature
4+
title: "[FEATURE]"
5+
labels: enhancement
6+
assignees: pzhu-flexiv
7+
8+
---
9+
10+
## How urgent is this feature?
11+
12+
On a scale of 1 to 10.
13+
14+
## Is this feature request related to a problem?
15+
16+
This new feature is needed so that ... can be solved.
17+
18+
## Describe the solution you'd like
19+
20+
What you want to happen.
21+
22+
## Describe alternatives you've considered
23+
24+
Any alternative solutions or workarounds you've considered.
25+
26+
## Additional context
27+
28+
Add any other context or screenshots about this feature.

.github/workflows/shared_steps/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ runs:
2727
pwd
2828
cd example
2929
mkdir -p build && cd build
30-
cmake .. -DCMAKE_INSTALL_PREFIX=~/rdk_install
30+
cmake .. -DCMAKE_PREFIX_PATH=~/rdk_install
3131
cmake --build . --config Release -j 4
3232
3333
# Find and link to flexiv_rdk library, then build all test programs.
@@ -37,5 +37,5 @@ runs:
3737
pwd
3838
cd test
3939
mkdir -p build && cd build
40-
cmake .. -DCMAKE_INSTALL_PREFIX=~/rdk_install
40+
cmake .. -DCMAKE_PREFIX_PATH=~/rdk_install
4141
cmake --build . --config Release -j 4

CMakeLists.txt

Lines changed: 10 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -3,48 +3,34 @@ cmake_minimum_required(VERSION 3.16.3)
33
# ===================================================================
44
# PROJECT SETUP
55
# ===================================================================
6-
project(flexiv_rdk VERSION 1.5.1)
6+
project(flexiv_rdk VERSION 1.6.0)
77

88
# Configure build type
99
if(NOT CMAKE_BUILD_TYPE)
1010
set(CMAKE_BUILD_TYPE Release CACHE STRING "CMake build type" FORCE)
1111
endif()
1212
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Release" "Debug" "RelWithDebInfo")
1313

14-
# Configure Python RDK
15-
option(INSTALL_PYTHON_RDK "Install Python RDK (to user site packages path)" OFF)
16-
if(INSTALL_PYTHON_RDK)
17-
if(NOT RDK_PYTHON_VERSION)
18-
set(RDK_PYTHON_VERSION 3.10 CACHE STRING "Python version to install RDK for" FORCE)
19-
endif()
20-
set_property(CACHE RDK_PYTHON_VERSION PROPERTY STRINGS "3.10" "3.12")
21-
find_package(Python3 ${RDK_PYTHON_VERSION} EXACT COMPONENTS Interpreter REQUIRED)
22-
endif()
23-
24-
# Set C++ and Python library filename
25-
message("OS: ${CMAKE_SYSTEM_NAME}")
26-
message("Processor: ${CMAKE_SYSTEM_PROCESSOR}")
14+
# Set static library according to platform
15+
message(STATUS "OS: ${CMAKE_SYSTEM_NAME}")
16+
message(STATUS "Processor: ${CMAKE_SYSTEM_PROCESSOR}")
2717
if(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
2818
if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "x86_64")
29-
set(RDK_CPP_LIB "libflexiv_rdk.x86_64-linux-gnu.a")
30-
set(RDK_PY_LIB "flexivrdk.cpython-${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR}-x86_64-linux-gnu.so")
19+
set(RDK_STATIC_LIB "libflexiv_rdk.x86_64-linux-gnu.a")
3120
elseif(${CMAKE_SYSTEM_PROCESSOR} MATCHES "aarch64")
32-
set(RDK_CPP_LIB "libflexiv_rdk.aarch64-linux-gnu.a")
33-
set(RDK_PY_LIB "flexivrdk.cpython-${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR}-aarch64-linux-gnu.so")
21+
set(RDK_STATIC_LIB "libflexiv_rdk.aarch64-linux-gnu.a")
3422
else()
3523
message(FATAL_ERROR "Linux with ${CMAKE_SYSTEM_PROCESSOR} processor is currently not supported.")
3624
endif()
3725
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
3826
if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm64")
39-
set(RDK_CPP_LIB "libflexiv_rdk.arm64-darwin.a")
40-
set(RDK_PY_LIB "flexivrdk.cpython-${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR}-darwin.so")
27+
set(RDK_STATIC_LIB "libflexiv_rdk.arm64-darwin.a")
4128
else()
4229
message(FATAL_ERROR "Mac with ${CMAKE_SYSTEM_PROCESSOR} processor is currently not supported.")
4330
endif()
4431
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Windows")
4532
if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "AMD64")
46-
set(RDK_CPP_LIB "flexiv_rdk.win_amd64.lib")
47-
set(RDK_PY_LIB "flexivrdk.cp${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR}-win_amd64.pyd")
33+
set(RDK_STATIC_LIB "flexiv_rdk.win_amd64.lib")
4834
else()
4935
message(FATAL_ERROR "Windows with ${CMAKE_SYSTEM_PROCESSOR} processor is currently not supported.")
5036
endif()
@@ -79,7 +65,7 @@ if(fastrtps_FOUND)
7965
endif()
8066

8167
# ===================================================================
82-
# INSTALL C++ LIBRARY
68+
# CREATE LIBRARY
8369
# ===================================================================
8470
# Create an INTERFACE library with no source file to compile
8571
add_library(${PROJECT_NAME} INTERFACE)
@@ -94,7 +80,7 @@ target_include_directories(${PROJECT_NAME} INTERFACE
9480
)
9581

9682
target_link_libraries(${PROJECT_NAME} INTERFACE
97-
${CMAKE_CURRENT_SOURCE_DIR}/lib/${RDK_CPP_LIB}
83+
${CMAKE_CURRENT_SOURCE_DIR}/lib/${RDK_STATIC_LIB}
9884
Threads::Threads
9985
Eigen3::Eigen
10086
spdlog::spdlog
@@ -109,24 +95,5 @@ else()
10995
endif()
11096

11197
# Install the INTERFACE library
112-
message(STATUS "C++ RDK library: ${RDK_CPP_LIB}")
11398
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/FlexivInstallLibrary.cmake)
11499
FlexivInstallLibrary()
115-
116-
# ===================================================================
117-
# INSTALL PYTHON LIBRARY
118-
# ===================================================================
119-
if(INSTALL_PYTHON_RDK)
120-
# Get user site packages path
121-
message(STATUS "Python executable: ${Python3_EXECUTABLE}")
122-
execute_process(
123-
COMMAND ${Python3_EXECUTABLE} -c "import site; print(site.getusersitepackages())"
124-
OUTPUT_VARIABLE USER_SITE
125-
OUTPUT_STRIP_TRAILING_WHITESPACE
126-
)
127-
message(STATUS "Python site packages path: ${USER_SITE}")
128-
129-
# Install Python RDK to user site packages path
130-
message(STATUS "Python RDK library: ${RDK_PY_LIB}")
131-
install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/lib_py/${RDK_PY_LIB}" DESTINATION ${USER_SITE})
132-
endif()

0 commit comments

Comments
 (0)