This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Unreviewed patches


> When building a cross compiler to a hosted OS, you have two options:
>
> - use --with-headers/--with-libs (deprecated), and these will copy
>   stuff to sys-include and lib, or
>
> - use --with-sysroot, and make sure the sysroot already contains a
>   copy/link/whatever of the relevant bits of relevant headers,
>   libraries and object files you expect to find in the root filesystem
>   or the target OS.
>
>
> In either case, the goal is to not touch the install tree during
> compilation.  Sure enough, --with-headers/libs do touch the install
> tree, but they were broken by design, which is just one of the reasons
> for the switch to --with-sysroot.
>
> This is why we no longer run recursively invoke the
> install-gcc-tooldir target from stmp-fixinc, and instead just print a
> warning.

Thanks for the review and the clarification.

> One thing we could do to improve this significantly, however, is to
> take advantage of the fact that we no longer need to use
> ${gcc_tooldir} for pathnames to be relocated correctly if you move the
> install tree after installation.  I'd be quite happy to review and
> hopefully approve a change to configure.ac that changed the default
> setting of CROSS_SYSTEM_HEADER_DIR to look more like the definition in
> the --with-sysroot case, and a corresponding change in Makefile.in
> such that we not fail when compiling for embedded targets that don't
> have a root filesystem.  Would you give that a try?

Unfortunately, I know next to nothing about the makefile/configure machinery 
and have very little interest in building complete cross-toolchains for the 
time being.  I only cared about the PR because the original patch was 
modifying a file in config/sparc and thought it was not correct either.

I'm going to add a link to your suggestion in the PR audit trail.

-- 
Eric Botcazou


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]