mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
If -Wextra is appended to CFLAGS it will enable all warnings. Previous options such as -Wno-unused-parameters have no effect anymore. As a result compilation will fail with gcc-4.3. Newer versions of gcc will appearently remember -Wno-* options before -Wextra. Rearrange warning options for gcc so that -Wextra comes before other -W options. This fixes compilation of stubdom in SLES11. Signed-off-by: Olaf Hering <olaf@aepfle.de> Acked-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
22 lines
826 B
Diff
22 lines
826 B
Diff
---
|
|
CMakeLists.txt | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
Index: tpm_emulator-x86_64/CMakeLists.txt
|
|
===================================================================
|
|
--- tpm_emulator-x86_64.orig/CMakeLists.txt
|
|
+++ tpm_emulator-x86_64/CMakeLists.txt
|
|
@@ -40,10 +40,11 @@ set(TPM_STORAGE_NAME "/var/lib/tpm/tpm_e
|
|
set(TPM_DEVICE_NAME "/dev/tpm")
|
|
endif()
|
|
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.in ${CMAKE_CURRENT_BINARY_DIR}/config.h)
|
|
-add_definitions(-Wall -Werror -Wno-unused-parameter -Wpointer-arith -Wcast-align -Wwrite-strings)
|
|
+add_definitions(-Wall -Werror)
|
|
if("${CMAKE_SYSTEM}" MATCHES "Linux")
|
|
add_definitions(-Wextra)
|
|
endif()
|
|
+add_definitions(-Wno-unused-parameter -Wpointer-arith -Wcast-align -Wwrite-strings)
|
|
if(USE_OPENSSL)
|
|
add_definitions(-DUSE_OPENSSL)
|
|
endif()
|