public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Re: Install gcc
       [not found] <5e6238c2.1c69fb81.e2203.5452SMTPIN_ADDED_BROKEN@mx.google.com>
@ 2020-03-06 12:08 ` Jonathan Wakely
  2020-03-06 12:52   ` yilu
       [not found]   ` <5e624788.1c69fb81.a0d08.4515SMTPIN_ADDED_BROKEN@mx.google.com>
  0 siblings, 2 replies; 5+ messages in thread
From: Jonathan Wakely @ 2020-03-06 12:08 UTC (permalink / raw)
  To: yilu; +Cc: gcc-help

On Fri, 6 Mar 2020 at 11:49, yilu@bupt.edu.cn <yilu@bupt.edu.cn> wrote:
>
> Hi, everybody.
> I'm trying install gcc, with command:
>
> ./gcc/configure --prefix=/gccobj --disable-checking --enable-languages=all --disable-multilib --disable-bootstrap --with-gmp=/gmp --with-mpfr==/mpfr --with-mpc==/mpc

This is a really really bad idea. The build will create a
sub-directory called 'gcc' which is the directory where you have the
source tree.

https://gcc.gnu.org/install/configure.html says
"First, we **highly** recommend that GCC be built into a separate
directory from the sources which does **not** reside within the source
tree."

> (I've installed mpfr,mpc,gmp in the corresponding directory)

My recommendation is that you don't do that either.
See https://gcc.gnu.org/wiki/InstallingGCC


> and I got this two information after a lot of checkings:
>
> configure: creating ./config.status
> config.status: creating Makefile
>
> and then I try the command
>
> make -j4
>
> and I got
>
> make[1]: Leaving directory '/root'
> Makefile:959: recipe for target 'all' failed
> make: *** [all] Error 2

This is completely usleless information. The error happened much
earlier but you've just shown the very end of the output which says
"there was an error">

>
> I searched for FAQ, but cannot find an approach. What can I do in this situation?

See https://gcc.gnu.org/wiki/InstallingGCC

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Re: Install gcc
  2020-03-06 12:08 ` Install gcc Jonathan Wakely
@ 2020-03-06 12:52   ` yilu
  2020-03-06 13:03     ` Henri Cloetens
       [not found]   ` <5e624788.1c69fb81.a0d08.4515SMTPIN_ADDED_BROKEN@mx.google.com>
  1 sibling, 1 reply; 5+ messages in thread
From: yilu @ 2020-03-06 12:52 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: gcc-help

Oh...I'm so sorry. I've read these guides but I miss that I should go into the objdir to configure. Thanks!
This time I got into the objdir and use:
`./../gcc/configure --prefix=/usr/local/gcc --enable-languages=all --disable-multilib --disable-bootstrap`
and I found the Makefile in my objdir directory. I try `make -j4` and found 
g++: error: gengtype-lex.c: No such file or directory
g++: fatal error: no input files
Could you help me with this?


Beenle Yi
yilu@bupt.edu.cn
 
From: Jonathan Wakely
Date: 2020-03-06 20:08
To: yilu@bupt.edu.cn
CC: gcc-help
Subject: Re: Install gcc
On Fri, 6 Mar 2020 at 11:49, yilu@bupt.edu.cn <yilu@bupt.edu.cn> wrote:
>
> Hi, everybody.
> I'm trying install gcc, with command:
>
> ./gcc/configure --prefix=/gccobj --disable-checking --enable-languages=all --disable-multilib --disable-bootstrap --with-gmp=/gmp --with-mpfr==/mpfr --with-mpc==/mpc
 
This is a really really bad idea. The build will create a
sub-directory called 'gcc' which is the directory where you have the
source tree.
 
https://gcc.gnu.org/install/configure.html says
"First, we **highly** recommend that GCC be built into a separate
directory from the sources which does **not** reside within the source
tree."
 
> (I've installed mpfr,mpc,gmp in the corresponding directory)
 
My recommendation is that you don't do that either.
See https://gcc.gnu.org/wiki/InstallingGCC
 
 
> and I got this two information after a lot of checkings:
>
> configure: creating ./config.status
> config.status: creating Makefile
>
> and then I try the command
>
> make -j4
>
> and I got
>
> make[1]: Leaving directory '/root'
> Makefile:959: recipe for target 'all' failed
> make: *** [all] Error 2
 
This is completely usleless information. The error happened much
earlier but you've just shown the very end of the output which says
"there was an error">
 
>
> I searched for FAQ, but cannot find an approach. What can I do in this situation?
 
See https://gcc.gnu.org/wiki/InstallingGCC
 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Re: Install gcc
       [not found]   ` <5e624788.1c69fb81.a0d08.4515SMTPIN_ADDED_BROKEN@mx.google.com>
@ 2020-03-06 12:56     ` Jonathan Wakely
  2020-03-06 13:52       ` yilu
  0 siblings, 1 reply; 5+ messages in thread
From: Jonathan Wakely @ 2020-03-06 12:56 UTC (permalink / raw)
  To: yilu; +Cc: gcc-help

On Fri, 6 Mar 2020 at 12:52, yilu@bupt.edu.cn wrote:
>
> Oh...I'm so sorry. I've read these guides but I miss that I should go into the objdir to configure. Thanks!
> This time I got into the objdir and use:
> `./../gcc/configure --prefix=/usr/local/gcc --enable-languages=all --disable-multilib --disable-bootstrap`
> and I found the Makefile in my objdir directory. I try `make -j4` and found
> g++: error: gengtype-lex.c: No such file or directory
> g++: fatal error: no input files
> Could you help me with this?

