# Debugging (Note: DWARF-4 on 4.5.1 when we ship)
add_compile_flags("-gdwarf-2 -g2 -femit-struct-debug-detailed=none -feliminate-unused-debug-types")
+# Do not allow warnings
+add_compile_flags("-Werror")
+
# For some reason, cmake sets -fPIC, and we don't want it
string(REPLACE "-fPIC" "" CMAKE_SHARED_LIBRARY_ASM_FLAGS ${CMAKE_SHARED_LIBRARY_ASM_FLAGS})
add_custom_target(${_target_name} ALL DEPENDS ${_binary_file})
endfunction()
+
+function(allow_warnings __module)
+ add_target_compile_flags(${__module} -Wno-error)
+endfunction()