Compare commits

..

No commits in common. "3c614f48bd10116cc8230ab41089e031e02e23c2" and "c91e7a198929e754914faf61751a0a0a3138ee64" have entirely different histories.

5 changed files with 2 additions and 3048 deletions

View file

@ -1,39 +0,0 @@
steps:
build:
image: woodpeckerci/plugin-docker-buildx
settings:
dry-run: true
repo: git.merp.digital/${CI_REPO_OWNER}/${CI_REPO_NAME}
platforms: linux/amd64
registry: git.merp.digital
when:
- event: push
branch:
exclude: [develop, master]
publish-nightly:
image: woodpeckerci/plugin-docker-buildx
settings:
repo: git.merp.digital/${CI_REPO_OWNER}/${CI_REPO_NAME}
platforms: linux/amd64
registry: git.merp.digital
tags: develop
username: ${CI_REPO_OWNER}
password:
from_secret: cb_token
when:
- event: push
branch: develop
publish-release:
image: woodpeckerci/plugin-docker-buildx
settings:
repo: git.merp.digital/${CI_REPO_OWNER}/${CI_REPO_NAME}
platforms: linux/amd64
registry: git.merp.digital
tags: ["latest", "${CI_COMMIT_TAG}"]
username: ${CI_REPO_OWNER}
password:
from_secret: cb_token
when:
- event: tag

View file

@ -1,9 +0,0 @@
FROM ghcr.io/cross-rs/mips-unknown-linux-musl:latest
RUN apt update && apt install -y git wget subversion build-essential libncurses5-dev zlib1g-dev gawk flex quilt git-core unzip libssl-dev python-dev python-pip libxml-parser-perl time
RUN git clone https://github.com/OnionIoT/source.git
COPY openwrt-build-config source/.config
ENV FORCE_UNSAFE_CONFIGURE=1
RUN cd source && make -j12

View file

@ -1,6 +1,6 @@
MIT License
Copyright (c) 2024 zenermerps (Andreas Mieke)
Copyright (c) 2024 zenermerps
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

View file

@ -1,35 +1,3 @@
# onion2s-build
Docker image for cross to build rust packages for the Onion Omega 2S(+)
## Prerequisites
You will need to have the rustup version of cargo installed, for more information look at the official Rust documentation. You need Docker (or Podman) up and running, and you need to install cross with:
```sh
cargo install cross --git https://github.com/cross-rs/cross
```
## Configuration
To compile for the Onion Omega 2S(+) you need to add the following configuration:
Cargo.toml:
```toml
[workspace.metadata.cross.target.mipsel-unknown-linux-musl]
image = "git.merp.digital/zenermerps/onion2s-build:latest"
build-std = ["std"]
```
.cargo/config:
```toml
[target.mipsel-unknown-linux-musl]
linker = "/source/staging_dir/toolchain-mipsel_24kc_gcc-7.3.0_musl/bin/mipsel-openwrt-linux-musl-gcc"
```
_Note_: cargo will complain that this location is deprecated, however (at least on macOS) moving the file to the suggested location results in an error about `Cargo.toml` not being found (while a `cargo.toml` exists). I assume this is due to some discrepancy between macOS's case-insensitive vs Linux's case-sensistive file system.
## Build
You then can use `cross` as replacement for `cargo`, you need to specify the target with: `--target mipsel-unknown-linux-musl`, this is all you need to compile for the Onion Omega 2S(+).
For example:
```sh
cross build --release --target mipsel-unknown-linux-musl
```
Docker image for cross to build rust packages for the Onion Omega 2S(+)

File diff suppressed because it is too large Load diff