Fix pkgconfig install path on package
This commit is contained in:
parent
4066171ea2
commit
3333ca7d69
|
@ -205,7 +205,7 @@ if (NOT BIN_INSTALL_DIR)
|
|||
endif ()
|
||||
|
||||
if (NOT INCLUDE_INSTALL_DIR)
|
||||
set(INCLUDE_INSTALL_DIR include)
|
||||
set(INCLUDE_INSTALL_DIR include/${LIB_NAME})
|
||||
endif ()
|
||||
|
||||
# Always build the STATIC library
|
||||
|
@ -408,8 +408,6 @@ endif ()
|
|||
include(CPack)
|
||||
|
||||
# pkg-config
|
||||
set(INSTALL_LIBDIR "${CMAKE_INSTALL_PREFIX}/${LIB_INSTALL_DIR}" CACHE PATH "Installation directory for libraries")
|
||||
set(INSTALL_INCDIR "${CMAKE_INSTALL_PREFIX}/${INCLUDE_INSTALL_DIR}" CACHE PATH "Installation directory for headers")
|
||||
configure_file(
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/${LIB_NAME}.pc.cmake.in"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}.pc"
|
||||
|
@ -417,7 +415,7 @@ configure_file(
|
|||
)
|
||||
install(FILES
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}.pc"
|
||||
DESTINATION "${INSTALL_LIBDIR}/pkgconfig"
|
||||
DESTINATION "${LIB_INSTALL_DIR}/pkgconfig"
|
||||
)
|
||||
|
||||
# eof
|
||||
|
|
|
@ -40,6 +40,14 @@ If you do **not** need the tidy library built as a 'shared' (DLL) library, then
|
|||
|
||||
See the `CMakeLists.txt` file for other CMake **options** offered.
|
||||
|
||||
## Build the tidy packages
|
||||
|
||||
1. `cd build/cmake`
|
||||
|
||||
2. `cmake ../.. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr`
|
||||
|
||||
3. Unix/OS X: `make package`
|
||||
|
||||
## Build PHP with the tidy-html5 library
|
||||
|
||||
Due to API changes in the PHP source, `buffio.h` needs to be renamed to `tidybuffio.h` in the file `ext/tidy/tidy.c` in PHP's source.
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
libdir=@INSTALL_LIBDIR@
|
||||
includedir=@INSTALL_INCDIR@
|
||||
prefix=@CMAKE_INSTALL_PREFIX@
|
||||
exec_prefix=${prefix}
|
||||
libdir=${exec_prefix}/@LIB_INSTALL_DIR@
|
||||
includedir=${prefix}/@INCLUDE_INSTALL_DIR@
|
||||
|
||||
Name: @LIB_NAME@
|
||||
Description: @LIBTIDY_DESCRIPTION@
|
||||
|
|
Loading…
Reference in a new issue