From 825f6894cd26376f9e3f57a9b8b20c7a7301ca0b Mon Sep 17 00:00:00 2001 From: "Dustin C. Hatch" Date: Fri, 13 Dec 2024 19:45:47 -0600 Subject: [PATCH] wip: Install Firefox --- ci/Jenkinsfile | 6 +++ install.packages | 1 + portage/make.conf/60-use.conf | 1 + portage/make.conf/introspection.conf | 4 ++ portage/make.conf/videocore.conf | 1 + portage/make.conf/wayland.conf | 1 + portage/package.accept_keywords/firefox | 1 + portage/package.use/firefox | 6 +++ .../librsvg/do-not-build-rsvg-convert.patch | 48 +++++++++++++++++++ prepare.sh | 13 +++++ 10 files changed, 82 insertions(+) create mode 100644 portage/make.conf/60-use.conf create mode 100644 portage/make.conf/introspection.conf create mode 100644 portage/make.conf/videocore.conf create mode 100644 portage/make.conf/wayland.conf create mode 100644 portage/package.accept_keywords/firefox create mode 100644 portage/package.use/firefox create mode 100644 portage/patches/gnome-base/librsvg/do-not-build-rsvg-convert.patch create mode 100644 prepare.sh diff --git a/ci/Jenkinsfile b/ci/Jenkinsfile index ff0de97..1270b8c 100644 --- a/ci/Jenkinsfile +++ b/ci/Jenkinsfile @@ -9,6 +9,12 @@ pipeline { } stages { + stage('Prepare') { + steps { + sh '. ./prepare.sh' + } + } + stage('Build') { steps { sh 'env -i PATH="${PATH}" make -C aimee-os CONFIGDIR=${PWD} O=/build' diff --git a/install.packages b/install.packages index 31638b0..5c67a29 100644 --- a/install.packages +++ b/install.packages @@ -1 +1,2 @@ net-wireless/wpa_supplicant +www-client/firefox diff --git a/portage/make.conf/60-use.conf b/portage/make.conf/60-use.conf new file mode 100644 index 0000000..ad110bb --- /dev/null +++ b/portage/make.conf/60-use.conf @@ -0,0 +1 @@ +USE="${USE} -python -readline" diff --git a/portage/make.conf/introspection.conf b/portage/make.conf/introspection.conf new file mode 100644 index 0000000..63c418a --- /dev/null +++ b/portage/make.conf/introspection.conf @@ -0,0 +1,4 @@ +# Disable GObject introspection because it cannot be cross-compiled +# https://bugs.gentoo.org/850895 +# https://bugs.gentoo.org/751325 +USE="${USE} -introspection -vala" diff --git a/portage/make.conf/videocore.conf b/portage/make.conf/videocore.conf new file mode 100644 index 0000000..05c0c2b --- /dev/null +++ b/portage/make.conf/videocore.conf @@ -0,0 +1 @@ +VIDEO_CARDS='v3d vc4' diff --git a/portage/make.conf/wayland.conf b/portage/make.conf/wayland.conf new file mode 100644 index 0000000..71d123e --- /dev/null +++ b/portage/make.conf/wayland.conf @@ -0,0 +1 @@ +USE="${USE} -X wayland" diff --git a/portage/package.accept_keywords/firefox b/portage/package.accept_keywords/firefox new file mode 100644 index 0000000..f0cbd3b --- /dev/null +++ b/portage/package.accept_keywords/firefox @@ -0,0 +1 @@ +dev-libs/nss ~amd64 diff --git a/portage/package.use/firefox b/portage/package.use/firefox new file mode 100644 index 0000000..3580b88 --- /dev/null +++ b/portage/package.use/firefox @@ -0,0 +1,6 @@ +media-libs/harfbuzz -cairo +media-libs/libvpx postproc +media-libs/mesa -llvm wayland +media-video/ffmpeg openssl -gnutls +www-client/firefox -telemetry dbus wayland +x11-libs/gtk+ wayland diff --git a/portage/patches/gnome-base/librsvg/do-not-build-rsvg-convert.patch b/portage/patches/gnome-base/librsvg/do-not-build-rsvg-convert.patch new file mode 100644 index 0000000..4e2775e --- /dev/null +++ b/portage/patches/gnome-base/librsvg/do-not-build-rsvg-convert.patch @@ -0,0 +1,48 @@ +--- a/Makefile.in 2024-12-13 12:17:08.339616211 -0600 ++++ b/Makefile.in 2024-12-13 12:18:30.301517960 -0600 +@@ -641,12 +641,6 @@ + rsvg/src/test_utils/reference_utils.rs \ + rsvg-bench/Cargo.toml \ + rsvg-bench/src/main.rs \ +- rsvg_convert/tests/internal_predicates/file.rs \ +- rsvg_convert/tests/internal_predicates/mod.rs \ +- rsvg_convert/tests/internal_predicates/pdf.rs \ +- rsvg_convert/tests/internal_predicates/png.rs \ +- rsvg_convert/tests/internal_predicates/svg.rs \ +- rsvg_convert/tests/rsvg_convert.rs \ + librsvg-c/tests/legacy_sizing.rs \ + gdk-pixbuf-loader/Cargo.toml \ + gdk-pixbuf-loader/src/lib.rs \ +@@ -685,15 +679,6 @@ + librsvgincdir = $(includedir)/librsvg-$(RSVG_API_VERSION)/librsvg + librsvginc_HEADERS = $(librsvg_public_headers) + +-# Use SCRIPTS instead of PROGRAMS since we build it on our own +-bin_SCRIPTS = rsvg-convert$(EXEEXT) +-RSVG_CONVERT_BIN = $(CARGO_TARGET_DIR)/$(RUST_TARGET_SUBDIR)/rsvg-convert$(EXEEXT) +-RSVG_CONVERT_SRC = \ +- rsvg_convert/Cargo.toml \ +- rsvg_convert/build.rs \ +- rsvg_convert/src/main.rs \ +- $(NULL) +- + @HAVE_RST2MAN_TRUE@man1_MANS = rsvg-convert.1 + dist_doc_DATA = \ + README.md \ +@@ -1643,16 +1628,6 @@ + $(CARGO) --locked build $(CARGO_VERBOSE) $(CARGO_TARGET_ARGS) $(CARGO_RELEASE_ARGS) --package librsvg-c \ + && cd $(LIBRSVG_BUILD_DIR) && $(LINK) $< && cp $(RUST_LIB) .libs/librsvg_c_api.a + +-$(RSVG_CONVERT_BIN): $(RSVG_CONVERT_SRC) | librsvg_c_api.la +- +cd $(top_srcdir) && \ +- PKG_CONFIG_ALLOW_CROSS=1 \ +- PKG_CONFIG='$(PKG_CONFIG)' \ +- CARGO_TARGET_DIR=$(CARGO_TARGET_DIR) \ +- $(CARGO) --locked build $(CARGO_VERBOSE) $(CARGO_TARGET_ARGS) $(CARGO_RELEASE_ARGS) --package rsvg_convert +- +-rsvg-convert$(EXEEXT): $(RSVG_CONVERT_BIN) +- cd $(LIBRSVG_BUILD_DIR) && cp $(RSVG_CONVERT_BIN) rsvg-convert$(EXEEXT) +- + rsvg-convert.1: rsvg-convert.rst + @HAVE_RST2MAN_TRUE@ $(RST2MAN) $(top_srcdir)/rsvg-convert.rst rsvg-convert.1 + @HAVE_RST2MAN_FALSE@ @echo "========================================" diff --git a/prepare.sh b/prepare.sh new file mode 100644 index 0000000..8000650 --- /dev/null +++ b/prepare.sh @@ -0,0 +1,13 @@ +#!/bin/sh + +ls -l /etc/portage + +mkdir -p /etc/portage/package.use +mkdir -p /etc/portage/make.conf +cp portage/package.use/firefox /etc/portage/package.use/ +cp portage/make.conf/introspection.conf /etc/portage/make.conf/ +cp portage/make.conf/wayland.conf /etc/portage/make.conf/ + +xargs -r emerge -vbknuUj --rebuilt-binaries=y --color=y <