/bionic/libc/tools/ |
D | bionic_utils.py | 40 def find_dir_of(path): argument 43 if len(path) > 1 and path[-1] == '/': 44 path = path[:-1] 47 d = os.path.dirname(path) 59 path = from_path 60 if path == None: 61 path = find_dir_of(sys.argv[0]) 62 D("this script seems to be located in: %s" % path) 65 if path == "": 66 path = "." [all …]
|
D | generate-NOTICE.py | 17 def IsUninteresting(path): argument 18 path = path.lower() 19 …if path.endswith(".mk") or path.endswith(".py") or path.endswith(".pyc") or path.endswith(".txt") … 21 if path.endswith("/notice") or path.endswith("/readme") or path.endswith("/caveats"): 23 if path.endswith("/tzdata") or path.endswith("/zoneinfo/generate"): 113 path = os.path.join(directory, filename) variable 114 if IsUninteresting(path): 119 content = open(path, 'r').read().decode('utf-8') 122 sys.stderr.write('warning: bad UTF-8 in %s\n' % path) 123 content = open(path, 'r').read().decode('iso-8859-1') [all …]
|
D | gensyscalls.py | 8 import sys, os.path, glob, re, commands, filecmp, shutil 31 def make_dir( path ): argument 32 path = os.path.abspath(path) 33 if not os.path.exists(path): 34 parent = os.path.dirname(path) 37 os.mkdir(path) 40 dir = os.path.dirname( bionic_temp + relpath ) 316 def scan_linux_unistd_h(self, fp, path): argument 319 for line in open(path): 351 path = "arch-%s/syscalls.mk" % arch [all …]
|
/bionic/libc/kernel/tools/ |
D | utils.py | 45 return os.path.basename(sys.argv[0]) 48 return os.path.dirname(sys.argv[0]) 53 path = from_path 54 if path == None: 55 path = os.path.realpath(sys.argv[0]) 56 path = os.path.dirname(path) 57 D("this script seems to be located in: %s" % path) 60 D("probing "+path) 61 if path == "": 64 file = path + "/" + target_file [all …]
|
D | clean_header.py | 10 def cleanupFile( path, original_path): argument 15 src_path = path 17 if not os.path.exists(src_path): 19 panic( "file does not exist: '%s'\n" % path ) 20 sys.stderr.write( "warning: file does not exit: %s\n" % path ) 23 if not os.path.isfile(src_path): 25 panic( "path is not a file: '%s'\n" % path ) 26 sys.stderr.write( "warning: not a file: %s\n" % path ) 29 if os.path.commonprefix( [ src_path, original_path ] ) != original_path: 31 panic( "file is not in 'original' directory: %s\n" % path ); [all …]
|
D | kernel.py | 7 import sys, cpp, re, os.path, string, time 89 hdr_dir = os.path.realpath(os.path.dirname(from_file)) 90 hdr_dir = hdr_dir.replace("%s/" % os.path.realpath(kernel_root), 106 def parseFile(self, path, arch=None, kernel_root=None): argument 108 if not os.path.exists(path): 115 f = open(path, "rt") 117 print "!!! can't read '%s'" % path 128 if verboseSearch: print "::: " + path 131 if verboseSearch: print "*** " + path 133 list = cpp.BlockParser().parseFile(path) [all …]
|
D | update_all.py | 19 """ % { "progname" : os.path.basename(sys.argv[0]) } 36 if not os.path.isdir(original_dir): 40 if not os.path.isdir(original_dir): 48 base, ext = os.path.splitext(file) 55 b.readDir( os.path.normpath( progdir + "/../arch-%s" % arch ) ) 57 b.readDir( os.path.normpath( progdir + "/../common" ) ) 62 for path in sources: 63 dst_path, newdata = clean_header.cleanupFile(path, original_dir) 76 …str = "cleaning: %-*s -> %-*s (%s)" % ( 35, "<original>" + path[len(original_dir):], 35, dst_path,…
|
D | find_headers.py | 61 if not os.path.exists(kernel_root): 65 if not os.path.isdir(kernel_root): 69 if not os.path.isdir(kernel_root+"/include/linux"): 74 if not os.path.exists(wanted_config): 78 if not os.path.isfile(wanted_config): 85 if os.path.exists("%s/arch/%s/include/asm" % (kernel_root, archdir)): 96 if os.path.isdir(kernel_root+"/asm"): 120 def parse_file(path, parser): argument 122 parser.parseFile(path)
|
D | defaults.py | 19 kernel_original_path = os.path.normpath( find_program_dir() + '/../../../../external/kernel-headers… 23 kernel_cleaned_path = os.path.normpath( find_program_dir() + '/..' )
|
D | find_users.py | 48 def parse_file(path, parser): argument 49 parser.parseFile(path)
|
/bionic/libc/bionic/ |
D | libgen.cpp | 42 char* basename(const char* path) { in basename() argument 44 int rc = basename_r(path, basename_tls_buffer, basename_tls_buffer_size); in basename() 48 char* dirname(const char* path) { in dirname() argument 50 int rc = dirname_r(path, dirname_tls_buffer, dirname_tls_buffer_size); in dirname() 54 int basename_r(const char* path, char* buffer, size_t buffer_size) { in basename_r() argument 61 if (path == NULL || *path == '\0') { in basename_r() 68 endp = path + strlen(path) - 1; in basename_r() 69 while (endp > path && *endp == '/') { in basename_r() 74 if (endp == path && *endp == '/') { in basename_r() 82 while (startp > path && *(startp - 1) != '/') { in basename_r() [all …]
|
D | statfs.c | 32 int statfs(const char* path, struct statfs* stat) in statfs() argument 34 return __statfs64(path, sizeof(struct statfs), stat); in statfs()
|
D | ftok.c | 32 key_t ftok(const char* path, int id) in ftok() argument 36 if ( lstat(path, &st) < 0 ) in ftok()
|
/bionic/libc/stdio/ |
D | mktemp.c | 45 mkstemps(char *path, int slen) in mkstemps() argument 49 return (_gettemp(path, &fd, 0, slen) ? fd : -1); in mkstemps() 53 mkstemp(char *path) in mkstemp() argument 57 return (_gettemp(path, &fd, 0, 0) ? fd : -1); in mkstemp() 61 mkdtemp(char *path) in mkdtemp() argument 63 return(_gettemp(path, (int *)NULL, 1, 0) ? path : (char *)NULL); in mkdtemp() 69 _mktemp(char *path) in _mktemp() argument 71 return(_gettemp(path, (int *)NULL, 0, 0) ? path : (char *)NULL); in _mktemp() 78 mktemp(char *path) in mktemp() argument 80 return(_mktemp(path)); in mktemp() [all …]
|
/bionic/libc/include/sys/ |
D | xattr.h | 39 extern int setxattr(const char *path, const char *name, const void *value, size_t size, int flags); 40 extern int lsetxattr(const char *path, const char *name, const void *value, size_t size, int flags); 43 extern ssize_t getxattr(const char *path, const char *name, void *value, size_t size); 44 extern ssize_t lgetxattr(const char *path, const char *name, void *value, size_t size); 46 extern ssize_t listxattr(const char *path, char *list, size_t size); 47 extern ssize_t llistxattr(const char *path, char *list, size_t size); 50 extern int removexattr(const char *path, const char *name); 51 extern int lremovexattr(const char *path, const char *name);
|
D | ipc.h | 37 extern key_t ftok(const char* path, int id);
|
/bionic/libc/include/ |
D | libgen.h | 37 extern char* dirname (const char* path); 38 extern char* basename(const char* path); 52 extern int dirname_r(const char* path, char* buffer, size_t bufflen); 53 extern int basename_r(const char* path, char* buffer, size_t bufflen);
|
D | fcntl.h | 46 extern int open(const char* path, int mode, ...); 47 extern int openat(int fd, const char* path, int mode, ...); 50 extern int creat(const char* path, mode_t mode);
|
/bionic/libc/upstream-netbsd/libc/compat-43/ |
D | creat.c | 46 creat(const char *path, mode_t mode) in creat() argument 49 _DIAGASSERT(path != NULL); in creat() 51 return(open(path, O_WRONLY|O_CREAT|O_TRUNC, mode)); in creat()
|
/bionic/libc/upstream-netbsd/libc/gen/ |
D | utime.c | 50 utime(const char *path, const struct utimbuf *times) in utime() argument 54 _DIAGASSERT(path != NULL); in utime() 64 return (utimes(path, tvp)); in utime()
|
/bionic/libc/tools/zoneinfo/ |
D | generate | 14 bionic_libc_tools_zoneinfo_dir = os.path.realpath(os.path.dirname(sys.argv[0])) 15 bionic_libc_tools_dir = os.path.dirname(bionic_libc_tools_zoneinfo_dir) 16 bionic_libc_dir = os.path.dirname(bionic_libc_tools_dir) 17 bionic_dir = os.path.dirname(bionic_libc_dir) 20 if not os.path.isdir(bionic_libc_tools_zoneinfo_dir): 23 if not os.path.isdir(bionic_libc_zoneinfo_dir):
|
/bionic/libc/private/ |
D | ScopedReaddir.h | 24 ScopedReaddir(const char* path) { in ScopedReaddir() argument 25 dir_ = opendir(path); in ScopedReaddir()
|
/bionic/libc/upstream-freebsd/lib/libc/stdlib/ |
D | realpath.c | 51 realpath(const char * __restrict path, char * __restrict resolved) in realpath() argument 60 if (path == NULL) { in realpath() 64 if (path[0] == '\0') { in realpath() 76 if (path[0] == '/') { in realpath() 79 if (path[1] == '\0') in realpath() 82 left_len = strlcpy(left, path + 1, sizeof(left)); in realpath() 94 left_len = strlcpy(left, path, sizeof(left)); in realpath()
|
/bionic/libc/unistd/ |
D | exec.c | 140 char *bp, *cur, *path, buf[MAXPATHLEN]; in execvp() local 153 cur = path = NULL; in execvp() 159 if (!(path = getenv("PATH"))) in execvp() 160 path = _PATH_DEFPATH; in execvp() 161 len = strlen(path) + 1; in execvp() 167 strlcpy(cur, path, len); in execvp() 168 path = cur; in execvp()
|
/bionic/tests/ |
D | dlfcn_test.cpp | 155 char path[PATH_MAX]; in TEST() local 156 snprintf(path, sizeof(path), "/proc/%d/maps", getpid()); in TEST() 158 FILE* fp = fopen(path, "r"); in TEST() 163 char* path = strchr(line, '/'); in TEST() local 164 if (path != NULL && strcmp(executable_path, path) == 0) { in TEST()
|