Allow to change CMAKE_INSTALL_BINDIR and CMAKE_INSTALL_INCLUDEDIR.
GitOrigin-RevId: 5704095d127c7fcf2450133745ab2ac546a1177f
This commit is contained in:
parent
0152d8ea2a
commit
0198711920
@ -5,6 +5,12 @@ project(TDLib VERSION 1.5.5 LANGUAGES CXX C)
|
||||
if (NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
if (NOT DEFINED CMAKE_INSTALL_BINDIR)
|
||||
set(CMAKE_INSTALL_BINDIR "bin")
|
||||
endif()
|
||||
if (NOT DEFINED CMAKE_INSTALL_INCLUDEDIR)
|
||||
set(CMAKE_INSTALL_INCLUDEDIR "include")
|
||||
endif()
|
||||
|
||||
if (POLICY CMP0054)
|
||||
# do not expand quoted arguments
|
||||
@ -915,8 +921,8 @@ add_library(Td::TdJsonStatic ALIAS TdJsonStatic)
|
||||
install(TARGETS tdjson TdJson tdjson_static TdJsonStatic tdjson_private tdclient tdcore TdStatic EXPORT TdTargets
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
|
||||
INCLUDES DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}"
|
||||
)
|
||||
|
||||
install(EXPORT TdTargets
|
||||
@ -925,12 +931,12 @@ install(EXPORT TdTargets
|
||||
DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/Td"
|
||||
)
|
||||
|
||||
install(FILES ${TD_JSON_HEADERS} "${CMAKE_CURRENT_BINARY_DIR}/td/telegram/tdjson_export.h" DESTINATION include/td/telegram)
|
||||
install(FILES td/telegram/Client.h td/telegram/Log.h DESTINATION include/td/telegram)
|
||||
install(FILES td/tl/TlObject.h DESTINATION include/td/tl)
|
||||
install(FILES "${TL_TD_AUTO_INCLUDES}/td/telegram/td_api.h" "${TL_TD_AUTO_INCLUDES}/td/telegram/td_api.hpp" DESTINATION include/td/telegram)
|
||||
install(FILES ${TD_JSON_HEADERS} "${CMAKE_CURRENT_BINARY_DIR}/td/telegram/tdjson_export.h" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/td/telegram")
|
||||
install(FILES td/telegram/Client.h td/telegram/Log.h DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/td/telegram")
|
||||
install(FILES td/tl/TlObject.h DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/td/tl")
|
||||
install(FILES "${TL_TD_AUTO_INCLUDES}/td/telegram/td_api.h" "${TL_TD_AUTO_INCLUDES}/td/telegram/td_api.hpp" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/td/telegram")
|
||||
if (TD_ENABLE_JNI)
|
||||
install(FILES td/tl/tl_jni_object.h DESTINATION include/td/tl)
|
||||
install(FILES td/tl/tl_jni_object.h DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/td/tl")
|
||||
endif()
|
||||
|
||||
include(CMakePackageConfigHelpers)
|
||||
|
@ -1,5 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
|
||||
|
||||
if (NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
|
||||
if (NOT OPENSSL_FOUND)
|
||||
find_package(OpenSSL REQUIRED)
|
||||
find_package(ZLIB REQUIRED)
|
||||
@ -47,6 +51,4 @@ endif()
|
||||
install(TARGETS tdsqlite EXPORT TdTargets
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
@ -1,5 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
|
||||
|
||||
if (NOT DEFINED CMAKE_INSTALL_BINDIR)
|
||||
set(CMAKE_INSTALL_BINDIR "bin")
|
||||
endif()
|
||||
|
||||
file(MAKE_DIRECTORY auto/td/telegram)
|
||||
file(MAKE_DIRECTORY auto/td/mtproto)
|
||||
|
||||
@ -129,9 +133,9 @@ if (NOT CMAKE_CROSSCOMPILING)
|
||||
)
|
||||
|
||||
if (TD_ENABLE_JNI)
|
||||
install(TARGETS td_generate_java_api RUNTIME DESTINATION bin)
|
||||
install(FILES JavadocTlDocumentationGenerator.php TlDocumentationGenerator.php DESTINATION bin/td/generate)
|
||||
install(FILES scheme/td_api.tlo scheme/td_api.tl DESTINATION bin/td/generate/scheme)
|
||||
install(TARGETS td_generate_java_api RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
|
||||
install(FILES JavadocTlDocumentationGenerator.php TlDocumentationGenerator.php DESTINATION "${CMAKE_INSTALL_BINDIR}/td/generate")
|
||||
install(FILES scheme/td_api.tlo scheme/td_api.tl DESTINATION "${CMAKE_INSTALL_BINDIR}/td/generate/scheme")
|
||||
endif()
|
||||
|
||||
if (TD_ENABLE_DOTNET)
|
||||
|
@ -1,5 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
|
||||
|
||||
if (NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
|
||||
#SOURCE SETS
|
||||
set(TDACTOR_SOURCE
|
||||
td/actor/impl/ConcurrentScheduler.cpp
|
||||
@ -52,6 +56,4 @@ endif()
|
||||
install(TARGETS tdactor EXPORT TdTargets
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
@ -1,5 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
|
||||
|
||||
if (NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
|
||||
#SOURCE SETS
|
||||
set(TDDB_SOURCE
|
||||
td/db/binlog/Binlog.cpp
|
||||
@ -52,6 +56,4 @@ endif()
|
||||
install(TARGETS tddb EXPORT TdTargets
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
@ -1,5 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
|
||||
|
||||
if (NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
|
||||
if (NOT OPENSSL_FOUND)
|
||||
find_package(OpenSSL REQUIRED)
|
||||
find_package(ZLIB REQUIRED)
|
||||
@ -61,6 +65,4 @@ endif()
|
||||
install(TARGETS tdnet EXPORT TdTargets
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
@ -1,5 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
|
||||
|
||||
if (NOT DEFINED CMAKE_INSTALL_LIBDIR)
|
||||
set(CMAKE_INSTALL_LIBDIR "lib")
|
||||
endif()
|
||||
|
||||
if (WIN32)
|
||||
if (WINGETOPT_FOUND)
|
||||
set(TD_HAVE_GETOPT 1)
|
||||
@ -328,6 +332,4 @@ endif()
|
||||
install(TARGETS tdutils EXPORT TdTargets
|
||||
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user