|
Name |
|
Date |
Size |
#Lines |
LOC |
| .. | | - | - |
| .cargo/ | H | - | - | 2 | 2 |
| .vscode/ | H | - | - | 24 | 23 |
| core_io/ | H | - | - | 154,744 | 141,142 |
| include/ | H | - | - | 1,491 | 1,112 |
| openlibm/ | H | - | - | 49,920 | 28,777 |
| posix-regex/ | H | - | - | 1,387 | 1,213 |
| pthreads-emb/ | H | - | - | 50,945 | 25,835 |
| ralloc/ | H | - | - | 5,070 | 2,845 |
| src/ | H | - | - | 39,769 | 30,452 |
| tests/ | H | - | - | 8,469 | 6,920 |
| .editorconfig | H A D | 07-Aug-2020 | 91 | 8 | 6 |
| .gitignore | H A D | 02-Aug-2023 | 79 | 10 | 9 |
| .gitlab-ci.yml | H A D | 01-Mar-2023 | 1,016 | 57 | 48 |
| .gitmodules | H A D | 05-Aug-2023 | 786 | 20 | 19 |
| CONTRIBUTING.md | H A D | 22-Feb-2019 | 4.8 KiB | 124 | 89 |
| Cargo.toml | H A D | 24-Oct-2023 | 1.4 KiB | 61 | 48 |
| LICENSE | H A D | 08-Mar-2018 | 1 KiB | 22 | 17 |
| Makefile | H A D | 13-May-2023 | 7.6 KiB | 239 | 174 |
| README.md | H A D | 01-Apr-2023 | 1.6 KiB | 45 | 33 |
| Xargo.toml | H A D | 28-May-2020 | 21 | 2 | 1 |
| bindgen_transform.sh | H A D | 09-Mar-2018 | 186 | 5 | 4 |
| build.rs | H A D | 17-Apr-2023 | 2.5 KiB | 80 | 65 |
| ci.sh | H A D | 18-Feb-2020 | 115 | 12 | 9 |
| fmt.sh | H A D | 27-Aug-2018 | 68 | 4 | 1 |
| init_dragonos_toolchain.sh | H A D | 11-May-2023 | 1.8 KiB | 68 | 59 |
| redoxer.sh | H A D | 01-Mar-2023 | 272 | 19 | 13 |
| renamesyms.sh | H A D | 19-Aug-2022 | 748 | 28 | 19 |
| rust-toolchain.toml | H A D | 11-Feb-2023 | 69 | 4 | 3 |
| rustfmt.toml | H A D | 28-Jul-2019 | 574 | 25 | 24 |
README.md
1# relibc ![build](https://travis-ci.org/redox-os/relibc.svg?branch=master)
2relibc is a portable POSIX C standard library written in Rust. It is under heavy development, and currently supports Redox, Linux and DragonOS.
3
4The motivation for this project is twofold: Reduce issues the redox crew was having with newlib, and create a safer alternative to a C standard library written in C. It is mainly designed to be used under redox, as an alternative to newlib, but it also supports linux syscalls via the [sc](https://crates.io/crates/sc) crate.
5
6## Building
7Just run `make all`.
8
9### Build for DragonOS
10
11You can follow the instructions to build relibc for DragonOS:
12
13```bash
14mkdir -p sysroot/usr
15make -j $(nproc) && DESTDIR=sysroot/usr make install -j $(nproc)
16```
17
18### Issues
19#### I'm building for my own platform which I run, and am getting `x86_64-linux-gnu-ar: command not found` (or similar)
20The Makefile expects the gnu compiler tools prefixed with the platform specifier, as would be present when you'd install a cross compiler. Since you are building for your own platform, some distros (like Manjaro) don't install/symlink the prefixed executables.
21An easy fix would be to replace the corresponding lines in the Makefile, e.g.
22```diff
23 ifeq ($(TARGET),x86_64-unknown-linux-gnu)
24 export CC=x86_64-linux-gnu-gcc
25- export LD=x86_64-linux-gnu-ld
26- export AR=x86_64-linux-gnu-ar
27+ export LD=ld
28+ export AR=ar
29 export OBJCOPY=x86_64-linux-gnu-objcopy
30 endif
31```
32
33### [Contributing](CONTRIBUTING.md)
34
35## Supported OSes
36
37 - Redox OS
38 - Linux
39 - DragonOS
40
41## Supported architectures
42
43 - x86\_64
44 - Aarch64
45