Bug 37210 - Discourage Default Builds in the GCC Source Tree more strongly
Summary: Discourage Default Builds in the GCC Source Tree more strongly
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: other (show other bugs)
Version: 4.4.0
: P3 enhancement
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords: build
Depends on:
Blocks:
 
Reported: 2008-08-23 11:51 UTC by Tom Browder
Modified: 2020-11-06 22:14 UTC (History)
5 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2018-06-11 00:00:00


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Browder 2008-08-23 11:51:00 UTC
The gcc configuration instructions *highly* recommend building outside the gcc source tree, and often, following the gcc-help list, I see that doing so causes problems.  I propose that the build process be modified so as to default to *failing* to build under those circumstances.  Add a configuration variable, if necessary, to allow such a build.

In the meantime, I recommend that the "highly" recommendation be changed to some more mandatory language unless the user is a gcc developer.
Comment 1 Andrew Pinski 2008-08-24 21:29:40 UTC
Well it is not prohibited, it is supported to do the build in the src directory, just not recommended as it is not tested really and can (I think 4.3.x has a bug dealing with fixed includes) be broken even for releases.
Comment 2 Tom Browder 2008-08-24 22:07:17 UTC
Andrew, you're right--it's not prohibited, but my argument is that it should be prohibited as the default build (but have a specific configure variable to allow it), at least until it is tested.  Over the years I've watched people have a build  problem, and the first thing the gurus tell them is *don't* build in the gcc tree, so this enhancement would at least get newbies' attention instead of continuing to waste help bandwidth.  Note the recommendation to not build in the tree has been around I'll guess for at least ten years.  And with the complexity of the build I doubt that the tested in-tree build will ever be a requirement for a release.

I envision a short but succinct message telling about the prohibition and adding a link to more detail.  The installation instructions should perhaps have text enhancement or other edits to highlight the reason for the prohibition.  
Comment 3 Manuel López-Ibáñez 2008-08-25 20:41:14 UTC
I think this is a great idea. A good error with a long explanation will save a lot of time for a lot of people. I don't think you even need the configure option to allow it. I cannot see why anyone would need to build in the source directory.

Care to provide a patch?
Comment 4 Ralf Wildenhues 2009-09-21 16:44:26 UTC
With PR 35619 fixed in trunk it works fine for me to build in the source tree.
Feel free to Cc: me on new bugs arising from an in-tree build.
(Leaving bug open as it addresses 4.4 not trunk.)
Comment 5 Ralf Wildenhues 2010-09-26 13:44:43 UTC
status update: <http://gcc.gnu.org/ml/gcc-patches/2010-09/msg02033.html>.
Comment 6 Eric Gallager 2018-03-11 14:03:32 UTC
I'm going to confirm this with a slightly modified title
Comment 7 Eric Gallager 2018-06-11 05:35:16 UTC
(In reply to Eric Gallager from comment #6)
> I'm going to confirm this with a slightly modified title

Oops, I didn't actually confirm this when I said so; hopefully it'll do it this time.