--- CMakeLists.txt.orig 2021-12-23 03:14:18.000000000 -0800 +++ CMakeLists.txt 2022-01-08 14:27:34.000000000 -0800 @@ -31,6 +31,8 @@ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32") set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -m32") set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -m32") +else () + set_property (GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS FALSE) endif () # Helper functions dealing with finding libraries and programs this library @@ -386,10 +388,10 @@ endif () if (NOT WIN32) - add_definitions ("-Wall -Werror") + add_definitions ("-Wall") endif () -include_directories ("src") +include_directories (BEFORE "src") if (${BUILD_STATIC_LIB} STREQUAL "ON") # Build a static library (without -fPIC). @@ -498,8 +500,8 @@ list (APPEND GEOCODER_DEPS ${COMMON_DEPS}) # Note that the subset of base/ on which the geocoder relies is implemented # on top of Boost header-only libraries (e.g. scoped_ptr.hpp). - target_link_libraries (geocoding ${LIBRARY_DEPS}) - target_link_libraries (geocoding-shared ${LIBRARY_DEPS}) + target_link_libraries (geocoding phonenumber ${LIBRARY_DEPS}) + target_link_libraries (geocoding-shared phonenumber-shared ${LIBRARY_DEPS}) endif () # Build a specific library for testing purposes. @@ -562,7 +564,7 @@ endif () # Build the testing binary. -include_directories ("test") +include_directories (BEFORE "test") add_executable (libphonenumber_test ${TEST_SOURCES}) set (TEST_LIBS phonenumber_testing ${GTEST_LIB})