libc: replace null.h and size_t.h with stddef.h
According to commit b71a8a4591 and Jira: ZEP-733
(libc: remove stddef.h which is provided by the compiler),
the stddef.h in zephyr code is removed and it's provided
by the compiler. The original stddef.h includes two head
files, null.h and size_t.h, which are also useless now.
So remove these two deprecated files, in case conflicting
definition.
Change-Id: Ie7163fdbd23c32759425b50f3deff2a57cc051a9
Signed-off-by: Qiu Peiyang <peiyangx.qiu@intel.com>
This commit is contained in:
parent
884d9fb50f
commit
c53fe299c0
@ -1,28 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2016 Wind River Systems, Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file
|
||||
* @brief NULL definition
|
||||
*/
|
||||
|
||||
#if !defined(NULL)
|
||||
#ifdef __cplusplus
|
||||
#define NULL 0
|
||||
#else
|
||||
#define NULL (void *)0
|
||||
#endif
|
||||
#endif
|
||||
@ -1,37 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2016 Wind River Systems, Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file
|
||||
* @brief size_t definition
|
||||
*/
|
||||
|
||||
#if !defined(__size_t_defined)
|
||||
#define __size_t_defined
|
||||
|
||||
#ifdef __i386
|
||||
typedef unsigned long int size_t;
|
||||
#elif defined(__ARM_ARCH)
|
||||
typedef unsigned int size_t;
|
||||
#elif defined(__arc__)
|
||||
typedef unsigned int size_t;
|
||||
#elif defined(__NIOS2__)
|
||||
typedef unsigned int size_t;
|
||||
#else
|
||||
#error "The minimal libc library does not recognize the architecture!\n"
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@ -20,9 +20,8 @@
|
||||
#define __INC_stdio_h__
|
||||
|
||||
#include <stdarg.h> /* Needed to get definition of va_list */
|
||||
#include <bits/null.h>
|
||||
#include <bits/size_t.h>
|
||||
#include <bits/restrict.h>
|
||||
#include <stddef.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
|
||||
@ -19,9 +19,7 @@
|
||||
#ifndef __INC_stdlib_h__
|
||||
#define __INC_stdlib_h__
|
||||
|
||||
#include <bits/null.h>
|
||||
#include <bits/size_t.h>
|
||||
|
||||
#include <stddef.h>
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
@ -19,8 +19,7 @@
|
||||
#ifndef __INC_string_h__
|
||||
#define __INC_string_h__
|
||||
|
||||
#include <bits/null.h>
|
||||
#include <bits/size_t.h>
|
||||
#include <stddef.h>
|
||||
#include <bits/restrict.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
Loading…
Reference in New Issue
Block a user