Skip to content

Commit

Permalink
modify CMakeLists.txt for simplify the dependencies [VIP]
Browse files Browse the repository at this point in the history
  • Loading branch information
zhanghm1995 committed Jun 22, 2018
1 parent aa7f246 commit e1efd2e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 16 deletions.
19 changes: 8 additions & 11 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,13 @@ set(PACKAGE_DEPENDENCIES
###### find packages #########
##############################
find_package(catkin REQUIRED COMPONENTS ${PACKAGE_DEPENDENCIES} message_generation)
find_package(ivcommon REQUIRED)
find_package(sensor_driver REQUIRED)
set(BUILD_SHARED_LIBS OFF)
include("${IVCOMMON_CMAKE_DIR}/functions.cmake")
google_initialize_ivcommon_project()




include(FindPkgConfig) #zhanghm: what mean?
find_package(LuaGoogle REQUIRED)

find_package(PCL REQUIRED)
#set(OpenCV_DIR /usr/local/share/OpenCV)
find_package(OpenCV REQUIRED)
Expand All @@ -54,7 +52,7 @@ catkin_package(
)

#include headers
include_directories(SYSTEM ${catkin_INCLUDE_DIRS} ${sensor_driver_INCLUDE_DIRS} ${ivcommon_INCLUDE_DIRS} ${LUA_INCLUDE_DIR} ${PCL_INCLUDE_DIRS} ${Boost_INCLUDE_DIRS} ${EIGEN3_INCLUDE_DIR} src include)
include_directories(SYSTEM ${catkin_INCLUDE_DIRS} ${PCL_INCLUDE_DIRS} ${Boost_INCLUDE_DIRS} ${EIGEN3_INCLUDE_DIR} src include)
include_directories(${OpenCV_INCLUDE_DIRS} ${catkin_INCLUDE_DIRS})

set(SRC_LIST src/TypeDef.h src/object_detection_radar.h src/frontal_delphi_radar.cpp src/main.cpp src/object_detection_radar.cpp)
Expand All @@ -63,13 +61,12 @@ set(SRC_LIST src/TypeDef.h src/object_detection_radar.h src/frontal_delphi_radar
##############################

add_executable(frontal_delphi_radar ${SRC_LIST})
target_link_libraries(frontal_delphi_radar PUBLIC ${catkin_LIBRARIES} ${ivcommon_LIBRARIES}
target_link_libraries(frontal_delphi_radar PUBLIC ${catkin_LIBRARIES}
${PCL_LIBRARIES}
${Boost_LIBRARIES}
${OpenCV_LIBS}
${sensor_driver_LIBRARIES})
${OpenCV_LIBS})
add_executable(get_radar_data src/get_radar_data.cpp src/frontal_delphi_radar.cpp)
target_link_libraries(get_radar_data ${catkin_LIBRARIES} ${ivcommon_LIBRARIES} ${Boost_LIBRARIES} ${sensor_driver_LIBRARIES})
target_link_libraries(get_radar_data ${catkin_LIBRARIES} ${Boost_LIBRARIES})

add_executable(get_ECU src/getECU.cpp src/AnalysisECU.cpp)
target_link_libraries(get_ECU ${catkin_LIBRARIES} ${Boost_LIBRARIES})
Expand All @@ -92,4 +89,4 @@ install(
RUNTIME DESTINATION ${CATKIN_GLOBAL_BIN_DESTINATION}
)

set(CUDA_USE_STATIC_CUDA_RUNTIME OFF)
set(CUDA_USE_STATIC_CUDA_RUNTIME OFF)
3 changes: 0 additions & 3 deletions package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,10 @@
<build_depend>message_generation</build_depend>
<exec_depend>message_runtime</exec_depend>

<depend>ivcommon</depend>
<depend>sensor_driver_msgs</depend>
<depend>sensor_driver</depend>
<depend>eigen_conversions</depend>
<depend>geometry_msgs</depend>
<depend>libgflags-dev</depend>
<depend>libgoogle-glog-dev</depend>
<depend>nav_msgs</depend>
<depend>robot_state_publisher</depend>
<depend>rosbag</depend>
Expand Down
4 changes: 2 additions & 2 deletions src/object_detection_radar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,8 @@ void ObjectDetection::show_result(vector<moving_object_millimeter>& valid_obj)//

//附带显示其他属性信息
//目标序号,v, moving
sprintf(text,"%d %.3f %d %.3f",
(*it).target_ID,(*it).v,(*it).moving,speed_abs);
sprintf(text,"%d %.3f",
(*it).target_ID,(*it).v);
cvPutText(m_Delphi_img,text,cvPoint(delphi_pos.x+2,delphi_pos.y),&cf,cvScalar(0,255,255));

/*************绘制另一幅对比图********************/
Expand Down

0 comments on commit e1efd2e

Please sign in to comment.