Sfoglia il codice sorgente

Add compiling instructions for Ubuntu.

Mathias Gottschlag 5 anni fa
parent
commit
362169b74e
1 ha cambiato i file con 22 aggiunte e 2 eliminazioni
  1. 22
    2
      README.md

+ 22
- 2
README.md Vedi File

@@ -9,7 +9,7 @@ Compiling the display firmware requires a rust toolchain for ARMv6m:
9 9
 
10 10
     rustup target add thumbv6m-none-eabi
11 11
 
12
-Compiling the base station software depends on the targeted board. The following steps can be used to cross-compile the software for an ARMv7 target from a Fedora host:
12
+Compiling the base station software depends on the targeted board. The following steps can be used to cross-compile the software for an ARMv7 target running Armbian from a Fedora host:
13 13
 
14 14
 1. Install the toolchain:
15 15
 
@@ -19,14 +19,34 @@ Compiling the base station software depends on the targeted board. The following
19 19
 
20 20
 2. Configure Rust to use the ARM GCC:
21 21
 
22
-        cat > ~/.cargo/config
22
+        cat > ~/.cargo/config <<_EOF
23 23
         [target.arm-unknown-linux-gnueabi]
24 24
         linker = "arm-linux-gnueabi-gcc"
25
+        rustflags = ["-Clink-args=-Wl,--dynamic-linker=/lib/ld-linux-armhf.so.3"]
26
+        _EOF
25 27
 
26 28
 3. Compile the software using the newly installed toolchain:
27 29
 
28 30
         cargo build --target=arm-unknown-linux-gnueabi
29 31
 
32
+For an Ubuntu host, the following steps can be used:
33
+
34
+1. Install the toolchain:
35
+
36
+        sudo apt-get install gcc-arm-linux-gnueabihf
37
+        rustup target add arm-unknown-linux-gnueabihf
38
+
39
+2. Configure Rust to use the ARM GCC:
40
+
41
+        cat > ~/.cargo/config <<_EOF
42
+        [target.arm-unknown-linux-gnueabihf]
43
+        linker = "arm-linux-gnueabihf-gcc"
44
+        _EOF
45
+
46
+3. Compile the software using the newly installed toolchain:
47
+
48
+        cargo build --target=arm-unknown-linux-gnueabihf
49
+
30 50
 # License
31 51
 
32 52
 The hardware contained in this repository is licensed under the [CERN Open Hardware Licence Version 2 - Weakly Reciprocal](cern_ohl_w_v2.txt), and the software is licensed under the [GNU General Public License v3](gpl-3.0.md).

Loading…
Annulla
Salva