Skip to content

Commit e91cb12

Browse files
committed
cmake: workaround minidump libraries finding for i686 nexe
1 parent 7e5d912 commit e91cb12

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

CMakeLists.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -516,6 +516,17 @@ if (WIN32)
516516
elseif (NACL)
517517
find_library(NACL_EXCEPTION nacl_exception)
518518
find_library(NACL_MINIDUMP minidump_generator)
519+
520+
# HACK: To be removed when Saigo is repackaged properly.
521+
if (NOT NACL_MINIDUMP
522+
# NACL_TARGET is specific to Saigo, PNaCl target is le32 and doesn't set NACL_TARGET.
523+
AND "${NACL_TARGET}" STREQUAL "i686"
524+
# x86_64-nacl/lib32 is specific to Google build, other builds may provide i686-nacl/lib instead.
525+
AND EXISTS "${DEPS_DIR}/saigo_newlib/x86_64-nacl/lib32")
526+
set(NACL_EXCEPTION "${DEPS_DIR}/saigo_newlib/x86_64-nacl/lib32/libnacl_exception.a")
527+
set(NACL_MINIDUMP "${DEPS_DIR}/saigo_newlib/x86_64-nacl/lib32/libminidump_generator.a")
528+
endif()
529+
519530
set(LIBS_BASE ${LIBS_BASE} ${NACL_MINIDUMP} ${NACL_EXCEPTION})
520531
else()
521532
find_library(LIBM m)

0 commit comments

Comments
 (0)