From 0fad76216cdec86ee211dc5140a6de7c3e07a8e9 Mon Sep 17 00:00:00 2001 From: Huang Rui Date: Mon, 23 Nov 2026 00:20:03 -0800 Subject: [PATCH] dev-util/codex: drop 0.169.0 Signed-off-by: Huang Rui --- dev-util/codex/Manifest | 2 - dev-util/codex/codex-0.169.0.ebuild | 210 ---------------------------- 2 files changed, 212 deletions(-) delete mode 100644 dev-util/codex/codex-0.169.0.ebuild diff --git a/dev-util/codex/Manifest b/dev-util/codex/Manifest index fb57c703ee..d10a95bccd 100644 --- a/dev-util/codex/Manifest +++ b/dev-util/codex/Manifest @@ -1,7 +1,5 @@ -DIST codex-0.169.0.tar.gz 20106159 BLAKE2B 9e435ebbfc2e1f09a17c12a26ad763405d370358266648886792ab1982036b6d5d7f4cfe31290cb4106423a53148bb962e86f405e17043898d404c6f30eb2b98 SHA512 00a18659e50126f37c23a2b097afc5ab80f361627ac52a281f0897f97f0f9a05d25e88a8d8a5aab6b582ab642b346a34e7de07edb46957fd7589aa41cccd5e36 DIST codex-0.170.0.tar.gz 20246531 BLAKE2B 9675689a347c81d4bb754c72fef234fc6d7eebdf43f7a80bd53674728528edccdfbd1f054a8f7486ada5d8a07799d70c09c6a9a4a49bb5b4076dfc23659743da SHA512 097063b7f1214a8874aff1678dd2db5fbcbaaa39417ebf272daf2229db2d0c80c8e0fbfa2389b44cb7d3517ec6f32653bb00b5a3471e156e85bc43f85e292472 DIST codex-0.171.0.tar.gz 20869033 BLAKE2B aa0931b4bf7845950dda2dbb3fd8af1f145c45b862a6c1a90f4b3aad8db02ec955b3f5cf6516e5ef77b0dafd25a30b0e36fb3e04fb61065cb9482bee0f0111cb SHA512 12f082232a6eacd127c173ff76d973db78e1ea5fd1e02749ce67396281a1b67ca8630e8191e180c95b8366e18eaaf2f2d5e771db920d3a1fac1876ce185b16aa -DIST codex-rust-v0.169.0-crates.tar.xz 137064744 BLAKE2B 472c5c7f010598d1d729f2d724c6db077c1b4dd48f3c0656162171ee60d09febc70b4ac547e5eec336551dccdfd893e3b81eeeecc52dee5344a293ef9e7cc7bf SHA512 1bb8335c2907b909b3106d3c85692536c62601cff091b6a39248f1ad3161b23da9ad99a9b25004d299b56fa54dab528c7828acfc82987e2efc087d93b427c935 DIST codex-rust-v0.170.0-crates.tar.xz 137064744 BLAKE2B 472c5c7f010598d1d729f2d724c6db077c1b4dd48f3c0656162171ee60d09febc70b4ac547e5eec336551dccdfd893e3b81eeeecc52dee5344a293ef9e7cc7bf SHA512 1bb8335c2907b909b3106d3c85692536c62601cff091b6a39248f1ad3161b23da9ad99a9b25004d299b56fa54dab528c7828acfc82987e2efc087d93b427c935 DIST codex-rust-v0.171.0-crates.tar.xz 137982924 BLAKE2B 958d8a955b84fab7a25d611a7f38f7c9e2cf866d8b7a3a8f619de31021eaa653423a125b10f8972dbc97939df01029d037cc7fce1093db17022f487de9ab4fb0 SHA512 9e956d84803de512e966d57a6e2aaeb93f94d5205a68805c165cef161479429ac12071a21a740cf123ebada76f8594677dda549a33cfa6e1c1d4808ed034b95c DIST crossterm-37ca4a27a9424ec5dbe6451f48c339d7b45f8d63.gh.tar.gz 162868 BLAKE2B dbcef93a74ac940a49884e2684e3ded20cbe98591027dc6d634e4626ee5e3d2814329d2c53ce90eda903eba81131c64630ed88cfcb3c2c740818cee9bc887f8c SHA512 5f2299734d4213c1d19bd405c6beefcf2936c800838cdea61d4e936f424eef8f29df9cc0aff73e2c7530e3d51080448741598c493034f9057d8e3ceb0d13148e diff --git a/dev-util/codex/codex-0.169.0.ebuild b/dev-util/codex/codex-0.169.0.ebuild deleted file mode 100644 index 4c23f97246..0000000000 --- a/dev-util/codex/codex-0.169.0.ebuild +++ /dev/null @@ -1,210 +0,0 @@ -# Copyright 2025-2026 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -# NOTE: This package uses a pre-built crate tarball instead of listing individual -# crates in CRATES="". This approach is required because: -# 1. Codex has 800+ crate dependencies, which triggers Portage QA warnings: -# "QA Notice: This package uses a very large number of CRATES. Please provide -# a crate tarball instead and fetch it via SRC_URI." -# 2. Stricter ebuild QA checks (e.g., in CI pipelines) fail with too many crates. -# -# The crate tarball is auto-generated by GitHub Actions at: -# https://github.com/gentoo-zh-drafts/codex/ -# Workflow source code for auditing: -# https://github.com/gentoo-zh-drafts/codex/blob/crate-dist/.github/workflows/crates.yml -# This allows anyone to review and verify the crate packaging process. - -# vendored openssl-0.10.75 and openssl-sys-0.9.111 don't support openssl-4 -CRATES=" - openssl@0.10.82 - openssl-sys@0.9.118 -" - -declare -A GIT_CRATES=( - [crossterm]='https://github.com/openai-oss-forks/crossterm;ed1cdab335221515706178d68495bba2aed1924f;crossterm-%commit%' - [h3]='https://github.com/hyperium/h3;e07e69412876f7e26f026bd75a48b2704d8c8283;h3-%commit%/h3' - [h3-quinn]='https://github.com/hyperium/h3;e07e69412876f7e26f026bd75a48b2704d8c8283;h3-%commit%/h3-quinn' - [mxc-sdk]='https://github.com/microsoft/mxc;b21120168d70befe12356411423266bfef168446;mxc-%commit%/src/mxc-sdk' - [nucleo-matcher]='https://github.com/helix-editor/nucleo;4253de9faabb4e5c6d81d946a5e35a90f87347ee;nucleo-%commit%/matcher' - [nucleo]='https://github.com/helix-editor/nucleo;4253de9faabb4e5c6d81d946a5e35a90f87347ee;nucleo-%commit%' - [rmcp-macros]='https://github.com/modelcontextprotocol/rust-sdk;98a54789b80110ad210495c4ad845c89e1980471;rust-sdk-%commit%/crates/rmcp-macros' - [rmcp]='https://github.com/modelcontextprotocol/rust-sdk;98a54789b80110ad210495c4ad845c89e1980471;rust-sdk-%commit%/crates/rmcp' - [sqlx-core]='https://github.com/transact-rs/sqlx;10462fa4414c6c7f1ed1d39bb31678e3b726878c;sqlx-%commit%/sqlx-core' - [sqlx-sqlite]='https://github.com/transact-rs/sqlx;10462fa4414c6c7f1ed1d39bb31678e3b726878c;sqlx-%commit%/sqlx-sqlite' - [runfiles]='https://github.com/dzbarsky/rules_rust;b56cbaa8465e74127f1ea216f813cd377295ad81;rules_rust-%commit%/rust/runfiles' - [tokio-tungstenite]='https://github.com/openai-oss-forks/tokio-tungstenite;7447c427513cfe685f236e1ac0513c4ea3dd9c0b;tokio-tungstenite-%commit%' - [tungstenite]='https://github.com/openai-oss-forks/tungstenite-rs;bc589d684755a8c02da0fc7e58d0861cbfc306f1;tungstenite-rs-%commit%' - [v8]='https://github.com/openai-oss-forks/rusty_v8;90a65f887a0c0f048f3784afbcb320b373c8a2e0;rusty_v8-%commit%' -) - -RUST_MIN_VER="1.95.0" - -# python3 .github/scripts/rusty_v8_bazel.py resolved-v8-crate-version -RUSTY_V8_TAG="152.2.0" - -inherit cargo check-reqs toolchain-funcs - -CHECKREQS_MEMORY="15G" -CHECKREQS_DISK_BUILD="20G" - -DESCRIPTION="Codex CLI - OpenAI's AI-powered coding agent" -HOMEPAGE="https://github.com/openai/codex" - -# The crate tarball URL uses ${PV} so it auto-updates when bumping versions. -# This tarball is generated by: https://github.com/gentoo-zh-drafts/codex/ -# See .github/workflows/crates.yml for the generation process. -SRC_URI=" - https://github.com/openai/${PN}/archive/rust-v${PV}.tar.gz -> ${PN}-${PV}.tar.gz - https://github.com/gentoo-zh-drafts/codex/releases/download/rust-v${PV}/codex-rust-v${PV}-crates.tar.xz - amd64? ( - https://github.com/openai/codex/releases/download/rusty-v8-v${RUSTY_V8_TAG}/librusty_v8_release_x86_64-unknown-linux-musl.a.gz - -> rusty_v8_${RUSTY_V8_TAG}_librusty_v8_release_x86_64-unknown-linux-musl.a.gz - https://github.com/openai/codex/releases/download/rusty-v8-v${RUSTY_V8_TAG}/src_binding_release_x86_64-unknown-linux-musl.rs - -> rusty_v8_${RUSTY_V8_TAG}_src_binding_release_x86_64-unknown-linux-musl.rs - ) - arm64? ( - https://github.com/openai/codex/releases/download/rusty-v8-v${RUSTY_V8_TAG}/librusty_v8_release_aarch64-unknown-linux-musl.a.gz - -> rusty_v8_${RUSTY_V8_TAG}_librusty_v8_release_aarch64-unknown-linux-musl.a.gz - https://github.com/openai/codex/releases/download/rusty-v8-v${RUSTY_V8_TAG}/src_binding_release_aarch64-unknown-linux-musl.rs - -> rusty_v8_${RUSTY_V8_TAG}_src_binding_release_aarch64-unknown-linux-musl.rs - ) - ${CARGO_CRATE_URIS} -" - -S="${WORKDIR}/${PN}-rust-v${PV}/codex-rs" - -LICENSE="Apache-2.0" -# Dependent crate licenses -LICENSE+=" - Apache-2.0 Apache-2.0-with-LLVM-exceptions BSD-2 BSD Boost-1.0 - CC0-1.0 CDLA-Permissive-2.0 ISC MIT MPL-2.0 Unicode-3.0 ZLIB -" -SLOT="0" -KEYWORDS="-* ~amd64 ~arm64" -# Tests need GStreamer 1.28 and the upstream voice runtime fixtures -RESTRICT="test" - -DEPEND="dev-libs/openssl:=" -RDEPEND="${DEPEND} - >=sys-apps/bubblewrap-0.11.2 - sys-apps/ripgrep -" -BDEPEND="virtual/pkgconfig" - -# rust does not use *FLAGS from make.conf, silence portage warning -QA_FLAGS_IGNORED="usr/lib/${PN}/bin/*" - -pkg_pretend() { - check-reqs_pkg_pretend -} - -pkg_setup() { - check-reqs_pkg_setup - rust_pkg_setup - if tc-is-lto; then - export CARGO_PROFILE_RELEASE_LTO=thin - else - export CARGO_PROFILE_RELEASE_LTO=false - fi -} - -gen_git_crate_dir() { - # https://github.com/gentoo/gentoo/blob/b09dd88412fe2d5eee5a8891e08bfa2d67848da3/eclass/cargo.eclass#L442 - IFS=';' read -r crate_uri commit crate_dir <<<"${GIT_CRATES[$1]}" - echo "${WORKDIR}/${crate_dir//%commit%/${commit}}" -} - -src_prepare() { - default - - # Fix tokio-tungstenite's git dependency on tungstenite - sed -i '/^\[dependencies\.tungstenite\]/,/^$/{ - s|git = "https://github.com/openai-oss-forks/tungstenite-rs"|path = "'"$(gen_git_crate_dir tungstenite)"'"| - /^rev = /d - }' "$(gen_git_crate_dir tokio-tungstenite)/Cargo.toml" || die - - # Remove the [patch.crates-io] section and add path-based patches - sed -i '/^\[patch\.crates-io\]/,/^$/d' "${S}/Cargo.toml" || die - sed -i '/^\[patch\."ssh:\/\/git@github\.com/,/^$/d' "${S}/Cargo.toml" || die - - # Add new patch section with local paths - cat >> "${S}/Cargo.toml" <<-EOF || die - - [patch.crates-io] - crossterm = { path = "$(gen_git_crate_dir crossterm)" } - sqlx-core = { path = "$(gen_git_crate_dir sqlx-core)" } - sqlx-sqlite = { path = "$(gen_git_crate_dir sqlx-sqlite)" } - tokio-tungstenite = { path = "$(gen_git_crate_dir tokio-tungstenite)" } - tungstenite = { path = "$(gen_git_crate_dir tungstenite)" } - v8 = { path = "$(gen_git_crate_dir v8)" } - EOF - - local crate sum - for crate in openssl-0.10.82 openssl-sys-0.9.118; do - sum=$(sha256sum "${DISTDIR}"/${crate}.crate | cut -d' ' -f1) - sed -i -e "/^name = \"${crate%-*}\"$/,/^checksum/{" \ - -e "s/^version = .*/version = \"${crate##*-}\"/" \ - -e "s/^checksum = .*/checksum = \"${sum}\"/" \ - -e "}" Cargo.lock || die - done - # openssl-0.10.82 no longer depends on once_cell - sed -i -e '/^name = "openssl"$/,/^]/{/"once_cell",/d}' Cargo.lock || die -} - -src_compile() { - local rusty_v8_triple - use amd64 && rusty_v8_triple=x86_64-unknown-linux-musl - use arm64 && rusty_v8_triple=aarch64-unknown-linux-musl - - # codex-core trait resolution overflows rustc's default 8MiB stack - export RUST_MIN_STACK=16777216 - - RUSTY_V8_ARCHIVE="${DISTDIR}/rusty_v8_${RUSTY_V8_TAG}_librusty_v8_release_${rusty_v8_triple}.a.gz" \ - RUSTY_V8_SRC_BINDING_PATH="${DISTDIR}/rusty_v8_${RUSTY_V8_TAG}_src_binding_release_${rusty_v8_triple}.rs" \ - cargo_src_compile \ - --bin codex \ - --bin codex-code-mode-host -} - -src_install() { - local pkgdir="/usr/lib/${PN}" - local pkg_target - case ${ARCH} in - amd64) pkg_target="x86_64-unknown-linux-gnu" ;; - arm64) pkg_target="aarch64-unknown-linux-gnu" ;; - esac - - exeinto "${pkgdir}"/bin - doexe "$(cargo_target_dir)/codex" "$(cargo_target_dir)/codex-code-mode-host" - - # The app-server daemon installs the CLI from this layout, see - # https://github.com/openai/codex/issues/48050 - cat > "${T}"/codex-package.json <<-EOF || die - { - "layoutVersion": 1, - "version": "${PV}", - "target": "${pkg_target}", - "variant": "codex", - "entrypoint": "bin/codex", - "resourcesDir": "codex-resources", - "pathDir": "codex-path" - } - EOF - insinto "${pkgdir}" - doins "${T}"/codex-package.json - - # The layout requires both files, they resolve to the system programs - printf '#!/bin/sh\nexec %s/usr/bin/rg "$@"\n' "${EPREFIX}" > "${T}"/rg || die - printf '#!/bin/sh\nexec %s/usr/bin/bwrap "$@"\n' "${EPREFIX}" > "${T}"/bwrap || die - exeinto "${pkgdir}"/codex-path - doexe "${T}"/rg - exeinto "${pkgdir}"/codex-resources - doexe "${T}"/bwrap - - dosym ../lib/"${PN}"/bin/codex /usr/bin/"${PN}" - dosym ../lib/"${PN}"/bin/codex-code-mode-host /usr/bin/codex-code-mode-host - - einstalldocs -}