Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 299431 - media-libs/openjpeg should depend on virtual/libstdc++
Summary: media-libs/openjpeg should depend on virtual/libstdc++
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Gentoo Graphics Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-01-03 01:30 UTC by Reimar Döffinger
Modified: 2010-01-05 01:08 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Reimar Döffinger 2010-01-03 01:30:48 UTC
During the final linking stage openjpeg use -lstdc++.
Thus it depends on libstdc++ being installed, but it does not declare it as dependency.
This is particularly easy to notice when using emerge-wrapper with a clean target like x86_64-w64-mingw32 (though openjpeg doesn't compiler on that for other reasons).

Reproducible: Always

Steps to Reproduce:
Comment 1 Samuli Suominen (RETIRED) gentoo-dev 2010-01-03 21:35:39 UTC
- virtual/libstdc++ is for libstdc++.so.5 from GCC 3.3.x
- openjpeg is a source based package
- libstdc++.so.6 is part of sys-devel/gcc, if you don't have gcc, you don't have a sane system

in other words: no, I won't make sys-devel/gcc a depend of media-libs/openjpeg, as gcc is part of system set.
Comment 2 Reimar Döffinger 2010-01-03 21:43:46 UTC
gcc was compiled with "nocxx" flags (since it is for a cross-compile toolchain).
While I'd prefer it if I didn't need a C++ compiler just to get libstdc++, is there a chance to make it at least give a sane error message, like "recompile gcc without nocxx"?
I noticed that quite a few other packages have similar "issues" e.g. gettext requiring actually a C++ compiler even with the nocxx use flag.
Comment 3 Samuli Suominen (RETIRED) gentoo-dev 2010-01-03 21:58:30 UTC
(In reply to comment #2)
> gcc was compiled with "nocxx" flags (since it is for a cross-compile
> toolchain).
> While I'd prefer it if I didn't need a C++ compiler just to get libstdc++, is
> there a chance to make it at least give a sane error message, like "recompile
> gcc without nocxx"?
> I noticed that quite a few other packages have similar "issues" e.g. gettext
> requiring actually a C++ compiler even with the nocxx use flag.
> 

There's currently no sane way of checking if gcc is built without nocxx or not, you're pretty much on your own if you do that. None of the packages linking to libstdc++ does any kind of checking. virtual/libstdc++ is really only for old binary packages that need the old libstdc++.so.5... so that's totally unrelated to this problem

Ideally we'd have an eclass, like cxx.eclass, which would check the compilers properties that's currently used and selected with gcc-config, that could then be reused in ebuilds... but it's currently no-avail. I suggest you bring this up in gentoo-dev mailinglist
Comment 4 Samuli Suominen (RETIRED) gentoo-dev 2010-01-03 22:11:57 UTC
Or possible a tc-has-cxx() function to toolchain-funcs.eclass, that grep's for something appropiate like languages and c++ for `gcc -v`. Either way, any movement on this belongs to the mailinglist...
Comment 5 SpanKY gentoo-dev 2010-01-05 01:08:42 UTC
yes, this is a mailing list topic

USE=cxx is for packages with optional C++ support.  it is not for packages which always require C++.