Skip to content

Commit 5178f1f

Browse files
authored
Merge pull request #22 from ZIMO-Elektronik/array_bounds
fix: workaround ignore `-Werror=array-bounds` on MINGW
2 parents 3ae3d71 + f4172d6 commit 5178f1f

23 files changed

+30
-25
lines changed

.github/workflows/license.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ on:
88

99
jobs:
1010
license:
11-
uses: ZIMO-Elektronik/.github-workflows/.github/workflows/license-checker.yml@v0.0.6
11+
uses: ZIMO-Elektronik/.github-workflows/.github/workflows/license-checker.yml@v0.0.9

.github/workflows/tests.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ on:
88

99
jobs:
1010
tests:
11-
uses: ZIMO-Elektronik/.github-workflows/.github/workflows/x86_64-linux-gnu-gcc.yml@v0.0.8
11+
uses: ZIMO-Elektronik/.github-workflows/.github/workflows/x86_64-linux-gnu-gcc.yml@v0.0.9
1212
with:
13-
pre-build: sudo apt install -y libgl1-mesa-dev libglx-dev ninja-build
13+
pre-build: sudo apt install -y libgl1-mesa-dev libglx-dev ninja-build

.licenserc.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"{cmake}/**/*.cmake": [
33
"#[[",
44
"MIT License",
5-
"Copyright (c) 2024 ZIMO Elektronik",
5+
"Copyright (c) 2025 ZIMO Elektronik",
66
"Permission is hereby granted, free of charge, to any person obtaining a copy",
77
"of this software and associated documentation files (the \"Software\"), to deal",
88
"in the Software without restriction, including without limitation the rights",

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Changelog
22

3+
## 0.9.4
4+
- Update to CPM 0.40.5
5+
- Bugfix workaround ignore `-Werror=array-bounds` on MINGW
6+
37
## 0.9.3
48
- Update to CPM 0.40.2
59
- Bugfix `add_clang_format_target` doesn't fail without `clang-format`

CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ if(NOT cpm.cmake_SOURCE_DIR)
1515
FetchContent_Declare(
1616
CPM.cmake
1717
GIT_REPOSITORY "https://github.com/cpm-cmake/CPM.cmake.git"
18-
GIT_TAG v0.40.2)
18+
GIT_TAG v0.40.5)
1919
FetchContent_MakeAvailable(CPM.cmake)
2020
include(${cpm.cmake_SOURCE_DIR}/cmake/CPM.cmake)
2121
endif()

LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2024 ZIMO Elektronik
3+
Copyright (c) 2025 ZIMO Elektronik
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

cmake/FindCQtDeployer.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/add_clang_format_target.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/add_compile_link_options.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/build_qt.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/find_qt.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/minify_html.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/sanitize.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/target_common_warnings.cmake

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal
@@ -38,11 +38,12 @@ function(target_common_warnings TARGET SCOPE)
3838
# Make some errors
3939
set(C_ERRORS "$<$<COMPILE_LANGUAGE:C>:-Werror-implicit-function-declaration>")
4040
set(C_CXX_ERRORS
41-
-Werror=array-bounds;-Werror=dangling-else;-Werror=implicit-fallthrough;-Werror=parentheses;-Werror=logical-not-parentheses;-Werror=misleading-indentation;-Werror=return-type;-Werror=sequence-point;-Werror=shift-negative-value;-Werror=shift-overflow;-Werror=sizeof-array-div;-Werror=strict-aliasing;-Werror=tautological-compare;-Werror=type-limits
41+
-Werror=dangling-else;-Werror=implicit-fallthrough;-Werror=parentheses;-Werror=logical-not-parentheses;-Werror=misleading-indentation;-Werror=return-type;-Werror=sequence-point;-Werror=shift-negative-value;-Werror=shift-overflow;-Werror=sizeof-array-div;-Werror=strict-aliasing;-Werror=tautological-compare;-Werror=type-limits
4242
)
4343

4444
if(NOT MINGW)
45-
list(APPEND C_CXX_ERRORS -Werror=array-compare;-Werror=infinite-recursion)
45+
list(APPEND C_CXX_ERRORS
46+
-Werror=array-bounds;-Werror=array-compare;-Werror=infinite-recursion)
4647
endif()
4748

4849
target_compile_options(

cmake/target_compile_link_options.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/target_unity_build.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/toolchain-arm-clang.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/toolchain-arm-none-eabi-gcc.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/toolchain-clang.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/toolchain-gcc-12.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/toolchain-gcc.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/toolchain-x86_64-w64-mingw32-gcc.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

cmake/version_from_git.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#[[
22
MIT License
33
4-
Copyright (c) 2024 ZIMO Elektronik
4+
Copyright (c) 2025 ZIMO Elektronik
55
66
Permission is hereby granted, free of charge, to any person obtaining a copy
77
of this software and associated documentation files (the "Software"), to deal

0 commit comments

Comments
 (0)