Add pkgconfig file (#459)
This commit is contained in:
parent
dfa10df5ae
commit
bc765e73a3
@ -136,6 +136,7 @@ if (USE_TLS)
|
|||||||
else() # default to OpenSSL on all other platforms
|
else() # default to OpenSSL on all other platforms
|
||||||
if (NOT USE_MBED_TLS) # Unless mbedtls is requested
|
if (NOT USE_MBED_TLS) # Unless mbedtls is requested
|
||||||
set(USE_OPEN_SSL ON)
|
set(USE_OPEN_SSL ON)
|
||||||
|
set(requires "openssl")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@ -167,7 +168,8 @@ if(BUILD_SHARED_LIBS)
|
|||||||
)
|
)
|
||||||
|
|
||||||
# Set library version
|
# Set library version
|
||||||
set_target_properties(ixwebsocket PROPERTIES VERSION 11.3.2)
|
set(version 11.3.2)
|
||||||
|
set_target_properties(ixwebsocket PROPERTIES VERSION ${version})
|
||||||
|
|
||||||
else()
|
else()
|
||||||
# Static library
|
# Static library
|
||||||
@ -290,6 +292,10 @@ if (IXWEBSOCKET_INSTALL)
|
|||||||
configure_file("${CMAKE_CURRENT_LIST_DIR}/ixwebsocket-config.cmake.in" "${CMAKE_CURRENT_BINARY_DIR}/ixwebsocket-config.cmake" @ONLY)
|
configure_file("${CMAKE_CURRENT_LIST_DIR}/ixwebsocket-config.cmake.in" "${CMAKE_CURRENT_BINARY_DIR}/ixwebsocket-config.cmake" @ONLY)
|
||||||
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/ixwebsocket-config.cmake" DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/ixwebsocket")
|
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/ixwebsocket-config.cmake" DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/ixwebsocket")
|
||||||
|
|
||||||
|
set(prefix ${CMAKE_INSTALL_PREFIX})
|
||||||
|
configure_file("${CMAKE_CURRENT_LIST_DIR}/ixwebsocket.pc.in" "${CMAKE_CURRENT_BINARY_DIR}/ixwebsocket.pc" @ONLY)
|
||||||
|
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/ixwebsocket.pc" DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
|
||||||
|
|
||||||
install(EXPORT ixwebsocket
|
install(EXPORT ixwebsocket
|
||||||
FILE ixwebsocket-targets.cmake
|
FILE ixwebsocket-targets.cmake
|
||||||
NAMESPACE ixwebsocket::
|
NAMESPACE ixwebsocket::
|
||||||
|
11
ixwebsocket.pc.in
Normal file
11
ixwebsocket.pc.in
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
prefix=@prefix@
|
||||||
|
exec_prefix=${prefix}
|
||||||
|
libdir=${exec_prefix}/lib
|
||||||
|
includedir=${prefix}/include
|
||||||
|
|
||||||
|
Name: ixwebsocket
|
||||||
|
Description: websocket and http client and server library, with TLS support and very few dependencies
|
||||||
|
Version: @version@
|
||||||
|
Libs: -L${libdir} -lixwebsocket
|
||||||
|
Cflags: -I${includedir}
|
||||||
|
Requires: @requires@
|
Loading…
Reference in New Issue
Block a user