aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesper Särnesjö <[email protected]>2014-08-20 18:03:29 +1000
committerChris Robinson <[email protected]>2014-08-20 13:31:24 -0700
commitba9995a8dec53518e758fc5ffc4283243b550fff (patch)
tree4bbb051f12415e93db43980c32fda39b399e119f
parente3d72ccd150679e92c9bf21518a2a6d164ea4a29 (diff)
Use directories relative to current project in CheckFileOffsetBits.cmake
Enables building OpenAL Soft in a subdirectory of another project.
-rw-r--r--cmake/CheckFileOffsetBits.cmake8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmake/CheckFileOffsetBits.cmake b/cmake/CheckFileOffsetBits.cmake
index 8b549b69..1dc154e4 100644
--- a/cmake/CheckFileOffsetBits.cmake
+++ b/cmake/CheckFileOffsetBits.cmake
@@ -17,13 +17,13 @@ MACRO(CHECK_FILE_OFFSET_BITS)
IF(NOT DEFINED _FILE_OFFSET_BITS)
MESSAGE(STATUS "Checking _FILE_OFFSET_BITS for large files")
TRY_COMPILE(__WITHOUT_FILE_OFFSET_BITS_64
- ${CMAKE_BINARY_DIR}
- ${CMAKE_SOURCE_DIR}/cmake/CheckFileOffsetBits.c
+ ${CMAKE_CURRENT_BINARY_DIR}
+ ${CMAKE_CURRENT_SOURCE_DIR}/cmake/CheckFileOffsetBits.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS})
IF(NOT __WITHOUT_FILE_OFFSET_BITS_64)
TRY_COMPILE(__WITH_FILE_OFFSET_BITS_64
- ${CMAKE_BINARY_DIR}
- ${CMAKE_SOURCE_DIR}/cmake/CheckFileOffsetBits.c
+ ${CMAKE_CURRENT_BINARY_DIR}
+ ${CMAKE_CURRENT_SOURCE_DIR}/cmake/CheckFileOffsetBits.c
COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS} -D_FILE_OFFSET_BITS=64)
ENDIF(NOT __WITHOUT_FILE_OFFSET_BITS_64)