You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add dev container, fix bugs in compiler setup (#20)
Features added:
* Add clang include directory to cfg
* Adding statiging release
* Add dev container
* Add runtime library interface
* Adding first version of unistd.c
* Adding print for exit code at debug exit
Bug Fixes:
* Fix bugs in compiler cfg template
* Fix namecmp to recognize substrings as non equal
* Fix abi thread local issue, add test program build to top level cmake project
* Fix makro in cmake template
* Fix debug to handle unlimited number of input items or input-/outputsets
# install packages required packages to get things running
11
+
RUN apt update
12
+
RUN apt-get install -y wget gpg
13
+
RUN apt-get install -y lsb-release
14
+
RUN apt-get install -y software-properties-common
15
+
RUN apt-get install -y gcc g++ # clang uses gcc to interface with the linker
16
+
17
+
# download initial clang
18
+
RUN wget https://apt.llvm.org/llvm.sh -O ~/llvm.sh
19
+
RUN chmod +x ~/llvm.sh
20
+
RUN ~/llvm.sh
21
+
RUN ln -s /usr/bin/ld.lld-19 /usr/bin/ld.lld
22
+
RUN rm -r /usr/include/*
23
+
24
+
# download and set up dandelionSDK
25
+
RUN wget https://github.com/eth-easl/dandelionSDK/releases/download/${VERSION}/dandelion_sdk_${BUILD}_${PLATFORM}_${TARGET_ARCH}.tar.gz -O ~/dandelionSDK.tar.gz
26
+
RUN tar -xzf ~/dandelionSDK.tar.gz -C ~/
27
+
RUN ~/dandelion_sdk/create-compiler.sh -d -c clang-19
Copy file name to clipboardExpand all lines: README.md
+28Lines changed: 28 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,6 +30,12 @@ dumping outputs to the terminal when terminating.
30
30
Fixing it is on our agenda, but not of highest priority.
31
31
If you want to use Dandelion and need C++ support for aarch64, please get in touch and we may be able to provide experimental builds or bump the priority to get it fixed.
32
32
33
+
### Other parameters
34
+
35
+
Additionally, the following parameters can be used to influence system behaviour.
36
+
37
+
-`PAGE_SIZE` sets the page size the runtime will assume to optimize allocation etc. and makes available to others to depend on. Should be a multiple of sizeof(size_t) for the platform compiled for.
38
+
33
39
## Interface expectations
34
40
### libc
35
41
When using libc or any system on top of it values can be fed into stdin, argv and environ by specifying a input set called "stdio".
@@ -97,6 +103,28 @@ For newlib to be built correctly the autoconf version 2.69.
97
103
This also enables the build of the in memory file system,
98
104
which can also be built without the other newlib builds by setting `-DDANDELION_FS=ON`
99
105
106
+
## Build Container
107
+
We also provide a docker file to construct a build container with the correct tools set up in them.
108
+
To create the container with docker use the following command:
Use the `--no-cache` if you want to rebuild the container from scratch.
113
+
114
+
To use the container use the following command:
115
+
```
116
+
docker run --rm -it --mount type=bind,src=<path to your source folder>,dst=/workspace --workdir=/workspace dandelion_dev_docker:latest bash
117
+
```
118
+
You will enter the container and your source folder will be mounted at `/workspace`.
119
+
The default clang and clang++ are set up to compile for dandelion debug on the machine you are running.
120
+
If you want a different target, you can set build, platform and architecture in the docker file.
121
+
Files you build in the container will be visible outside, as long as they are in the workspace directory.
122
+
123
+
To add more tools to the build environment, they can be added to the docker file, or you can base your container build on our docker file by importing it with:
124
+
```
125
+
FROM dandelion_dev_docker:latest
126
+
```
127
+
100
128
## Freestanding
101
129
The GCC/Clang standard expects 4 functions to allways be provided in any environment (even freestanding), which allow the compiler to always just insert them.
0 commit comments