Skip to content

Commit ed0e747

Browse files
authored
fix: sol2 header to allow for empty lua macro definitions (#7441)
1 parent 9000f51 commit ed0e747

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
- FIXED: Work around compilation error due to a false-positive of array-bounds check in sol2 [#7317](https://github.com/Project-OSRM/osrm-backend/pull/7317)
3232
- FIXED: Fix compilation with gcc >14 in release with LTO. [#7268](https://github.com/Project-OSRM/osrm-backend/issues/7268)
3333
- ADDED: Conditionally prefix custom CMake targets with `osrm_` when built as subproject, and add ALIAS targets for FetchContent compatibility [#7267](https://github.com/Project-OSRM/osrm-backend/issues/7267)
34+
- FIXED: Compilation error in vendored sol2 when LUA_COMPAT_BITLIB or LUA_COMPAT_5_2 are defined as empty macros [#00](https://github.com/Project-OSRM/osrm-backend/issues/00)
3435
- Misc:
3536
- CHANGED: Upgrade from clang-format-15 to clang-format-18 [#7249](https://github.com/Project-OSRM/osrm-backend/issues/7249)
3637
- ADDED: `--output` / `-o` option to osrm-extract for specifying custom output base path [#4930](https://github.com/Project-OSRM/osrm-backend/issues/4930)

third_party/sol2/include/sol/sol.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3107,7 +3107,7 @@ struct pre_main {
31073107
#else
31083108
// Lua 5.2 only (deprecated in 5.3 (503)) (Can be turned on with Compat flags)
31093109
// Lua 5.2, or other versions of Lua with the compat flag, or Lua that is not 5.2 with the specific define (5.4.1 either removed it entirely or broke it)
3110-
#if (SOL_LUA_VERSION_I_ == 502) || (defined(LUA_COMPAT_BITLIB) && (LUA_COMPAT_BITLIB != 0)) || (SOL_LUA_VERSION_I_ < 504 && (defined(LUA_COMPAT_5_2) && (LUA_COMPAT_5_2 != 0)))
3110+
#if (SOL_LUA_VERSION_I_ == 502) || (defined(LUA_COMPAT_BITLIB) && (LUA_COMPAT_BITLIB+0 != 0)) || (SOL_LUA_VERSION_I_ < 504 && (defined(LUA_COMPAT_5_2) && (LUA_COMPAT_5_2+0 != 0)))
31113111
#define SOL_LUA_BIT32_LIB_I_ SOL_ON
31123112
#else
31133113
#define SOL_LUA_BIT32_LIB_I_ SOL_DEFAULT_OFF

0 commit comments

Comments
 (0)