Skip to content

Commit 5118048

Browse files
committed
Do not expose the whole 3rdparty folder as a include_directory
1 parent 4d88af4 commit 5118048

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

3rdparty/cppzmq/CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,13 @@
1+
find_package(ZeroMQ REQUIRED)
2+
13
add_library(cppzmq INTERFACE)
4+
if(TARGET libzmq-static)
5+
target_link_libraries(cppzmq INTERFACE libzmq-static)
6+
elseif(TARGET libzmq)
7+
target_link_libraries(cppzmq INTERFACE libzmq)
8+
else()
9+
message(FATAL_ERROR "Failed to find libzmq")
10+
endif()
211

312
# This library doesn't use modern targets unfortunately.
413
#add_library(cppzmq::cppzmq ALIAS cppzmq)

tools/CMakeLists.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11

2-
include_directories(${PROJECT_SOURCE_DIR}/3rdparty)
3-
42
# add_executable(bt4_log_cat bt_log_cat.cpp )
53
# target_link_libraries(bt4_log_cat ${BTCPP_LIBRARY} )
64
# install(TARGETS bt4_log_cat

tools/bt_recorder.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#include <fstream>
44
#include <signal.h>
55
#include <fstream>
6-
#include "cppzmq/zmq.hpp"
6+
#include "zmq.hpp"
77
#include "behaviortree_cpp/flatbuffers/BT_logger_generated.h"
88

99
// http://zguide.zeromq.org/cpp:interrupt

0 commit comments

Comments
 (0)