media-libs/libmypaint can use libomp (Clang+LLD tested, confirmed works) Reproducible: Always Steps to Reproduce: 1. Try to build gcc without openmp, have libmypaint installed 2. Portage dependency conflict
Relevant flags: CFLAGS="-O2 -fopenmp=libomp" CXXFLAGS="-O2 -fopenmp=libomp" LDFLAGS="-Wl,-O1 -Wl,--as-needed -fuse-ld=lld -fopenmp=libomp -lomp" `-lomp` is needed for LDFLAGS though if you specified -fopenmp=libomp in C{XX}FLAGS+LDFLAGS, otherwise you get undefined symbol for omp_get_max_threads I'm weeding through all the quirks right now with Clang+LLD system wide, OpenMP seems to be the weirdest thing right now but I'm fixing those as I go, avoiding any GCC dependencies I can find.
Forgot to mention, I'm building libmypaint with USE="openmp" enabled. I know that probably seems obvious, just putting that out in there in case this comes up.
I'd expect it to handle -lomp for us given it's using AC_OPENMP. I can't reproduce your issue either. I can fix the dependency issue, of course, but could you show me the underlinking issue? Is it failing at runtime instead?
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f19472c25655279ce8dd1ea88d44a2c55cdfe071 commit f19472c25655279ce8dd1ea88d44a2c55cdfe071 Author: Sam James <sam@gentoo.org> AuthorDate: 2021-12-16 04:38:48 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2021-12-16 04:38:48 +0000 media-libs/libmypaint: fix openmp handling Bug: https://bugs.gentoo.org/828887 Signed-off-by: Sam James <sam@gentoo.org> .../{libmypaint-1.6.1.ebuild => libmypaint-1.6.1-r1.ebuild} | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
`-fopenmp=libomp -lomp` isn't needed, I was migrating a system from GCC+LD to Clang+LLD and needed to recompile more of the system against the new toolchain, sorry about that bit. I may have needed to re-build libomp but anyway, that issue is gone now. Thanks!
(In reply to Alec Ari from comment #5) > `-fopenmp=libomp -lomp` isn't needed, I was migrating a system from GCC+LD > to Clang+LLD and needed to recompile more of the system against the new > toolchain, sorry about that bit. I may have needed to re-build libomp but > anyway, that issue is gone now. > > Thanks! No problem! Thank you!