* [gentoo-commits] repo/gentoo:master commit in: app-misc/anki/files/23.12.1/
@ 2024-01-21 10:00 Sam James
0 siblings, 0 replies; 2+ messages in thread
From: Sam James @ 2024-01-21 10:00 UTC (permalink / raw
To: gentoo-commits
commit: f62ed792c828d52354e1d66437728dbecdd6021c
Author: Lucio Sauer <watermanpaint <AT> posteo <DOT> net>
AuthorDate: Tue Jan 9 12:56:18 2024 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Jan 21 10:00:25 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f62ed792
app-misc/anki/files/23.12.1: add links to patch origins where applicable
- Reword pseudo-venv.patch for clarity.
Signed-off-by: Lucio Sauer <watermanpaint <AT> posteo.net>
Signed-off-by: Sam James <sam <AT> gentoo.org>
app-misc/anki/files/23.12.1/configure-offline-build.patch | 1 +
app-misc/anki/files/23.12.1/ninja-gentoo-setup.patch | 1 +
app-misc/anki/files/23.12.1/no-git-submodule-sync.patch | 2 ++
app-misc/anki/files/23.12.1/pseudo-venv.patch | 10 +++++++---
app-misc/anki/files/23.12.1/remove-yarn-dep.patch | 1 +
5 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/app-misc/anki/files/23.12.1/configure-offline-build.patch b/app-misc/anki/files/23.12.1/configure-offline-build.patch
index 7979d4124744..28c77916e555 100644
--- a/app-misc/anki/files/23.12.1/configure-offline-build.patch
+++ b/app-misc/anki/files/23.12.1/configure-offline-build.patch
@@ -1,4 +1,5 @@
This is an adapted patch from the games/anki FreeBSD port.
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_configure_src_main.rs
It replaces or skips network-reliant methods of the build setup and disables
the setup for bundles and for offline documentation. This way, we achieve a
diff --git a/app-misc/anki/files/23.12.1/ninja-gentoo-setup.patch b/app-misc/anki/files/23.12.1/ninja-gentoo-setup.patch
index 4ef0da86d9f5..8671057d4054 100644
--- a/app-misc/anki/files/23.12.1/ninja-gentoo-setup.patch
+++ b/app-misc/anki/files/23.12.1/ninja-gentoo-setup.patch
@@ -1,4 +1,5 @@
This is an adapted patch from the games/anki FreeBSD port.
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_runner_src_build.rs
It adapts the ninja(-compatible) build system to the Gentoo system and
prevents repo sync via git.
diff --git a/app-misc/anki/files/23.12.1/no-git-submodule-sync.patch b/app-misc/anki/files/23.12.1/no-git-submodule-sync.patch
index 58addebf795d..df09a09b91a4 100644
--- a/app-misc/anki/files/23.12.1/no-git-submodule-sync.patch
+++ b/app-misc/anki/files/23.12.1/no-git-submodule-sync.patch
@@ -1,4 +1,6 @@
This is an adapted patch from the games/anki FreeBSD port.
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_configure_src_rust.rs
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_ninja__gen_src_git.rs
It prevents the build system from issuing the repo sync that
requires git and an internet connection.
diff --git a/app-misc/anki/files/23.12.1/pseudo-venv.patch b/app-misc/anki/files/23.12.1/pseudo-venv.patch
index fe5c00e17f93..8c173021a5b7 100644
--- a/app-misc/anki/files/23.12.1/pseudo-venv.patch
+++ b/app-misc/anki/files/23.12.1/pseudo-venv.patch
@@ -1,9 +1,13 @@
+This is an adapted patch from the games/anki FreeBSD port.
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_configure_src_python.rs
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_ninja__gen_src_python.rs
+
Use the "PythonEnvironmentStub" function to use a native Python environment
instead of a Python venv.
* Avoid the use of Python's pip (network access).
-* Remove the python_binary input which is the only dependant of the
- python_binary target. This saves us from setting an extra environment
- variable to prevent network access.
+* Remove the python_binary input for PythonEnvironmentStub since we create the
+ pseudo venv manually in the ebuild. This saves us from setting an extra
+ environment variable to prevent network access.
The python_binary input should really only be added to PythonEnvironment, if
the venv is not set up.
diff --git a/app-misc/anki/files/23.12.1/remove-yarn-dep.patch b/app-misc/anki/files/23.12.1/remove-yarn-dep.patch
index bb5d49861c6e..d4cfb30b80b4 100644
--- a/app-misc/anki/files/23.12.1/remove-yarn-dep.patch
+++ b/app-misc/anki/files/23.12.1/remove-yarn-dep.patch
@@ -1,4 +1,5 @@
This is an adapted patch from the games/anki FreeBSD port.
+https://github.com/freebsd/freebsd-ports/blob/109c3d4629b84972e660b689d169ac0761c1a519/games/anki/files/patch-build_runner_src_yarn.rs
The ebuild ships a ready-to-use node_modules tarball which does not require
sys-apps/yarn to be installed. Pre-built node_modules allows us to run JS tests.
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-misc/anki/files/23.12.1/
@ 2024-08-20 8:31 Joonas Niilola
0 siblings, 0 replies; 2+ messages in thread
From: Joonas Niilola @ 2024-08-20 8:31 UTC (permalink / raw
To: gentoo-commits
commit: dbb73d2c2716f419f1fe3c320c79ae3f97b1ac45
Author: Lucio Sauer <watermanpaint <AT> posteo <DOT> net>
AuthorDate: Wed Aug 7 13:05:00 2024 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue Aug 20 08:31:45 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dbb73d2c
app-misc/anki: ensure build runner and configure are built for CBUILD
These changes have not yet been tested in an actual cross environment
but since the build system respects Cargo environment variables, this
should hopefully work.
Bump the revision of this ebuild because the build now honors LDFLAGS
among other RUSTFLAGS set in cargo_env in the cargo eclass.
Signed-off-by: Lucio Sauer <watermanpaint <AT> posteo.net>
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
...ystem-nextest.patch => ninja-rules-for-cargo.patch} | 18 ++++++++++++++++--
1 file changed, 16 insertions(+), 2 deletions(-)
diff --git a/app-misc/anki/files/23.12.1/use-system-nextest.patch b/app-misc/anki/files/23.12.1/ninja-rules-for-cargo.patch
similarity index 50%
rename from app-misc/anki/files/23.12.1/use-system-nextest.patch
rename to app-misc/anki/files/23.12.1/ninja-rules-for-cargo.patch
index 8f931b97da86..cf9356bbc24c 100644
--- a/app-misc/anki/files/23.12.1/use-system-nextest.patch
+++ b/app-misc/anki/files/23.12.1/ninja-rules-for-cargo.patch
@@ -1,10 +1,24 @@
-Provide the binary ourselves to prevent network access.
+Fix the output path for Rust binaries in the Ninja file to match
+Cargo's target directory when CARGO_BUILD_TARGET is set. This prevents
+file-not-found errors for some build steps.
+
+Provide the cargo-nextest binary ourselves to prevent network access.
Set test runner options in the ebuild.
From: Lucio Sauer <watermanpaint@posteo.net>
--- a/build/ninja_gen/src/cargo.rs
+++ b/build/ninja_gen/src/cargo.rs
-@@ -152,19 +152,11 @@ impl BuildAction for CargoTest {
+@@ -61,6 +61,9 @@ impl RustOutput<'_> {
+ let mut path: Utf8PathBuf = rust_base.into();
+ if let Some(target) = target {
+ path = path.join(target);
++ } else {
++ let triple = std::env::var("CARGO_BUILD_TARGET").unwrap_or_default();
++ path = path.join(triple);
+ }
+ path = path.join(profile_output_dir(build_profile)).join(filename);
+ path.to_string()
+@@ -152,19 +155,11 @@ impl BuildAction for CargoTest {
fn files(&mut self, build: &mut impl FilesHandle) {
build.add_inputs("", &self.inputs);
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-08-20 8:31 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-20 8:31 [gentoo-commits] repo/gentoo:master commit in: app-misc/anki/files/23.12.1/ Joonas Niilola
-- strict thread matches above, loose matches on Subject: below --
2024-01-21 10:00 Sam James
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox