commit:     a4b4987f14e79eabf1c593cfa9defde1b1060516
Author:     Itai Ferber <itai <AT> itaiferber <DOT> net>
AuthorDate: Fri Mar  6 18:18:36 2026 +0000
Commit:     David Roman <stkw0 <AT> disroot <DOT> org>
CommitDate: Fri Mar  6 18:48:51 2026 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=a4b4987f

dev-lang/odin: clean up ebuilds

Signed-off-by: Itai Ferber <itai <AT> itaiferber.net>

 dev-lang/odin/odin-2026.03.ebuild | 20 +++++++++-----------
 dev-lang/odin/odin-9999.ebuild    | 36 +++++++++++++++++-------------------
 2 files changed, 26 insertions(+), 30 deletions(-)

diff --git a/dev-lang/odin/odin-2026.03.ebuild 
b/dev-lang/odin/odin-2026.03.ebuild
index 12857ad014..38c8296a05 100644
--- a/dev-lang/odin/odin-2026.03.ebuild
+++ b/dev-lang/odin/odin-2026.03.ebuild
@@ -7,7 +7,6 @@ LLVM_COMPAT=( {17..21} )
 inherit llvm-r2
 
 DESCRIPTION="The Data-Oriented Language for Sane Software Development."
-
 HOMEPAGE="https://odin-lang.org/";
 
 if [[ $PV == 9999 ]]; then
@@ -16,16 +15,11 @@ if [[ $PV == 9999 ]]; then
 else
        MY_PV="${PV/./-}"
        
SRC_URI="https://github.com/odin-lang/Odin/archive/refs/tags/dev-${MY_PV}.tar.gz
 -> ${PN}-${MY_PV}.tar.gz"
-       # Source directory; the dir where the sources can be found 
(automatically
-       # unpacked) inside ${WORKDIR}.  The default value for S is 
${WORKDIR}/${P}
-       # If you don't need to change it, leave the S= line out of the ebuild
-       # to keep it tidy.
        S="${WORKDIR}/Odin-dev-${MY_PV}"
        KEYWORDS="~amd64"
 fi
 
 LICENSE="ZLIB"
-
 SLOT="0"
 
 RDEPEND="
@@ -35,7 +29,7 @@ RDEPEND="
        ')
 "
 
-DEPEND="${RDEPEND}"
+BDEPEND="${RDEPEND}"
 
 # build_odin.sh sets its own flags. Some gcc flags cause build failures
 CPPFLAGS=""
@@ -45,10 +39,14 @@ src_compile() {
 }
 
 src_install() {
-       insinto usr/lib/odin
-       exeinto usr/lib/odin
+       local install_dir="/usr/$(get_libdir)/${PN}"
+       insinto "${install_dir}"
+       doins -r base core vendor
 
+       # Odin needs to link against runtime libs. Odin can pick up on those 
libs
+       # via `ODIN_ROOT`, but installing it into the same base dir keeps 
everything
+       # working right out of the box.
+       exeinto "${install_dir}"
        doexe odin
-       doins -r base core vendor
-       dosym -r /usr/lib/odin/odin /usr/bin/odin
+       dosym -r "${install_dir}/odin" "/usr/bin/odin"
 }

diff --git a/dev-lang/odin/odin-9999.ebuild b/dev-lang/odin/odin-9999.ebuild
index 478efa1330..38c8296a05 100644
--- a/dev-lang/odin/odin-9999.ebuild
+++ b/dev-lang/odin/odin-9999.ebuild
@@ -3,11 +3,10 @@
 
 EAPI=8
 
-LLVM_COMPAT=(14 17 18 19 20)
-inherit llvm-r1
+LLVM_COMPAT=( {17..21} )
+inherit llvm-r2
 
 DESCRIPTION="The Data-Oriented Language for Sane Software Development."
-
 HOMEPAGE="https://odin-lang.org/";
 
 if [[ $PV == 9999 ]]; then
@@ -15,27 +14,22 @@ if [[ $PV == 9999 ]]; then
        inherit git-r3
 else
        MY_PV="${PV/./-}"
-       
SRC_URI="https://github.com/odin-lang/Odin/archive/refs/tags/dev-${MY_PV}.tar.gz";
-       # Source directory; the dir where the sources can be found 
(automatically
-       # unpacked) inside ${WORKDIR}.  The default value for S is 
${WORKDIR}/${P}
-       # If you don't need to change it, leave the S= line out of the ebuild
-       # to keep it tidy.
+       
SRC_URI="https://github.com/odin-lang/Odin/archive/refs/tags/dev-${MY_PV}.tar.gz
 -> ${PN}-${MY_PV}.tar.gz"
        S="${WORKDIR}/Odin-dev-${MY_PV}"
        KEYWORDS="~amd64"
 fi
 
-LICENSE="BSD"
-
+LICENSE="ZLIB"
 SLOT="0"
 
 RDEPEND="
-$(llvm_gen_dep '
-llvm-core/clang:${LLVM_SLOT}=
-llvm-core/llvm:${LLVM_SLOT}=
-')
+       $(llvm_gen_dep '
+               llvm-core/clang:${LLVM_SLOT}=
+               llvm-core/llvm:${LLVM_SLOT}=
+       ')
 "
 
-DEPEND="${RDEPEND}"
+BDEPEND="${RDEPEND}"
 
 # build_odin.sh sets its own flags. Some gcc flags cause build failures
 CPPFLAGS=""
@@ -45,10 +39,14 @@ src_compile() {
 }
 
 src_install() {
-       insinto usr/lib/odin
-       exeinto usr/lib/odin
+       local install_dir="/usr/$(get_libdir)/${PN}"
+       insinto "${install_dir}"
+       doins -r base core vendor
 
+       # Odin needs to link against runtime libs. Odin can pick up on those 
libs
+       # via `ODIN_ROOT`, but installing it into the same base dir keeps 
everything
+       # working right out of the box.
+       exeinto "${install_dir}"
        doexe odin
-       doins -r base core vendor
-       dosym -r /usr/lib/odin/odin /usr/bin/odin
+       dosym -r "${install_dir}/odin" "/usr/bin/odin"
 }

Reply via email to