tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: c++11
On Thu, Nov 03, 2016 at 03:46:20PM -0400, Greg Troxel wrote:
>
> Thomas Klausner <tk%giga.or.at@localhost> writes:
>
> > Shouldn't we rather add support to USE_LANGUAGES like this:
> >
> > USE_LANGUAGES+= c++11
> >
> > and make bsd.pkg.mk set CXXFLAGS and request a good-enough compiler?
>
> I have the impression that in a C++ program one can't mix compilers and
> expect it to work. If e.g. one compiles a library with gcc 4.5, and a
> program with 4.8, and then links them with 4.8, will that
> program/library work correctly? This seems to reliably work in C. If
> it's not reliable/true in C++, is it because each compiler has a
> different ABI? Some other reason?
>
> Is it then necessary to arrange for all programs to be built with the
> same compiler?
>
> And, is this need-same-compiler issue related to issues from switching
> between clang and gcc (which seems inadvisable on the fly)?
>
>
lang/gcc* packages should install everything in /usr/pkg/gcc{ver} and
fix broken includes, but I don't know to what extent it works/we take
advantage of this/base dynamic linker cooperates.
given that I recently had to add a patch to make pkgsrc gcc work with
shared libraries on netbsd (FSF gcc still thinks we don't have them),
my hunch is that we could probably do it better...
now netbsd-6 firefox relies on it to work and it seems to run, so it
can't be all bad.
Home |
Main Index |
Thread Index |
Old Index