public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* 'posix_spawnp' error in build
@ 2023-12-25 14:41 Prashant
  2023-12-25 16:28 ` Segher Boessenkool
  0 siblings, 1 reply; 7+ messages in thread
From: Prashant @ 2023-12-25 14:41 UTC (permalink / raw)
  To: gcc-help, gcc

[-- Attachment #1: Type: text/plain, Size: 1625 bytes --]

Hello,

I'm new to the GCC community, who is willing to contribute and expand my
knowledge on compilers. I hope this is the right forum I'm asking for help.

 I'm trying to build the gcc repository. Based on the instructions given on
the SummerOfCode - GCC Wiki (gnu.org)
<https://gcc.gnu.org/wiki/SummerOfCode#Before_you_apply> and GCC for New
Contributors — GCC Contributors Guide 0.1 documentation
(gcc-newbies-guide.readthedocs.io)
<https://gcc-newbies-guide.readthedocs.io/en/latest/>, I have tried the
following commands.

1) git clone git://gcc.gnu.org/git/gcc.git
2) cd gcc & ./contrib/download_prerequisites
3) mkdir objdir & cd objdir
4) ../gcc/configure --prefix=/home/path/to/gcc --enable-languages=c,c++
5) make -j 4

Running the 5th throws the following error:
'xgcc: fatal error: cannot execute ‘cc1plus’: posix_spawnp: No such file or
directory
compilation terminated.'

I have tried to search Google and take help of ChatGPT but even the
guidance didn't resolve my issue.

Following are the solutions that I tried.

Executing the command:

1) 'sudo apt-get install --reinstall build-essential'
2) 'sudo apt-get install --reinstall g++'
3) 'unset GCC_EXEC_PREFIX'

This is based on the following pages:
php - Compile error: "g++: error trying to exec 'cc1plus': execvp: No such
file or directory" - Stack Overflow
<https://stackoverflow.com/questions/8878676/compile-error-g-error-trying-to-exec-cc1plus-execvp-no-such-file-or-dir>

and ChatGPT inputs.

I haven't been able to find a solution for the same. Any guidance/input
will be appreciated.


Thanks

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

end of thread, other threads:[~2023-12-29 22:37 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-25 14:41 'posix_spawnp' error in build Prashant
2023-12-25 16:28 ` Segher Boessenkool
2023-12-25 16:33   ` Xi Ruoyao
2023-12-25 23:00     ` Segher Boessenkool
2023-12-26 14:04       ` Prashant
2023-12-25 18:26   ` Prashant
2023-12-29 22:40   ` Dave Blanchard

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).