summaryrefslogtreecommitdiffstats
path: root/source/l/SDL2/SDL2.no-werror-declaration-after-statement.diff
diff options
context:
space:
mode:
Diffstat (limited to 'source/l/SDL2/SDL2.no-werror-declaration-after-statement.diff')
-rw-r--r--source/l/SDL2/SDL2.no-werror-declaration-after-statement.diff18
1 files changed, 18 insertions, 0 deletions
diff --git a/source/l/SDL2/SDL2.no-werror-declaration-after-statement.diff b/source/l/SDL2/SDL2.no-werror-declaration-after-statement.diff
new file mode 100644
index 000000000..52e612888
--- /dev/null
+++ b/source/l/SDL2/SDL2.no-werror-declaration-after-statement.diff
@@ -0,0 +1,18 @@
+--- ./CMakeLists.txt.orig 2022-04-21 12:37:37.000000000 -0500
++++ ./CMakeLists.txt 2022-04-26 13:11:44.293866236 -0500
+@@ -532,15 +532,6 @@
+ list(APPEND EXTRA_CFLAGS "-fno-strict-aliasing")
+ endif()
+
+- check_c_compiler_flag(-Wdeclaration-after-statement HAVE_GCC_WDECLARATION_AFTER_STATEMENT)
+- if(HAVE_GCC_WDECLARATION_AFTER_STATEMENT)
+- check_c_compiler_flag(-Werror=declaration-after-statement HAVE_GCC_WERROR_DECLARATION_AFTER_STATEMENT)
+- if(HAVE_GCC_WERROR_DECLARATION_AFTER_STATEMENT)
+- list(APPEND EXTRA_CFLAGS "-Werror=declaration-after-statement")
+- endif()
+- list(APPEND EXTRA_CFLAGS "-Wdeclaration-after-statement")
+- endif()
+-
+ if(DEPENDENCY_TRACKING)
+ check_c_source_compiles("
+ #if !defined(__GNUC__) || __GNUC__ < 3