summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@debian.org>2016-08-20 03:22:24 +0200
committerJulian Andres Klode <jak@debian.org>2016-08-24 10:08:25 +0200
commitfce0e7969b056354f80bf43bf4ef846f608ef848 (patch)
treed96e76406abfaf0edf9c3d5d9679defb9ad49bf5 /CMakeLists.txt
parentd6398180871a5f56fd926c77cfbb04e037dab7ff (diff)
CMake: Add Large File Support
This module should cover all sorts of large file supports, as long as they either support the getconf LFS_CFLAGS command; or the _FILE_OFFSET_BITS=64 or _LARGE_FILES macros. Closes: #834767 (cherry picked from commit 3fbd67460e1c4c38a79d00f09bf3113a39abbeca)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ad0fcc0d0..1a4d584f5 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -27,6 +27,12 @@ include(GNUInstallDirs)
include(TestBigEndian)
find_package(Threads)
find_package(PkgConfig)
+find_package(LFS REQUIRED)
+
+# Add large file support
+add_compile_options(${LFS_COMPILE_OPTIONS})
+add_definitions(${LFS_DEFINITIONS})
+link_libraries(${LFS_LIBRARIES})
# Set compiler flags
set(CMAKE_CXX_STANDARD 11)