--- CMakeLists.txt.orig	2017-11-28 16:06:22.000000000 -0800
+++ CMakeLists.txt	2017-11-28 16:07:25.000000000 -0800
@@ -27,6 +27,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
@@ -344,10 +346,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).
@@ -441,8 +443,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.
@@ -505,7 +507,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})