Add: introduce CMake for project management
CMake works on all our supported platforms, like MSVC, Mingw, GCC,
Clang, and many more. It allows for a single way of doing things,
so no longer we need shell scripts and vbs scripts to work on all
our supported platforms.
Additionally, CMake allows to generate project files for like MSVC,
KDevelop, etc.
This heavily reduces the lines of code we need to support multiple
platforms from a project perspective.
Addtiionally, this heavily improves our detection of libraries, etc.
2019-04-07 10:57:55 +01:00
|
|
|
#[=======================================================================[.rst:
|
|
|
|
FindLZO
|
|
|
|
-------
|
|
|
|
|
|
|
|
Finds the LZO library.
|
|
|
|
|
|
|
|
Result Variables
|
|
|
|
^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
This will define the following variables:
|
|
|
|
|
|
|
|
``LZO_FOUND``
|
|
|
|
True if the system has the LZO library.
|
|
|
|
``LZO_INCLUDE_DIRS``
|
|
|
|
Include directories needed to use LZO.
|
|
|
|
``LZO_LIBRARIES``
|
|
|
|
Libraries needed to link to LZO.
|
|
|
|
``LZO_VERSION``
|
|
|
|
The version of the LZO library which was found.
|
|
|
|
|
|
|
|
Cache Variables
|
|
|
|
^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
The following cache variables may also be set:
|
|
|
|
|
|
|
|
``LZO_INCLUDE_DIR``
|
|
|
|
The directory containing ``lzo/lzo1x.h``.
|
|
|
|
``LZO_LIBRARY``
|
|
|
|
The path to the LZO library.
|
|
|
|
|
|
|
|
#]=======================================================================]
|
|
|
|
|
|
|
|
find_package(PkgConfig QUIET)
|
|
|
|
pkg_check_modules(PC_LZO QUIET lzo2)
|
|
|
|
|
|
|
|
find_path(LZO_INCLUDE_DIR
|
|
|
|
NAMES lzo/lzo1x.h
|
|
|
|
PATHS ${PC_LZO_INCLUDE_DIRS}
|
|
|
|
)
|
|
|
|
|
|
|
|
find_library(LZO_LIBRARY
|
|
|
|
NAMES lzo2
|
|
|
|
PATHS ${PC_LZO_LIBRARY_DIRS}
|
|
|
|
)
|
|
|
|
|
2025-02-12 17:51:29 +00:00
|
|
|
include(FixVcpkgLibrary)
|
|
|
|
FixVcpkgLibrary(LZO)
|
Add: introduce CMake for project management
CMake works on all our supported platforms, like MSVC, Mingw, GCC,
Clang, and many more. It allows for a single way of doing things,
so no longer we need shell scripts and vbs scripts to work on all
our supported platforms.
Additionally, CMake allows to generate project files for like MSVC,
KDevelop, etc.
This heavily reduces the lines of code we need to support multiple
platforms from a project perspective.
Addtiionally, this heavily improves our detection of libraries, etc.
2019-04-07 10:57:55 +01:00
|
|
|
|
|
|
|
set(LZO_VERSION ${PC_LZO_VERSION})
|
|
|
|
|
|
|
|
include(FindPackageHandleStandardArgs)
|
|
|
|
find_package_handle_standard_args(LZO
|
|
|
|
FOUND_VAR LZO_FOUND
|
|
|
|
REQUIRED_VARS
|
|
|
|
LZO_LIBRARY
|
|
|
|
LZO_INCLUDE_DIR
|
|
|
|
VERSION_VAR LZO_VERSION
|
|
|
|
)
|
|
|
|
|
2020-09-25 12:55:25 +01:00
|
|
|
if(LZO_FOUND)
|
Add: introduce CMake for project management
CMake works on all our supported platforms, like MSVC, Mingw, GCC,
Clang, and many more. It allows for a single way of doing things,
so no longer we need shell scripts and vbs scripts to work on all
our supported platforms.
Additionally, CMake allows to generate project files for like MSVC,
KDevelop, etc.
This heavily reduces the lines of code we need to support multiple
platforms from a project perspective.
Addtiionally, this heavily improves our detection of libraries, etc.
2019-04-07 10:57:55 +01:00
|
|
|
set(LZO_LIBRARIES ${LZO_LIBRARY})
|
|
|
|
set(LZO_INCLUDE_DIRS ${LZO_INCLUDE_DIR})
|
2020-09-25 12:55:25 +01:00
|
|
|
endif()
|
Add: introduce CMake for project management
CMake works on all our supported platforms, like MSVC, Mingw, GCC,
Clang, and many more. It allows for a single way of doing things,
so no longer we need shell scripts and vbs scripts to work on all
our supported platforms.
Additionally, CMake allows to generate project files for like MSVC,
KDevelop, etc.
This heavily reduces the lines of code we need to support multiple
platforms from a project perspective.
Addtiionally, this heavily improves our detection of libraries, etc.
2019-04-07 10:57:55 +01:00
|
|
|
|
|
|
|
mark_as_advanced(
|
|
|
|
LZO_INCLUDE_DIR
|
|
|
|
LZO_LIBRARY
|
|
|
|
)
|