Skip to content

Commit

Permalink
add rostime patch
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfv committed Apr 2, 2021
1 parent 6bc0a0a commit cf961a5
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 0 deletions.
13 changes: 13 additions & 0 deletions patch/ros-noetic-rostime.linux.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 32a76bb9..68bd38f4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -5,7 +5,7 @@ find_package(catkin REQUIRED COMPONENTS cpp_common)
find_package(Boost REQUIRED COMPONENTS date_time system thread)
catkin_package(
INCLUDE_DIRS include
- LIBRARIES ${PROJECT_NAME}
+ LIBRARIES ${PROJECT_NAME} ${RT_LIBRARY}
CATKIN_DEPENDS cpp_common
DEPENDS Boost
)
35 changes: 35 additions & 0 deletions patch/ros-noetic-urg-c.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3563831..7d139fd 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -32,19 +32,19 @@ include_directories(${LIBRARY_INCLUDE_DIR} ${catkin_INCLUDE_DIRS})

## Declare libraries
add_library(liburg_c ${LIBRARY_SRC_DIR}/urg_sensor.c
- ${LIBRARY_SRC_DIR}/urg_utils.c
- ${LIBRARY_SRC_DIR}/urg_debug.c
- ${LIBRARY_SRC_DIR}/urg_connection.c
- ${LIBRARY_SRC_DIR}/urg_ring_buffer.c
- ${LIBRARY_SRC_DIR}/urg_serial.c
- ${LIBRARY_SRC_DIR}/urg_serial_utils.c
- ${LIBRARY_SRC_DIR}/urg_tcpclient.c
- ${LIBRARY_SRC_DIR}/urg_time.c
-
+ ${LIBRARY_SRC_DIR}/urg_utils.c
+ ${LIBRARY_SRC_DIR}/urg_debug.c
+ ${LIBRARY_SRC_DIR}/urg_connection.c
+ ${LIBRARY_SRC_DIR}/urg_ring_buffer.c
+ ${LIBRARY_SRC_DIR}/urg_serial.c
+ ${LIBRARY_SRC_DIR}/urg_serial_utils.c
+ ${LIBRARY_SRC_DIR}/urg_tcpclient.c
+ ${LIBRARY_SRC_DIR}/urg_time.c
)
-if(NOT ANDROID)
+
+if(NOT ANDROID AND NOT APPLE)
target_link_libraries(liburg_c -lrt -lm)
-endif(NOT ANDROID)
+endif(NOT ANDROID AND NOT APPLE)

add_library(open_urg_sensor ${LIBRARY_SAMPLE_DIR}/open_urg_sensor.c)
target_link_libraries(open_urg_sensor -lm liburg_c ${catkin_LIBRARIES})

0 comments on commit cf961a5

Please sign in to comment.