diff --git a/.github/scripts/stb/linux.sh b/.github/scripts/stb/linux.sh index 18ecff6..2350364 100644 --- a/.github/scripts/stb/linux.sh +++ b/.github/scripts/stb/linux.sh @@ -1,2 +1,5 @@ +#!/bin/bash +set -euo pipefail + # Just directly record self as root directory export STB_ROOT=$(pwd) diff --git a/.github/scripts/stb/macos.sh b/.github/scripts/stb/macos.sh index 18ecff6..2350364 100644 --- a/.github/scripts/stb/macos.sh +++ b/.github/scripts/stb/macos.sh @@ -1,2 +1,5 @@ +#!/bin/bash +set -euo pipefail + # Just directly record self as root directory export STB_ROOT=$(pwd) diff --git a/CMake/FindSTB.cmake b/CMake/FindSTB.cmake index 45257ff..e286d96 100644 --- a/CMake/FindSTB.cmake +++ b/CMake/FindSTB.cmake @@ -12,9 +12,9 @@ if (NOT DEFINED STB_ROOT) set(STB_FOUND FALSE) else () - # Look for STB_image.h in the specified STB_ROOT directory + # Look for stb_image.h in the specified STB_ROOT directory find_path(STB_INCLUDE_DIR - NAMES STB_image.h + NAMES stb_image.h HINTS ${STB_ROOT} NO_DEFAULT_PATH ) @@ -46,7 +46,7 @@ if (STB_FOUND) ) else () # If it is required, show infomations. - if (std_FIND_REQUIRED) + if (STB_FIND_REQUIRED) message(FATAL_ERROR "Fail to find STB library.") endif () endif () diff --git a/CMakeLists.txt b/CMakeLists.txt index 7c612d4..aaf5b94 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -45,7 +45,7 @@ include(CMakePackageConfigHelpers) # we should enable PIC (position independent code), otherwise build process will fail. # Also we should let all symbols in final dll be hidden (not exported) in default. # Because we only want export functions we ordered. -if ((NOT WIN32) AND NEMO_BUILD_BMAP) +if ((NOT WIN32) AND (NEMO_BUILD_BALLANCE AND NEMO_BUILD_BMAP)) set(CMAKE_CXX_VISIBILITY_PRESET hidden) set(CMAKE_C_VISIBILITY_PRESET hidden) set(CMAKE_POSITION_INDEPENDENT_CODE True)