See https://gcc.gnu.org/install/prerequisites.html

Flex version 2.5.4 (or later)
Necessary when modifying *.l files.
Necessary to build GCC during development because the generated output
files are not included in the version-controlled source repository.
They are included in releases.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Install gcc
  2020-03-06 12:52   ` yilu
@ 2020-03-06 13:03     ` Henri Cloetens
  0 siblings, 0 replies; 5+ messages in thread
From: Henri Cloetens @ 2020-03-06 13:03 UTC (permalink / raw)
  To: gcc-help

Hello Yi,

- First, you should create build directories for all components. 
(Jonathan explained this.)
- I would recommend you put the commands to do the configure in 
scripting files, for
   repeatability.
- Then, if you encounter errors, you need to find the "config.log" files 
that contains
   the relevant information.
- I mean with that, during the build, it writes quite some config.log 
files, you find mine below.
   One of these contain statements it finished in error. You need to 
find it, try to understand
   why it failed, and if you need help, post it here.

Best Regards,

Henri

  du -a | grep config | grep log
32    ./config.log
36    ./intl/config.log
132    ./build-x86_64-pc-linux-gnu/libiberty/config.log
40    ./build-x86_64-pc-linux-gnu/fixincludes/config.log
64    ./build-x86_64-pc-linux-gnu/libcpp/config.log
32    ./lto-plugin/config.log
132    ./libiberty/config.log
24    ./zlib/config.log
48    ./libbacktrace/config.log
28    ./libdecnumber/config.log
40    ./fixincludes/config.log
64    ./libcpp/config.log
248    ./gcc/config.log




On 03/06/2020 01:51 PM, yilu@bupt.edu.cn wrote:
> Oh...I'm so sorry. I've read these guides but I miss that I should go into the objdir to configure. Thanks!
> This time I got into the objdir and use:
> `./../gcc/configure --prefix=/usr/local/gcc --enable-languages=all --disable-multilib --disable-bootstrap`
> and I found the Makefile in my objdir directory. I try `make -j4` and found
> g++: error: gengtype-lex.c: No such file or directory
> g++: fatal error: no input files
> Could you help me with this?
>
>
> Beenle Yi
> yilu@bupt.edu.cn
>   
> From: Jonathan Wakely
> Date: 2020-03-06 20:08
> To: yilu@bupt.edu.cn
> CC: gcc-help
> Subject: Re: Install gcc
> On Fri, 6 Mar 2020 at 11:49, yilu@bupt.edu.cn <yilu@bupt.edu.cn> wrote:
>> Hi, everybody.
>> I'm trying install gcc, with command:
>>
>> ./gcc/configure --prefix=/gccobj --disable-checking --enable-languages=all --disable-multilib --disable-bootstrap --with-gmp=/gmp --with-mpfr==/mpfr --with-mpc==/mpc
>   
> This is a really really bad idea. The build will create a
> sub-directory called 'gcc' which is the directory where you have the
> source tree.
>   
> https://gcc.gnu.org/install/configure.html says
> "First, we **highly** recommend that GCC be built into a separate
> directory from the sources which does **not** reside within the source
> tree."
>   
>> (I've installed mpfr,mpc,gmp in the corresponding directory)
>   
> My recommendation is that you don't do that either.
> See https://gcc.gnu.org/wiki/InstallingGCC
>   
>   
>> and I got this two information after a lot of checkings:
>>
>> configure: creating ./config.status
>> config.status: creating Makefile
>>
>> and then I try the command
>>
>> make -j4
>>
>> and I got
>>
>> make[1]: Leaving directory '/root'
>> Makefile:959: recipe for target 'all' failed
>> make: *** [all] Error 2
>   
> This is completely usleless information. The error happened much
> earlier but you've just shown the very end of the output which says
> "there was an error">
>   
>> I searched for FAQ, but cannot find an approach. What can I do in this situation?
>   
> See https://gcc.gnu.org/wiki/InstallingGCC
>   


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Re: Install gcc
  2020-03-06 12:56     ` Jonathan Wakely
@ 2020-03-06 13:52       ` yilu
  0 siblings, 0 replies; 5+ messages in thread
From: yilu @ 2020-03-06 13:52 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: gcc-help

On Fri, 6 Mar 2020 at 12:52, yilu@bupt.edu.cn wrote:
>
> Oh...I'm so sorry. I've read these guides but I miss that I should go into the objdir to configure. Thanks!
> This time I got into the objdir and use:
> `./../gcc/configure --prefix=/usr/local/gcc --enable-languages=all --disable-multilib --disable-bootstrap`
> and I found the Makefile in my objdir directory. I try `make -j4` and found
> g++: error: gengtype-lex.c: No such file or directory
> g++: fatal error: no input files
> Could you help me with this?

See https://gcc.gnu.org/install/prerequisites.html

Flex version 2.5.4 (or later)
Necessary when modifying *.l files.
Necessary to build GCC during development because the generated output
files are not included in the version-controlled source repository.
They are included in releases.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-03-06 13:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <5e6238c2.1c69fb81.e2203.5452SMTPIN_ADDED_BROKEN@mx.google.com>
2020-03-06 12:08 ` Install gcc Jonathan Wakely
2020-03-06 12:52   ` yilu
2020-03-06 13:03     ` Henri Cloetens
     [not found]   ` <5e624788.1c69fb81.a0d08.4515SMTPIN_ADDED_BROKEN@mx.google.com>
2020-03-06 12:56     ` Jonathan Wakely
2020-03-06 13:52       ` yilu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).