File tree Expand file tree Collapse file tree 3 files changed +20
-26
lines changed Expand file tree Collapse file tree 3 files changed +20
-26
lines changed Original file line number Diff line number Diff line change @@ -25,14 +25,14 @@ jobs:
25
25
26
26
- name : Compiling test files
27
27
run : |
28
- /opt/avr-gcc/avr-gcc/ bin/avr-g++ --version
29
- /opt/avr-gcc/avr-gcc/ bin/avr-g++ -mmcu=atmega328p test/main1.cpp
30
- /opt/avr-gcc/avr-gcc/ bin/avr-g++ -mmcu=atmega328p test/main2.cpp
28
+ /opt/avr-gcc/bin/avr-g++ --version
29
+ /opt/avr-gcc/bin/avr-g++ -mmcu=atmega328p test/main1.cpp
30
+ /opt/avr-gcc/bin/avr-g++ -mmcu=atmega328p test/main2.cpp
31
31
32
32
# - name: Fake toolchain
33
33
# run: |
34
34
# mkdir -p /opt/avr-gcc/bin
35
- # cp $(which true) /opt/avr-gcc/avr-gcc/ bin/avr-g++
35
+ # cp $(which true) /opt/avr-gcc/bin/avr-g++
36
36
37
37
- name : Create tarball
38
38
run : |
Original file line number Diff line number Diff line change 2
2
3
3
## Installation
4
4
5
- Download the latest ` avr-gcc.tar.bz2 ` from [ Releases] ( https://github.com/modm-ext/docker-avr-gcc/releases )
5
+ Download the latest ` modm- avr-gcc.tar.bz2` from [ Releases] ( https://github.com/modm-ext/docker-avr-gcc/releases )
6
6
and unpack it to ` /opt ` :
7
7
8
8
``` sh
9
- tar xf avr-gcc.tar.bz2 --directory /opt
9
+ tar xf modm- avr-gcc.tar.bz2 --directory /opt
10
10
```
11
11
12
- Add the ` bin/ ` directories of avr-gcc and avr-binutils to your ` $PATH ` ,
12
+ Add the ` bin/ ` directory to your ` $PATH ` ,
13
13
e.g. by adding the following line to your ` ~/.bashrc ` file:
14
14
15
15
``` sh
16
- export PATH=" /opt/avr-gcc/avr-gcc/bin:/opt/avr-gcc/avr-binutils/ bin:$PATH "
16
+ export PATH=" /opt/avr-gcc/bin:$PATH "
17
17
```
18
18
19
19
## Building locally with Docker
20
20
21
21
There is a Docker image with all prerequisites for building, created from the ` Dockerfile ` in this repository.
22
- Pull and start the image from Dockerhub with:
23
-
24
- ``` sh
25
- docker run -it modm/avr-gcc-prerequisites
26
- ```
27
-
28
- Or build the image from the local ` Dockerfile ` and start it:
22
+ Build the image from the local ` Dockerfile ` and start it:
29
23
30
24
``` sh
31
25
docker build --tag avr-gcc-prerequisites:local .
@@ -35,14 +29,14 @@ docker run -it avr-gcc-prerequisites:local
35
29
Inside the Docker container get this repository
36
30
37
31
``` sh
38
- git clone https://github.com/modm-ext/docker- avr-gcc.git
32
+ git clone https://github.com/modm-io/ avr-gcc.git
39
33
```
40
34
41
35
Run the build.sh script
42
36
43
37
``` sh
44
- cd docker- avr-gcc
45
- time ./build.sh
38
+ cd avr-gcc
39
+ ./build.sh
46
40
```
47
41
48
42
The toolchain will be in ` /opt/avr-gcc ` .
Original file line number Diff line number Diff line change @@ -29,25 +29,25 @@ patch -g 0 -f -p0 -i ../../avr-size.patch
29
29
mkdir build && cd build
30
30
# configure and make
31
31
../configure \
32
- --prefix=${INSTALL} /avr-binutils/ \
33
32
--target=avr \
33
+ --prefix=${INSTALL} / \
34
34
--disable-nls \
35
35
--disable-werror
36
36
make -j${cores}
37
37
make install
38
38
39
39
# prepend path of newly compiled avr-binutils
40
- export PATH=${INSTALL} /avr-binutils/ bin:$PATH
40
+ export PATH=${INSTALL} /bin:$PATH
41
41
42
42
cd ${root}
43
43
cd ${SRC} /gcc-${VERSION_GCC}
44
44
mkdir build && cd build
45
45
../configure \
46
46
--target=avr \
47
- --prefix=${INSTALL} /avr-gcc/ \
48
- --with-ld=${INSTALL} /avr-binutils/ bin/avr-ld \
49
- --with-as=${INSTALL} /avr-binutils/ bin/avr-as \
50
- --libdir=${INSTALL} /avr-gcc/avr /lib \
47
+ --prefix=${INSTALL} / \
48
+ --with-ld=${INSTALL} /bin/avr-ld \
49
+ --with-as=${INSTALL} /bin/avr-as \
50
+ --libdir=${INSTALL} /avr/lib \
51
51
--enable-languages=c,c++ \
52
52
--disable-nls \
53
53
--disable-libssp \
@@ -62,15 +62,15 @@ make -j${cores}
62
62
make install
63
63
64
64
# prepend path of newly compiled avr-gcc
65
- export PATH=${INSTALL} /avr-gcc /bin:$PATH
65
+ # export PATH=${INSTALL}/bin:$PATH
66
66
67
67
cd ${root}
68
68
cd ${SRC} /avr-libc-${VERSION_LIBC}
69
69
patch -g 0 -f -p0 -i ../../avr-libc-add-mcu-atmega168pb.patch
70
70
build=` ./config.guess`
71
71
./configure \
72
72
--build=${build} \
73
- --prefix=${INSTALL} /avr-gcc \
73
+ --prefix=${INSTALL} \
74
74
--host=avr
75
75
make install -j${cores}
76
76
You can’t perform that action at this time.
0 commit comments