auto import from //branches/cupcake/...@130745
This commit is contained in:
@@ -97,6 +97,9 @@ typedef volatile int pthread_once_t;
|
||||
#define PTHREAD_PROCESS_PRIVATE 0
|
||||
#define PTHREAD_PROCESS_SHARED 1
|
||||
|
||||
#define PTHREAD_SCOPE_SYSTEM 0
|
||||
#define PTHREAD_SCOPE_PROCESS 1
|
||||
|
||||
/*
|
||||
* Prototypes
|
||||
*/
|
||||
@@ -128,6 +131,9 @@ int pthread_attr_getstack(pthread_attr_t const * attr, void ** stackaddr, size_t
|
||||
int pthread_attr_setguardsize(pthread_attr_t * attr, size_t guard_size);
|
||||
int pthread_attr_getguardsize(pthread_attr_t const * attr, size_t * guard_size);
|
||||
|
||||
int pthread_attr_setscope(pthread_attr_t *attr, int scope);
|
||||
int pthread_attr_getscope(pthread_attr_t const *attr);
|
||||
|
||||
int pthread_getattr_np(pthread_t thid, pthread_attr_t * attr);
|
||||
|
||||
int pthread_create(pthread_t *thread, pthread_attr_t const * attr,
|
||||
|
||||
@@ -82,9 +82,8 @@ extern size_t strspn(const char *, const char *);
|
||||
|
||||
extern char* strsignal(int sig);
|
||||
|
||||
/* Just declared to make libstdc++-v3 happy. */
|
||||
extern int strcoll (const char *, const char *);
|
||||
extern size_t strxfrm (char *, const char *, size_t);
|
||||
extern int strcoll(const char *, const char *);
|
||||
extern size_t strxfrm(char *, const char *, size_t);
|
||||
|
||||
__END_DECLS
|
||||
|
||||
|
||||
@@ -71,6 +71,10 @@ struct stat {
|
||||
unsigned long long st_ino;
|
||||
};
|
||||
|
||||
extern int chmod(const char *, mode_t);
|
||||
extern int fchmod(int, mode_t);
|
||||
extern int mkdir(const char *, mode_t);
|
||||
|
||||
extern int stat(const char *, struct stat *);
|
||||
extern int fstat(int, struct stat *);
|
||||
extern int lstat(const char *, struct stat *);
|
||||
|
||||
@@ -56,7 +56,7 @@ extern int utimes(const char *, const struct timeval *);
|
||||
#define timeradd(a, b, res) \
|
||||
do { \
|
||||
(res)->tv_sec = (a)->tv_sec + (b)->tv_sec; \
|
||||
(res)->tv_usec = (a)->tv_usec - (b)->tv_usec; \
|
||||
(res)->tv_usec = (a)->tv_usec + (b)->tv_usec; \
|
||||
if ((res)->tv_usec >= 1000000) { \
|
||||
(res)->tv_usec -= 1000000; \
|
||||
(res)->tv_sec += 1; \
|
||||
|
||||
@@ -65,6 +65,7 @@ typedef __kernel_nlink_t nlink_t;
|
||||
#define _OFF_T_DEFINED_
|
||||
typedef __kernel_off_t off_t;
|
||||
typedef __kernel_loff_t loff_t;
|
||||
typedef loff_t off64_t; /* GLibc-specific */
|
||||
|
||||
typedef __kernel_pid_t pid_t;
|
||||
|
||||
|
||||
54
libc/include/time64.h
Normal file
54
libc/include/time64.h
Normal file
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
|
||||
Copyright (c) 2007-2008 Michael G Schwern
|
||||
|
||||
This software originally derived from Paul Sheer's pivotal_gmtime_r.c.
|
||||
|
||||
The MIT License:
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
|
||||
Origin: http://code.google.com/p/y2038
|
||||
Modified for Bionic by the Android Open Source Project
|
||||
|
||||
*/
|
||||
#ifndef TIME64_H
|
||||
#define TIME64_H
|
||||
|
||||
#include <time.h>
|
||||
#include <stdint.h>
|
||||
|
||||
typedef int64_t time64_t;
|
||||
|
||||
struct tm *gmtime64_r (const time64_t *, struct tm *);
|
||||
struct tm *localtime64_r (const time64_t *, struct tm *);
|
||||
struct tm *gmtime64 (const time64_t *);
|
||||
struct tm *localtime64 (const time64_t *);
|
||||
|
||||
char *asctime64 (const struct tm *);
|
||||
char *asctime64_r (const struct tm *, char *);
|
||||
|
||||
char *ctime64 (const time64_t*);
|
||||
char *ctime64_r (const time64_t*, char*);
|
||||
|
||||
time64_t timegm64 (const struct tm *);
|
||||
time64_t mktime64 (const struct tm *);
|
||||
time64_t timelocal64 (const struct tm *);
|
||||
|
||||
#endif /* TIME64_H */
|
||||
@@ -34,6 +34,7 @@
|
||||
#include <sys/select.h>
|
||||
#include <sys/sysconf.h>
|
||||
#include <linux/capability.h>
|
||||
#include <pathconf.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
@@ -111,9 +112,6 @@ extern int link(const char *, const char *);
|
||||
extern int unlink(const char *);
|
||||
extern int chdir(const char *);
|
||||
extern int fchdir(int);
|
||||
extern int chmod(const char *, mode_t);
|
||||
extern int fchmod(int, mode_t);
|
||||
extern int mkdir(const char *, mode_t);
|
||||
extern int rmdir(const char *);
|
||||
extern int pipe(int *);
|
||||
extern int chroot(const char *);
|
||||
|
||||
Reference in New Issue
Block a user