Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Barugon committed Mar 22, 2023
1 parent 07c94db commit 5f97c20
Showing 1 changed file with 1 addition and 32 deletions.
33 changes: 1 addition & 32 deletions BUILD.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,8 @@

## Linux

The purpose of this is to create an executable that will work across most distributions, even if they have an older version of glibc.

> Note: this may not be needed anymore.
```bash
cargo install cross
```

- Create a `Dockerfile` in the project folder

```Dockerfile
FROM docker.io/library/ubuntu:20.04
RUN DEBIAN_FRONTEND=noninteractive apt update && apt -y install tzdata && apt -y install clang pkg-config cmake libfontconfig-dev libx11-xcb-dev libxcb-render-util0-dev libxcb-shape0-dev libxcb-xfixes0-dev
```

- Create a `Cross.toml` file in the project folder

```toml
[target.x86_64-unknown-linux-gnu]
image = "docker.io/library/ubuntu:20.04"
```

- Build the docker image

```bash
sudo dnf install podman
podman build -t docker.io/library/ubuntu:20.04 .
```

- Build the project

```bash
cross build --release --target=x86_64-unknown-linux-gnu
cargo build --release --target=x86_64-unknown-linux-gnu
```

## Windows
Expand Down

0 comments on commit 5f97c20

Please sign in to comment.