Changeset 9b8be79 in mainline
- Timestamp:
- 2018-09-18T14:50:22Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 460ea7e
- Parents:
- 7570a95f
- git-author:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-09-14 17:49:49)
- git-committer:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-09-18 14:50:22)
- Files:
-
- 1 added
- 12 deleted
- 46 edited
Legend:
- Unmodified
- Added
- Removed
-
.gitignore
r7570a95f r9b8be79 378 378 uspace/lib/math/test-libmath 379 379 uspace/lib/pcut/test-libpcut-* 380 uspace/lib/posix/gcc.specs381 uspace/lib/posix/include/libc382 uspace/lib/posix/link.ld383 uspace/lib/posix/redefs-hide-libc-symbols.list384 380 uspace/lib/posix/test-libposix 385 381 uspace/lib/sif/test-libsif -
uspace/lib/posix/Makefile
r7570a95f r9b8be79 31 31 LIBRARY = libposix 32 32 33 EXTRA_CFLAGS = -Iinclude/ 34 35 INCLUDE_LIBC = ./include/libc 33 EXTRA_CFLAGS = -Iinclude/posix 36 34 37 35 EXPORT_FILES = \ … … 77 75 78 76 EXPORT_CPPFLAGS = \ 79 -isystem $$(HELENOS_EXPORT_ROOT)/include \ 77 -isystem $$(HELENOS_EXPORT_ROOT)/include/posix \ 78 -isystem $$(HELENOS_EXPORT_ROOT)/include/libc \ 79 -idirafter $$(HELENOS_EXPORT_ROOT)/include \ 80 80 $(COMMON_CPPFLAGS) 81 81 … … 92 92 93 93 include $(USPACE_PREFIX)/Makefile.common 94 95 $(INCLUDE_LIBC): $(shell find ../c/include -name '*.h')96 cp -r -L --remove-destination -T ../c/include $@97 find ../c/include -type f -and -not -name '*.h' -delete98 94 99 95 export: $(EXPORT_DIR)/config.mk $(EXPORT_DIR)/config.rc … … 122 118 mkdir -p $(EXPORT_DIR)/include 123 119 rm -rf $(EXPORT_DIR)/include.new 124 cp -r -L -T ./include/posix $(EXPORT_DIR)/include.new 125 cp -r -L -T ./include/libc $(EXPORT_DIR)/include.new/libc 126 cp -r -L ../c/arch/$(UARCH)/include/* $(EXPORT_DIR)/include.new/libc 120 cp -r -L -T ./include $(EXPORT_DIR)/include.new 121 cp -r -L ../c/arch/$(UARCH)/include/libarch $(EXPORT_DIR)/include.new/libc 127 122 cp -r -L $(ROOT_PATH)/abi/include/* $(EXPORT_DIR)/include.new 128 123 mkdir -p $(EXPORT_DIR)/include.new/libclui 129 124 cp -L ../clui/tinput.h $(EXPORT_DIR)/include.new/libclui 130 131 find "$(EXPORT_DIR)/include.new/libc" "$(EXPORT_DIR)/include.new/libclui" -name '*.h' -exec sed \132 -e 's:#include <:#include <libc/:' \133 -e 's:#include <libc/abi/:#include <abi/:' \134 -e 's:#include <libc/_bits/:#include <_bits/:' \135 -e 's:#include <libc/libc/:#include <libc/:' \136 -i {} \;137 find "$(EXPORT_DIR)/include.new" -name '*.h' -exec sed \138 -e 's:#include "posix/:#include ":' \139 -e 's:#include <posix/:#include <:' \140 -i {} \;141 142 125 rm -rf $(EXPORT_DIR)/include 143 126 mv $(EXPORT_DIR)/include.new $(EXPORT_DIR)/include -
uspace/lib/posix/include/posix/ctype.h
r7570a95f r9b8be79 37 37 #define POSIX_CTYPE_H_ 38 38 39 #include "libc/ctype.h"39 #include <libc/ctype.h> 40 40 41 41 /* Obsolete Functions and Macros */ -
uspace/lib/posix/include/posix/dlfcn.h
r7570a95f r9b8be79 34 34 #define POSIX_DLFCN_H_ 35 35 36 #include "libc/dlfcn.h"36 #include <libc/dlfcn.h> 37 37 38 38 #define RTLD_LAZY 1 -
uspace/lib/posix/include/posix/fcntl.h
r7570a95f r9b8be79 36 36 #define POSIX_FCNTL_H_ 37 37 38 #include "sys/types.h"38 #include <sys/types.h> 39 39 40 40 #undef O_CREAT -
uspace/lib/posix/include/posix/getopt.h
r7570a95f r9b8be79 35 35 #define POSIX_GETOPT_H 36 36 37 #include "unistd.h"38 #include "libc/getopt.h"37 #include <unistd.h> 38 #include <libc/getopt.h> 39 39 40 40 #endif -
uspace/lib/posix/include/posix/limits.h
r7570a95f r9b8be79 36 36 #define POSIX_LIMITS_H_ 37 37 38 #include "libc/limits.h"38 #include <libc/limits.h> 39 39 40 40 #undef PATH_MAX -
uspace/lib/posix/include/posix/locale.h
r7570a95f r9b8be79 36 36 #define POSIX_LOCALE_H_ 37 37 38 #include < _bits/NULL.h>38 #include <stddef.h> 39 39 40 40 #ifndef __locale_t_defined -
uspace/lib/posix/include/posix/pthread.h
r7570a95f r9b8be79 33 33 #define POSIX_PTHREAD_H_ 34 34 35 #include "time.h"35 #include <time.h> 36 36 37 37 typedef void *pthread_t; -
uspace/lib/posix/include/posix/pwd.h
r7570a95f r9b8be79 36 36 #define POSIX_PWD_H_ 37 37 38 #include "sys/types.h"38 #include <sys/types.h> 39 39 40 40 struct passwd { -
uspace/lib/posix/include/posix/signal.h
r7570a95f r9b8be79 36 36 #define POSIX_SIGNAL_H_ 37 37 38 #include "sys/types.h"39 #include < posix/ucontext.h>38 #include <sys/types.h> 39 #include <ucontext.h> 40 40 41 41 extern void __posix_default_signal_handler(int signo); -
uspace/lib/posix/include/posix/stdio.h
r7570a95f r9b8be79 37 37 #define POSIX_STDIO_H_ 38 38 39 #include "libc/stdio.h"39 #include <libc/stdio.h> 40 40 41 #include "stddef.h"42 #include "libc/io/verify.h"43 #include "sys/types.h"44 #include "stdarg.h"45 #include "limits.h"41 #include <stddef.h> 42 #include <io/verify.h> 43 #include <sys/types.h> 44 #include <stdarg.h> 45 #include <limits.h> 46 46 47 47 extern FILE *fdopen(int, const char *); -
uspace/lib/posix/include/posix/stdlib.h
r7570a95f r9b8be79 37 37 #define POSIX_STDLIB_H_ 38 38 39 #include "libc/stdlib.h"40 #include "sys/types.h"39 #include <libc/stdlib.h> 40 #include <sys/types.h> 41 41 42 #include < _bits/NULL.h>42 #include <stddef.h> 43 43 44 44 /* Environment Access */ -
uspace/lib/posix/include/posix/string.h
r7570a95f r9b8be79 44 44 */ 45 45 46 #include <_bits/NULL.h> 47 #include <_bits/size_t.h> 46 #include <stddef.h> 48 47 49 #include "libc/mem.h"48 #include <libc/mem.h> 50 49 #ifdef _HELENOS_SOURCE 51 50 #undef _HELENOS_SOURCE 52 #include "libc/string.h"51 #include <libc/string.h> 53 52 #define _HELENOS_SOURCE 54 53 #else 55 #include "libc/string.h"54 #include <libc/string.h> 56 55 #endif 57 56 -
uspace/lib/posix/include/posix/strings.h
r7570a95f r9b8be79 37 37 #define POSIX_STRINGS_H_ 38 38 39 #include "libc/types/common.h"39 #include <types/common.h> 40 40 41 41 /* Search Functions */ -
uspace/lib/posix/include/posix/sys/mman.h
r7570a95f r9b8be79 36 36 #define POSIX_SYS_MMAN_H_ 37 37 38 #include "types.h"38 #include <sys/types.h> 39 39 #include <abi/mm/as.h> 40 40 -
uspace/lib/posix/include/posix/sys/stat.h
r7570a95f r9b8be79 37 37 #define POSIX_SYS_STAT_H_ 38 38 39 #include "types.h"40 #include "../time.h"39 #include <sys/types.h> 40 #include <time.h> 41 41 42 42 /* values are the same as on Linux */ -
uspace/lib/posix/include/posix/sys/time.h
r7570a95f r9b8be79 34 34 #define POSIX_SYS_TIME_H_ 35 35 36 #include "libc/time.h"36 #include <time.h> 37 37 38 38 struct timeval { -
uspace/lib/posix/include/posix/sys/types.h
r7570a95f r9b8be79 37 37 #define POSIX_SYS_TYPES_H_ 38 38 39 #include "libc/offset.h"40 #include "libc/types/common.h"39 #include <offset.h> 40 #include <types/common.h> 41 41 42 42 typedef unsigned int ino_t; -
uspace/lib/posix/include/posix/sys/wait.h
r7570a95f r9b8be79 36 36 #define POSIX_SYS_WAIT_H_ 37 37 38 #include "types.h"38 #include <sys/types.h> 39 39 40 40 #undef WIFEXITED -
uspace/lib/posix/include/posix/time.h
r7570a95f r9b8be79 37 37 #define POSIX_TIME_H_ 38 38 39 #include "sys/types.h" 40 41 #include <_bits/NULL.h> 42 43 #include "libc/time.h" 39 #include <stddef.h> 40 #include <sys/types.h> 41 #include <libc/time.h> 44 42 45 43 #ifndef __locale_t_defined -
uspace/lib/posix/include/posix/ucontext.h
r7570a95f r9b8be79 36 36 #define POSIX_UCONTEXT_H_ 37 37 38 #include "sys/types.h"38 #include <sys/types.h> 39 39 40 40 typedef int sig_atomic_t; -
uspace/lib/posix/include/posix/unistd.h
r7570a95f r9b8be79 37 37 #define POSIX_UNISTD_H_ 38 38 39 #include "sys/types.h"40 #include "stddef.h"39 #include <stddef.h> 40 #include <sys/types.h> 41 41 42 42 #define SEEK_SET 0 -
uspace/lib/posix/src/ctype.c
r7570a95f r9b8be79 34 34 */ 35 35 36 #include "posix/ctype.h"36 #include <ctype.h> 37 37 38 38 /** -
uspace/lib/posix/src/dlfcn.c
r7570a95f r9b8be79 32 32 33 33 #include "internal/common.h" 34 #include "posix/dlfcn.h"34 #include <dlfcn.h> 35 35 36 36 int dlclose(void *handle) -
uspace/lib/posix/src/fcntl.c
r7570a95f r9b8be79 34 34 35 35 #include "internal/common.h" 36 #include "posix/fcntl.h" 37 38 #include "libc/vfs/vfs.h" 39 36 #include <fcntl.h> 37 #include <vfs/vfs.h> 40 38 #include <errno.h> 41 39 -
uspace/lib/posix/src/fnmatch.c
r7570a95f r9b8be79 43 43 */ 44 44 45 #include "libc/stdbool.h"46 #include "posix/ctype.h"47 #include "posix/string.h"48 #include "posix/stdlib.h"45 #include <stdbool.h> 46 #include <ctype.h> 47 #include <string.h> 48 #include <stdlib.h> 49 49 #include <assert.h> 50 50 51 51 #include "internal/common.h" 52 #include "posix/fnmatch.h"52 #include <fnmatch.h> 53 53 54 54 /* Returned by _match... functions. */ -
uspace/lib/posix/src/locale.c
r7570a95f r9b8be79 34 34 35 35 #include "internal/common.h" 36 #include "posix/locale.h"36 #include <locale.h> 37 37 38 38 #include <errno.h> 39 39 40 #include "posix/limits.h"41 #include "posix/string.h"40 #include <limits.h> 41 #include <string.h> 42 42 43 43 /* -
uspace/lib/posix/src/pthread/condvar.c
r7570a95f r9b8be79 33 33 */ 34 34 35 #include "posix/pthread.h"36 #include "errno.h"35 #include <pthread.h> 36 #include <errno.h> 37 37 #include "../internal/common.h" 38 38 -
uspace/lib/posix/src/pthread/keys.c
r7570a95f r9b8be79 33 33 */ 34 34 35 #include "posix/stdlib.h"36 #include "posix/pthread.h"35 #include <stdlib.h> 36 #include <pthread.h> 37 37 #include <errno.h> 38 38 #include "../internal/common.h" -
uspace/lib/posix/src/pthread/mutex.c
r7570a95f r9b8be79 33 33 */ 34 34 35 #include "posix/pthread.h"35 #include <pthread.h> 36 36 #include <errno.h> 37 37 #include "../internal/common.h" -
uspace/lib/posix/src/pthread/threads.c
r7570a95f r9b8be79 33 33 */ 34 34 35 #include "posix/pthread.h"36 #include "errno.h"37 #include "posix/stdlib.h"35 #include <pthread.h> 36 #include <errno.h> 37 #include <stdlib.h> 38 38 #include <fibril.h> 39 39 #include "../internal/common.h" -
uspace/lib/posix/src/pwd.c
r7570a95f r9b8be79 33 33 */ 34 34 35 #include "libc/stdbool.h"36 #include "posix/pwd.h"37 #include "posix/string.h"35 #include <stdbool.h> 36 #include <pwd.h> 37 #include <string.h> 38 38 #include <errno.h> 39 39 #include <assert.h> -
uspace/lib/posix/src/signal.c
r7570a95f r9b8be79 33 33 */ 34 34 35 #include "posix/signal.h"35 #include <signal.h> 36 36 #include "internal/common.h" 37 #include "posix/limits.h"38 #include "posix/stdlib.h"39 #include "posix/string.h"37 #include <limits.h> 38 #include <stdlib.h> 39 #include <string.h> 40 40 41 41 #include <errno.h> 42 42 43 #include "libc/fibril_synch.h"44 #include "libc/task.h"43 #include <fibril_synch.h> 44 #include <task.h> 45 45 46 46 /* -
uspace/lib/posix/src/stdio.c
r7570a95f r9b8be79 36 36 37 37 #include "internal/common.h" 38 #include "posix/stdio.h"38 #include <stdio.h> 39 39 40 40 #include <assert.h> … … 43 43 #include <tmpfile.h> 44 44 45 #include "posix/fcntl.h" 46 #include "posix/stdlib.h" 47 #include "posix/string.h" 48 #include "posix/sys/stat.h" 49 #include "posix/sys/types.h" 50 #include "posix/unistd.h" 51 52 #include "libc/stdio.h" 53 #include "libc/io/printf_core.h" 54 #include "libc/str.h" 55 #include "libc/malloc.h" 56 #include "libc/adt/list.h" 45 #include <fcntl.h> 46 #include <stdlib.h> 47 #include <string.h> 48 #include <sys/stat.h> 49 #include <sys/types.h> 50 #include <unistd.h> 51 52 #include <io/printf_core.h> 53 #include <str.h> 54 #include <malloc.h> 55 #include <adt/list.h> 57 56 58 57 /** -
uspace/lib/posix/src/stdlib.c
r7570a95f r9b8be79 35 35 36 36 #include "internal/common.h" 37 #include "posix/stdlib.h"37 #include <stdlib.h> 38 38 39 39 #include <errno.h> 40 40 #include <tmpfile.h> 41 41 42 #include "posix/fcntl.h"43 #include "posix/limits.h"44 #include "posix/string.h"45 #include "posix/sys/stat.h"46 #include "posix/unistd.h"47 48 #include "libc/qsort.h"49 #include "libc/str.h"50 #include "libc/vfs/vfs.h"51 #include "libc/stats.h"42 #include <fcntl.h> 43 #include <limits.h> 44 #include <string.h> 45 #include <sys/stat.h> 46 #include <unistd.h> 47 48 #include <qsort.h> 49 #include <str.h> 50 #include <vfs/vfs.h> 51 #include <stats.h> 52 52 53 53 /** -
uspace/lib/posix/src/string.c
r7570a95f r9b8be79 36 36 37 37 #include "internal/common.h" 38 #include "posix/string.h"38 #include <string.h> 39 39 40 40 #include <assert.h> … … 42 42 #include <errno.h> 43 43 44 #include "posix/limits.h" 45 #include "posix/stdlib.h" 46 #include "posix/signal.h" 47 48 #include "libc/str.h" 49 #include "libc/str_error.h" 44 #include <limits.h> 45 #include <stdlib.h> 46 #include <signal.h> 47 #include <str.h> 48 #include <str_error.h> 50 49 51 50 /** -
uspace/lib/posix/src/strings.c
r7570a95f r9b8be79 35 35 36 36 #include "internal/common.h" 37 #include "posix/strings.h"37 #include <strings.h> 38 38 39 #include "posix/string.h"40 #include "posix/ctype.h"39 #include <string.h> 40 #include <ctype.h> 41 41 42 #include "libc/mem.h"43 #include "libc/str.h"42 #include <mem.h> 43 #include <str.h> 44 44 45 45 /** -
uspace/lib/posix/src/sys/mman.c
r7570a95f r9b8be79 34 34 35 35 #include "../internal/common.h" 36 #include < posix/sys/mman.h>37 #include < posix/sys/types.h>38 #include < libc/as.h>39 #include < posix/unistd.h>36 #include <sys/mman.h> 37 #include <sys/types.h> 38 #include <as.h> 39 #include <unistd.h> 40 40 41 41 void *mmap(void *start, size_t length, int prot, int flags, int fd, -
uspace/lib/posix/src/sys/stat.c
r7570a95f r9b8be79 35 35 36 36 #include "../internal/common.h" 37 #include "posix/sys/stat.h"38 #include "libc/vfs/vfs.h"37 #include <sys/stat.h> 38 #include <vfs/vfs.h> 39 39 40 40 #include <errno.h> 41 #include "libc/mem.h"41 #include <mem.h> 42 42 43 43 /** -
uspace/lib/posix/src/sys/wait.c
r7570a95f r9b8be79 35 35 36 36 #include "../internal/common.h" 37 #include "posix/sys/wait.h"37 #include <sys/wait.h> 38 38 39 #include "libc/task.h"39 #include <task.h> 40 40 #include <assert.h> 41 41 42 42 #include <errno.h> 43 43 44 #include "posix/limits.h"45 #include "posix/signal.h"44 #include <limits.h> 45 #include <signal.h> 46 46 47 47 int __posix_wifexited(int status) -
uspace/lib/posix/src/time.c
r7570a95f r9b8be79 35 35 36 36 #include "internal/common.h" 37 #include "posix/sys/types.h"38 #include "posix/sys/time.h"39 #include "posix/time.h"40 41 #include "posix/ctype.h"37 #include <sys/types.h> 38 #include <sys/time.h> 39 #include <time.h> 40 41 #include <ctype.h> 42 42 43 43 #include <errno.h> 44 44 45 #include "posix/signal.h"45 #include <signal.h> 46 46 #include <assert.h> 47 47 48 #include "libc/async.h" 49 #include "libc/malloc.h" 50 #include "libc/task.h" 51 #include "libc/stddef.h" 52 #include "libc/time.h" 48 #include <async.h> 49 #include <malloc.h> 50 #include <task.h> 51 #include <stddef.h> 53 52 54 53 // TODO: test everything in this file -
uspace/lib/posix/src/unistd.c
r7570a95f r9b8be79 35 35 36 36 #include "internal/common.h" 37 #include "posix/unistd.h"37 #include <unistd.h> 38 38 39 39 #include <errno.h> 40 40 41 #include "posix/dirent.h"42 #include "posix/string.h"43 #include "posix/sys/types.h"44 #include "posix/fcntl.h"45 46 #include "libc/task.h"47 #include "libc/stats.h"48 #include "libc/malloc.h"49 #include "libc/vfs/vfs.h"41 #include <dirent.h> 42 #include <string.h> 43 #include <sys/types.h> 44 #include <fcntl.h> 45 46 #include <task.h> 47 #include <stats.h> 48 #include <malloc.h> 49 #include <vfs/vfs.h> 50 50 51 51 #include <libarch/config.h> -
uspace/lib/posix/test/stdio.c
r7570a95f r9b8be79 29 29 #include <pcut/pcut.h> 30 30 #include <str.h> 31 #include "posix/stdio.h"31 #include <stdio.h> 32 32 33 33 PCUT_INIT; -
uspace/lib/posix/test/stdlib.c
r7570a95f r9b8be79 29 29 #include <pcut/pcut.h> 30 30 #include <str.h> 31 #include "posix/fcntl.h"32 #include "posix/stdio.h"33 #include "posix/stdlib.h"34 #include "posix/unistd.h"31 #include <fcntl.h> 32 #include <stdio.h> 33 #include <stdlib.h> 34 #include <unistd.h> 35 35 36 36 PCUT_INIT; -
uspace/lib/posix/test/unistd.c
r7570a95f r9b8be79 29 29 #include <stdio.h> 30 30 #include <pcut/pcut.h> 31 #include "posix/fcntl.h"32 #include "posix/stdlib.h"33 #include "posix/unistd.h"31 #include <fcntl.h> 32 #include <stdlib.h> 33 #include <unistd.h> 34 34 35 35 PCUT_INIT;
Note:
See TracChangeset
for help on using the changeset viewer.