This is the mail archive of the gcc-help@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: Building Relocatable gcc


Kyle Girard <kyle@kdmanalytics.com> writes:

>> What do you mean by relocatable?
>> 
>> If you use just the --prefix=DIR option, and run "make" and "make
>> install", then you can move the directory DIR wherever you like and
>> everything should continue to work.
>
> By relocatable I mean I guess self contained..  I can use --prefix and
> install the compiler to DIR, yes, but after I rename DIR to DIR2 doesn't
> gcc continue to look for it's headers in DIR?

No.  gcc uses relative paths to find its own internal headers.

> If I wanted to zip up the
> gcc in DIR and put it on another machine that doesn't have gcc installed
> on it and doesn't the directory DIR wont it still be looking for headers
> in DIR?

No.

> I'd like to make version of gcc that I can zip up and drop on to a
> machine in a directory of my choice and instantly have a version of gcc
> that I can compile things with.  Sort of like the way mingw is done but
> for linux.  

That should happen more or less automatically if you follow the simple
procedure I described above.

Ian


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