-
Notifications
You must be signed in to change notification settings - Fork 352
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add daita
as a Cargo cfg variable
#6231
Conversation
cade6d7
to
82855d4
Compare
daf0938
to
f14fd21
Compare
0ea1234
to
d5be080
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 29 of 53 files at r1, 23 of 33 files at r3, 8 of 10 files at r4, 1 of 1 files at r5, all commit messages.
Reviewable status: 61 of 64 files reviewed, 3 unresolved discussions (waiting on @hulthe and @Serock3)
build.sh
line 168 at r3 (raw file):
if [[ "$(uname -s)" == "MINGW"* || "$(uname -s)" == "Linux" ]]; then CARGO_ARGS+=(--features daita) fi
This should be removed, otherwise build.sh
will fail when compiling due to the daita feature not existing on Linux and Windows 😊
Code quote:
# Enable DAITA on supported platforms
if [[ "$(uname -s)" == "MINGW"* || "$(uname -s)" == "Linux" ]]; then
CARGO_ARGS+=(--features daita)
fi
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 6 of 7 files at r2, 2 of 33 files at r3, all commit messages.
Reviewable status: 63 of 64 files reviewed, 3 unresolved discussions (waiting on @Serock3)
.github/workflows/cargo-vendor.yml
line 24 at r2 (raw file):
run: | git config --global --add safe.directory '*' git submodule update --init --depth=1 dist-assets/binaries wireguard-go-rs/libwg
shouldn't this be wireguard-go-rs/libwg/wireguard-go?
.github/workflows/desktop-e2e.yml
line 164 at r5 (raw file):
uses: actions/checkout@v2 - name: Checkout submodules # TODO: should this specify a path? We don't want to pull `wireguard-go`
better to have it and not need it? 🤷
it's probably a non-issue to just keep this
dc84098
to
710c4bc
Compare
f14fd21
to
04ba931
Compare
710c4bc
to
6f1e290
Compare
59c389f
to
a540b5e
Compare
a540b5e
to
c0bf274
Compare
Replace `cargo:key=value` with `cargo::key=value`
Instead of gating `daita` per platform in the `build-wireguard-go.sh`, accept an argument which says whether DAITA support should be enabled.
Include `maybenot` as a submodule of our `wireguard-go` fork with DAITA-support. Use this submodule to build the `maybenot-ffi` on platforms which should build `wireguard-go` with DAITA (not windows). The main benefit of doing this is that Windows target no longer needs to clone the `wireguard-go` submodule.
c0bf274
to
00f210d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 5 files at r9.
Reviewable status: 61 of 78 files reviewed, 4 unresolved discussions (waiting on @dlon and @hulthe)
.github/workflows/desktop-e2e.yml
line 164 at r5 (raw file):
Previously, dlon (David Lönnhager) wrote…
+1
I agree
.github/workflows/rust-unused-dependencies.yml
line 92 at r7 (raw file):
Previously, dlon (David Lönnhager) wrote…
The macOS and Windows jobs can probably be merged if just the
Install go
step is skipped on Windows.
Done
wireguard-go-rs/libwg/libwg.a
line at r7 (raw file):
Previously, dlon (David Lönnhager) wrote…
This should probably be added to
.gitignore
? And completely removed from the git history as well (so it's not needlessly fetched).
Done (I think). Please verify that it is actually completely nuked from the git history 😊
4ebea97
to
6af681a
Compare
Due to reasons outlined here #6202 (review), It may be problematic to gate DAITA behind a cargo feature. This is an alternative approach which avoids the use of features.
This change is