From 340af12e02a06a8efe94df866fe363d88dbccc6e Mon Sep 17 00:00:00 2001 From: Scott K Logan Date: Tue, 22 Sep 2020 16:49:01 -0700 Subject: [PATCH] Fix the declared language for a few packages Signed-off-by: Scott K Logan --- rosidl_generator_c/CMakeLists.txt | 2 +- rosidl_runtime_c/CMakeLists.txt | 4 ++-- rosidl_typesupport_introspection_c/CMakeLists.txt | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/rosidl_generator_c/CMakeLists.txt b/rosidl_generator_c/CMakeLists.txt index 2a079103d..3d61cd87b 100644 --- a/rosidl_generator_c/CMakeLists.txt +++ b/rosidl_generator_c/CMakeLists.txt @@ -7,7 +7,7 @@ if(NOT CMAKE_C_STANDARD) set(CMAKE_C_STANDARD 11) endif() -if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") +if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang") add_compile_options(-Wall -Wextra -Wpedantic) endif() diff --git a/rosidl_runtime_c/CMakeLists.txt b/rosidl_runtime_c/CMakeLists.txt index 695120bac..16839b878 100644 --- a/rosidl_runtime_c/CMakeLists.txt +++ b/rosidl_runtime_c/CMakeLists.txt @@ -7,7 +7,7 @@ if(NOT CMAKE_C_STANDARD) set(CMAKE_C_STANDARD 11) endif() -if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") +if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang") add_compile_options(-Wall -Wextra -Wpedantic) endif() @@ -29,7 +29,7 @@ target_include_directories(${PROJECT_NAME} PUBLIC ament_target_dependencies(${PROJECT_NAME} "rcutils" "rosidl_typesupport_interface") -if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") +if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang") set_target_properties(${PROJECT_NAME} PROPERTIES COMPILE_OPTIONS -Wall -Wextra -Wpedantic) endif() diff --git a/rosidl_typesupport_introspection_c/CMakeLists.txt b/rosidl_typesupport_introspection_c/CMakeLists.txt index 8167725f9..5b581ec97 100644 --- a/rosidl_typesupport_introspection_c/CMakeLists.txt +++ b/rosidl_typesupport_introspection_c/CMakeLists.txt @@ -1,13 +1,13 @@ cmake_minimum_required(VERSION 3.5) -project(rosidl_typesupport_introspection_c) +project(rosidl_typesupport_introspection_c C) # Default to C11 if(NOT CMAKE_C_STANDARD) set(CMAKE_C_STANDARD 11) endif() -if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") +if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang") add_compile_options(-Wall -Wextra -Wpedantic) endif()