From f4adf107f31674eb20881531900ff092cc40c07f Mon Sep 17 00:00:00 2001 From: Flavio Ceolin Date: Tue, 3 Dec 2019 09:09:07 -0800 Subject: [PATCH] syscalls: Remove gen_syscall_header.py gen_syscall_header.py is not longer necessary, it was just creating a file including syscall.h. This header is now included directly by gen_syscalls.py. Signed-off-by: Flavio Ceolin --- CMakeLists.txt | 14 -------------- CODEOWNERS | 1 - include/syscall.h | 1 - scripts/gen_syscall_header.py | 24 ------------------------ scripts/gen_syscalls.py | 2 +- 5 files changed, 1 insertion(+), 41 deletions(-) delete mode 100755 scripts/gen_syscall_header.py diff --git a/CMakeLists.txt b/CMakeLists.txt index 561a9469b76..ca9302e25db 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -50,7 +50,6 @@ set(ZEPHYR_FINAL_EXECUTABLE zephyr_final) # Set some phony targets to collect dependencies set(OFFSETS_H_TARGET offsets_h) -set(SYSCALL_MACROS_H_TARGET syscall_macros_h_target) set(SYSCALL_LIST_H_TARGET syscall_list_h_target) set(DRIVER_VALIDATION_H_TARGET driver_validation_h_target) set(KOBJ_TYPES_H_TARGET kobj_types_h_target) @@ -477,18 +476,6 @@ if(EXISTS ${CMAKE_BINARY_DIR}/zephyr_modules.txt) set(ZEPHYR_CURRENT_MODULE_DIR) endif() -set(syscall_macros_h ${ZEPHYR_BINARY_DIR}/include/generated/syscall_macros.h) - -add_custom_target(${SYSCALL_MACROS_H_TARGET} DEPENDS ${syscall_macros_h}) -add_custom_command( OUTPUT ${syscall_macros_h} - COMMAND - ${PYTHON_EXECUTABLE} - ${ZEPHYR_BASE}/scripts/gen_syscall_header.py - > ${syscall_macros_h} - DEPENDS ${ZEPHYR_BASE}/scripts/gen_syscall_header.py - ) - - set(syscall_list_h ${CMAKE_CURRENT_BINARY_DIR}/include/generated/syscall_list.h) set(syscalls_json ${CMAKE_CURRENT_BINARY_DIR}/misc/generated/syscalls.json) @@ -637,7 +624,6 @@ target_include_directories(${OFFSETS_LIB} PRIVATE target_link_libraries(${OFFSETS_LIB} zephyr_interface) add_dependencies( ${OFFSETS_LIB} ${SYSCALL_LIST_H_TARGET} - ${SYSCALL_MACROS_H_TARGET} ${DRIVER_VALIDATION_H_TARGET} ${KOBJ_TYPES_H_TARGET} ) diff --git a/CODEOWNERS b/CODEOWNERS index a4407ed5ec6..cf1b2d5f2c5 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -331,7 +331,6 @@ /arch/x86/gen_idt.py @andrewboie /scripts/gen_kobject_list.py @andrewboie /scripts/gen_priv_stacks.py @andrewboie @agross-oss @ioannisg -/scripts/gen_syscall_header.py @andrewboie /scripts/gen_syscalls.py @andrewboie /scripts/process_gperf.py @andrewboie /scripts/gen_relocate_app.py @wentongwu diff --git a/include/syscall.h b/include/syscall.h index 6f73f5f4218..ef2f38fd32b 100644 --- a/include/syscall.h +++ b/include/syscall.h @@ -14,7 +14,6 @@ #ifndef _ASMLANGUAGE #include -#include #ifdef __cplusplus extern "C" { diff --git a/scripts/gen_syscall_header.py b/scripts/gen_syscall_header.py deleted file mode 100755 index b08c4d53808..00000000000 --- a/scripts/gen_syscall_header.py +++ /dev/null @@ -1,24 +0,0 @@ -#!/usr/bin/env python3 -# -# Copyright (c) 2017 Intel Corporation -# -# SPDX-License-Identifier: Apache-2.0 - -""" -Generation script for syscall_macros.h - -Except for a single transitive include, this header is empty. The -generated code that used to live here is now emitted by -gen_syscalls.py directly. - -This script has no inputs, and emits the generated header to stdout. -""" - -import sys - -sys.stdout.write( - "/* Auto-generated by gen_syscall_header.py, do not edit! */\n\n") -sys.stdout.write("#ifndef GEN_SYSCALL_H\n#define GEN_SYSCALL_H\n\n") -sys.stdout.write("#include \n") - -sys.stdout.write("#endif /* GEN_SYSCALL_H */\n") diff --git a/scripts/gen_syscalls.py b/scripts/gen_syscalls.py index d70befb2dc3..2e75bd511e6 100755 --- a/scripts/gen_syscalls.py +++ b/scripts/gen_syscalls.py @@ -78,7 +78,7 @@ syscall_template = """ #ifndef _ASMLANGUAGE #include -#include +#include #if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6) #pragma GCC diagnostic push