Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 792615 - sys-boot/refind-0.13.2 with clang - error: unknown argument: '-fno-tree-loop-distribute-patterns'
Summary: sys-boot/refind-0.13.2 with clang - error: unknown argument: '-fno-tree-loop-...
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Stéphane Veyret
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-05-28 11:41 UTC by vicalcas
Modified: 2021-06-06 16:09 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,6.30 KB, text/x-log)
2021-05-28 11:41 UTC, vicalcas
Details
emerge info (emergeinfo,6.99 KB, text/plain)
2021-05-28 11:41 UTC, vicalcas
Details
emerge pqv (emergepqv,125 bytes, text/plain)
2021-05-28 11:42 UTC, vicalcas
Details

Note You need to log in before you can comment on or make changes to this bug.
Description vicalcas 2021-05-28 11:41:29 UTC
Created attachment 711882 [details]
build.log

When trying to emerge refind with the clang toolchain it complains about the -fno-tree-loop-distribute-patterns flag, which i found in the Make.common file in the work directory. Is this an ebuild problem or it is ill-advised to compile refind with clang so i'd have to use the gcc toolchain fallback?
Comment 1 vicalcas 2021-05-28 11:41:47 UTC
Created attachment 711885 [details]
emerge info
Comment 2 vicalcas 2021-05-28 11:42:07 UTC
Created attachment 711888 [details]
emerge pqv
Comment 3 vicalcas 2021-05-28 11:44:23 UTC
Btw im using clang with thinlto and this also
LDFLAGS="-fuse-ld=lld -rtlib=compiler-rt -unwindlib=libunwind"
AR="llvm-ar"
NM="llvm-nm"
RANLIB="llvm-ranlib"
Comment 4 vicalcas 2021-05-28 11:46:26 UTC
(In reply to vicalcas from comment #3)
> Btw im using clang with thinlto and this also
> LDFLAGS="-fuse-ld=lld -rtlib=compiler-rt -unwindlib=libunwind"
> AR="llvm-ar"
> NM="llvm-nm"
> RANLIB="llvm-ranlib"

(Doesn't seem most of this are relevant because the cflags are already set by the Make.common file)
Comment 5 vicalcas 2021-05-29 17:20:42 UTC
It does compile with gcc without any problems
Comment 6 Stéphane Veyret 2021-06-06 16:09:13 UTC
Here is the answer of Rod Smith, author of rEFInd :

I don't use Clang myself, and I do not officially support it for
compiling rEFInd. Thus, I don't consider this a bug. That said, if
somebody were to submit a Sourceforge git merge request or patch that
makes rEFInd compile with Clang *AND THAT DOES NOT NEGATIVELY AFFECT GCC
COMPILATION*, I would likely approve that merge/patch. Emphasis added
because I have received submissions in the past (mostly for GPT fdisk,
not rEFInd) that have claimed to add support for new development
environments but that have created significant headaches.

At the moment, rEFInd's compilation process is unusually delicate,
thanks in part to the quirks of EFI development, but also to the fact
that it supports two EFI libraries (GNU-EFI and Tianocore EDK 2; also,
the latter can be built in either of two ways, one of which is
deprecated). This will make adding support for a different C compiler a
bit trickier; adding that new compiler will mean addressing both compile
paths, even if one of them is addressed by saying "nope, this
combination is unsupported." Compilation would have to fail in some
clean way in that case.