forked from premiere/premiere-libtorrent
Add tools to cmake build
This commit is contained in:
parent
17055ad4d1
commit
7e390b1ca7
|
@ -452,6 +452,7 @@ option(libiconv "enable linking against system libiconv" OFF)
|
|||
option(logging "build with logging" ON)
|
||||
option(build_tests "build tests" OFF)
|
||||
option(build_examples "build examples" OFF)
|
||||
option(build_tools "build tools" OFF)
|
||||
option(python-bindings "build python bindings" OFF)
|
||||
|
||||
set(CMAKE_CONFIGURATION_TYPES Debug Release RelWithDebInfo)
|
||||
|
@ -738,6 +739,11 @@ install(
|
|||
${ConfigPackageLocation}
|
||||
)
|
||||
|
||||
# === build tools ===
|
||||
if (build_tools)
|
||||
add_subdirectory(tools)
|
||||
endif()
|
||||
|
||||
# === build examples ===
|
||||
if (build_examples)
|
||||
add_subdirectory(examples)
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
add_executable(parse_access_log parse_access_log.cpp)
|
||||
target_link_libraries(parse_access_log PRIVATE torrent-rasterbar)
|
||||
|
||||
add_executable(dht dht_put.cpp)
|
||||
target_link_libraries(dht PRIVATE torrent-rasterbar)
|
||||
|
||||
add_executable(session_log_alerts session_log_alerts.cpp)
|
||||
target_link_libraries(session_log_alerts torrent-rasterbar)
|
|
@ -39,7 +39,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
using namespace lt;
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
int main(int /*argc*/, char* /*argv*/[])
|
||||
{
|
||||
std::printf("press Ctrl+C, kill the process or wait for 1000 alerts\n");
|
||||
|
||||
|
|
Loading…
Reference in New Issue