Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 May 2001 08:28:41 -0700
From:      Terry Lambert <tlambert2@mindspring.com>
To:        Makoto MATSUSHITA <matusita@jp.FreeBSD.org>
Cc:        hackers@FreeBSD.ORG
Subject:   Re: Question about building source
Message-ID:  <3AFAB3A9.798899F@mindspring.com>
References:  <3AF82432.F150DB51@mindspring.com> <20010509025423Q.matusita@jp.FreeBSD.org> <3AF95FFB.40DCF441@mindspring.com> <20010510010142X.matusita@jp.FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Makoto MATSUSHITA wrote:
> tlambert2> It still breaks.  See bsd.orig.mk; you _can't_ use a
> tlambert2> compiler other than one installed in the default location,
> tlambert2> or it will override the compiler defaults which tell it
> tlambert2> where the correct header and crt0 files live.  Really.
> 
> ???
> 
> If you run 'chroot /vol1/FreeBSD /bin/sh', you'll get an environment
> that /vol1/FreeBSD is /; Compiler is in /usr/bin/cc.  Headers are in
> /usr/include. Crt* files are in /usr/lib.  All files are located as it
> should be.
> 
> If it doesn't work as you have said, "make release' also _doesn't_
> work; we cannot make a distribution. Obviously, it's wrong:)

I think you are missing the facts:

o	I am using a non-default compiler installation, so
	that mu C++ include directory is in /usr/local/include

o	DESTDIR is set

o	Look in /usr/share/bsd.prog.mk for ".if defined(DESTDIR)";
	it overrides my compiler defaults for the values of CFLAGS
	and CXXINCLUDES.  This makes them _WRONG_:

	.if defined(DESTDIR)
	CFLAGS+= -I${DESTDIR}/usr/include
	CXXINCLUDES+= -I${DESTDIR}/usr/include/g++
	.endif

o	Look in /usr/share/bsd.lib.mk: it does the same thing:

	.if defined(DESTDIR)
	CFLAGS+= -I${DESTDIR}/usr/include
	CXXINCLUDES+= -I${DESTDIR}/usr/include/g++
	.endif

Specifically, you get the _WRONG_ <rtti> and other C++ header
files, which makes exceptions and run time type information
_NOT WORK_.

See also:

http://www.FreeBSD.org/cgi/cvsweb.cgi/src/share/mk/bsd.prog.mk?rev=1.86.2.3&content-type=text/x-cvsweb-markup

http://www.FreeBSD.org/cgi/cvsweb.cgi/src/share/mk/bsd.lib.mk?rev=1.91.2.1&content-type=text/x-cvsweb-markup

The /usr/include/g++ files are _WRONG_...

The /usr/local/include/g++ are _RIGHT_...

The BSD .mk files insist on using the wrong .mk files; I don't
know how much clearer I can make it?!?


-- Terry

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3AFAB3A9.798899F>