public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-dev@lists.gentoo.org
Subject: [gentoo-dev] [RFC] Introducing LLVM_TARGET
Date: Mon, 05 Feb 2024 18:07:00 +0100	[thread overview]
Message-ID: <211397b1e89bc0d47a1769102648350a3336f9a5.camel@gentoo.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 1403 bytes --]

Hi,

TL;DR: Given that (not really surprising) the current approach for LLVM
dependencies doesn't work, I think it's time to give up and introduce
LLVM_TARGETS.  This would probably mean introduce llvm-r1.eclass.

However, since random apps tend to require old versions of LLVM, I do
wonder if we should set the default value globally, or have the eclass
generate IUSE defaults, so that everything works out of the box.


The problem roughly is that right now we rely on depstrings like:

DEPEND="
  <sys-devel/clang-19:=
  <sys-devel/llvm-19:=
  || (
    ( sys-devel/clang:18 sys-devel/llvm:18 )
    ( sys-devel/clang:17 sys-devel/llvm:17 )
    ( sys-devel/clang:16 sys-devel/llvm:16 )
  )
"

This kinda works, in the sense that it will enforce that you have
a single matching version of LLVM+Clang, and the eclass will use it. 
However, the := deps on top may be entirely mismatched.  For example, if
you have llvm:18 and clang:17 (+ llvm:17) installed, you'd get:

  sys-devel/clang:17=
  sys-devel/llvm:18=

When more packages land on the list, this could lead to quite a mess.

So what'd we go for would effectively be:

DEPEND="
  llvm_target_16? ( sys-devel/clang:16 sys-devel/llvm:16 )
  llvm_target_17? ( sys-devel/clang:17 sys-devel/llvm:17 )
  llvm_target_18? ( sys-devel/clang:18 sys-devel/llvm:18 )
"

WDYT?

-- 
Best regards,
Michał Górny


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 512 bytes --]

             reply	other threads:[~2024-02-05 17:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-05 17:07 Michał Górny [this message]
2024-02-05 23:44 ` [gentoo-dev] [RFC] Introducing LLVM_TARGET Sam James
2024-02-05 23:47   ` Sam James
2024-02-06  3:33   ` Ionen Wolkens

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=211397b1e89bc0d47a1769102648350a3336f9a5.camel@gentoo.org \
    --to=mgorny@gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox