-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8a23891
commit a146d10
Showing
7 changed files
with
79 additions
and
78 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +0,0 @@ | ||
cc_binary( | ||
name = "kafka-topics", | ||
|
||
srcs = ["KafkaTopics.cc"], | ||
|
||
linkopts = ["-lboost_program_options", "-lrdkafka"], | ||
|
||
deps = ["//:modern-cpp-kafka-api"], | ||
) | ||
|
||
cc_binary( | ||
name = "kafka-console-consumer", | ||
|
||
srcs = ["KafkaConsoleConsumer.cc"], | ||
|
||
linkopts = ["-lboost_program_options", "-lrdkafka"], | ||
|
||
deps = ["//:modern-cpp-kafka-api"], | ||
) | ||
|
||
cc_binary( | ||
name = "kafka-console-producer", | ||
|
||
srcs = ["KafkaConsoleProducer.cc"], | ||
|
||
linkopts = ["-lboost_program_options", "-lrdkafka"], | ||
|
||
deps = ["//:modern-cpp-kafka-api"], | ||
) | ||
|
||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1 @@ | ||
project("kafka-tools") | ||
|
||
|
||
#--------------------------- | ||
# boost | ||
#--------------------------- | ||
if (DEFINED ENV{BOOST_ROOT}) | ||
set(Boost_INCLUDE_DIRS $ENV{BOOST_ROOT}/include) | ||
set(Boost_LIBRARY_DIRS $ENV{BOOST_ROOT}/lib) | ||
else () | ||
find_package(Boost COMPONENTS program_options REQUIRED) | ||
if (NOT Boost_FOUND) | ||
message(FATAL_ERROR "Boost not found!") | ||
endif () | ||
endif () | ||
|
||
message(STATUS "boost include directory: ${Boost_INCLUDE_DIRS}") | ||
message(STATUS "boost library directory: ${Boost_LIBRARY_DIRS}") | ||
|
||
include_directories(SYSTEM ${Boost_INCLUDE_DIRS}) | ||
link_directories(${Boost_LIBRARY_DIRS}) | ||
|
||
|
||
# Target: kafka-topics | ||
set(KafkaTopics kafka-topics) | ||
|
||
add_executable("${KafkaTopics}" "KafkaTopics.cc") | ||
target_link_libraries("${KafkaTopics}" modern-cpp-kafka-api boost_program_options) | ||
|
||
install(TARGETS "${KafkaTopics}" DESTINATION tools) | ||
|
||
|
||
# Target: kafka-console-consumer | ||
set(KafkaConsoleConsumer kafka-console-consumer) | ||
|
||
add_executable("${KafkaConsoleConsumer}" "KafkaConsoleConsumer.cc") | ||
target_link_libraries("${KafkaConsoleConsumer}" modern-cpp-kafka-api boost_program_options) | ||
|
||
install(TARGETS "${KafkaConsoleConsumer}" DESTINATION tools) | ||
|
||
|
||
# Target: kafka-console-producer | ||
set(KafkaConsoleProducer kafka-console-producer) | ||
|
||
add_executable("${KafkaConsoleProducer}" "KafkaConsoleProducer.cc") | ||
target_link_libraries("${KafkaConsoleProducer}" modern-cpp-kafka-api boost_program_options) | ||
|
||
install(TARGETS "${KafkaConsoleProducer}" DESTINATION tools) | ||
add_subdirectory(console_clients) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
cc_binary( | ||
name = "kafka-topics", | ||
|
||
srcs = ["KafkaTopics.cc"], | ||
|
||
linkopts = ["-lboost_program_options", "-lrdkafka"], | ||
|
||
deps = ["//:modern-cpp-kafka-api"], | ||
) | ||
|
||
cc_binary( | ||
name = "kafka-console-consumer", | ||
|
||
srcs = ["KafkaConsoleConsumer.cc"], | ||
|
||
linkopts = ["-lboost_program_options", "-lrdkafka"], | ||
|
||
deps = ["//:modern-cpp-kafka-api"], | ||
) | ||
|
||
cc_binary( | ||
name = "kafka-console-producer", | ||
|
||
srcs = ["KafkaConsoleProducer.cc"], | ||
|
||
linkopts = ["-lboost_program_options", "-lrdkafka"], | ||
|
||
deps = ["//:modern-cpp-kafka-api"], | ||
) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
project("kafka-tools") | ||
|
||
|
||
#--------------------------- | ||
# boost | ||
#--------------------------- | ||
if (DEFINED ENV{BOOST_ROOT}) | ||
set(Boost_INCLUDE_DIRS $ENV{BOOST_ROOT}/include) | ||
set(Boost_LIBRARY_DIRS $ENV{BOOST_ROOT}/lib) | ||
else () | ||
find_package(Boost COMPONENTS program_options REQUIRED) | ||
if (NOT Boost_FOUND) | ||
message(FATAL_ERROR "Boost not found!") | ||
endif () | ||
endif () | ||
|
||
message(STATUS "boost include directory: ${Boost_INCLUDE_DIRS}") | ||
message(STATUS "boost library directory: ${Boost_LIBRARY_DIRS}") | ||
|
||
include_directories(SYSTEM ${Boost_INCLUDE_DIRS}) | ||
link_directories(${Boost_LIBRARY_DIRS}) | ||
|
||
|
||
# Target: kafka-topics | ||
set(KafkaTopics kafka-topics) | ||
|
||
add_executable("${KafkaTopics}" "KafkaTopics.cc") | ||
target_link_libraries("${KafkaTopics}" modern-cpp-kafka-api boost_program_options) | ||
|
||
install(TARGETS "${KafkaTopics}" DESTINATION tools) | ||
|
||
|
||
# Target: kafka-console-consumer | ||
set(KafkaConsoleConsumer kafka-console-consumer) | ||
|
||
add_executable("${KafkaConsoleConsumer}" "KafkaConsoleConsumer.cc") | ||
target_link_libraries("${KafkaConsoleConsumer}" modern-cpp-kafka-api boost_program_options) | ||
|
||
install(TARGETS "${KafkaConsoleConsumer}" DESTINATION tools) | ||
|
||
|
||
# Target: kafka-console-producer | ||
set(KafkaConsoleProducer kafka-console-producer) | ||
|
||
add_executable("${KafkaConsoleProducer}" "KafkaConsoleProducer.cc") | ||
target_link_libraries("${KafkaConsoleProducer}" modern-cpp-kafka-api boost_program_options) | ||
|
||
install(TARGETS "${KafkaConsoleProducer}" DESTINATION tools) |
File renamed without changes.
File renamed without changes.
File renamed without changes.