summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@intel.com>2016-03-09 21:42:01 +0200
committerGerrit Code Review <gerrit@zephyrproject.org>2016-03-11 01:09:56 +0000
commit6692e982988ebd83742a0cb4ba09380290420719 (patch)
treee36f72ddbd82cb350fc46b6ed17b847a63faea01 /lib
parent83379531974a4969582f31eb193b7e962f8d5943 (diff)
libc: Move ssize_t definition to sys/types.h
There's no need to have a separate file for this, and we'll be adding other types like off_t here soon as well. Change-Id: I40629a5a0fba7af44828eaeead294e4e55844bb0 Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/minimal/include/bits/ssize_t.h35
-rw-r--r--lib/libc/minimal/include/sys/types.h15
2 files changed, 14 insertions, 36 deletions
diff --git a/lib/libc/minimal/include/bits/ssize_t.h b/lib/libc/minimal/include/bits/ssize_t.h
deleted file mode 100644
index 218253ad1..000000000
--- a/lib/libc/minimal/include/bits/ssize_t.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (c) 2016 Intel Corporation
- *
- * 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 ssize_t definition
- */
-
-#if !defined(__ssize_t_defined)
-#define __ssize_t_defined
-
-#ifdef __i386
-typedef long int ssize_t;
-#elif defined(__ARM_ARCH)
-typedef int ssize_t;
-#elif defined(__arc__)
-typedef int ssize_t;
-#else
-#error "The minimal libc library does not recognize the architecture!\n"
-#endif
-
-#endif
diff --git a/lib/libc/minimal/include/sys/types.h b/lib/libc/minimal/include/sys/types.h
index f706d35c5..b649acae5 100644
--- a/lib/libc/minimal/include/sys/types.h
+++ b/lib/libc/minimal/include/sys/types.h
@@ -17,6 +17,19 @@
#ifndef __INC_sys_types_h__
#define __INC_sys_types_h__
-#include <bits/ssize_t.h>
+#if !defined(__ssize_t_defined)
+#define __ssize_t_defined
+
+#ifdef __i386
+typedef long int ssize_t;
+#elif defined(__ARM_ARCH)
+typedef int ssize_t;
+#elif defined(__arc__)
+typedef int ssize_t;
+#else
+#error "The minimal libc library does not recognize the architecture!\n"
+#endif
+
+#endif
#endif /* __INC_sys_types_h__ */