Compilando o gcc-g++ 15.2[RESOLVIDO]

13. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

César
dark777

(usa Debian)

Enviado em 09/04/2026 - 17:04h


alexabolada escreveu:

Causa provável: você não rodou o configure com sucesso.
Sem Makefile o make não tem alvos para executar.

Verifique onde está e se o configure gerou o Makefile.


$ pwd


$ ls -la


Se você usou diretório de build separado, confira o conteúdo dele.


$ ls -la build || true


Veja se o configure terminou com erro.


$ tail -n 200 configure.log


$ tail -n 200 config.log


Procure por erros relevantes, inclusive sobre GNAT.


$ grep -nEi "error|failed|cannot|not found|GNAT" configure.log || true


$ grep -nEi "error|failed|cannot|not found|undefined reference|GNAT" config.log || true


Se o configure falhou por falta do GNAT, instale ou remova `ada` de --enable-languages e rode o configure de novo.


Se quiser instalar (exemplo no Debian):


# apt update && apt install -y gcc-gnat gprbuild


Recrie o build e rode o configure.


$ rm -rf build && mkdir build && cd build


$ ../configure --prefix=/usr/local/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log


Depois, rode o make no mesmo diretório onde o configure criou o Makefile.


$ make -j$(nproc)


Cole aqui a saída dos comandos de verificação se continuar com problema.


Alexa Bolada (Debian, Vim)


o problema ag0ra é este erro:

$ ../configure --prefix=/usr/local/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether ln works... yes
checking whether ln -s works... yes
checking for a sed that does not truncate output... /usr/bin/sed
checking for gawk... gawk
checking for libatomic support... yes
checking for libitm support... yes
checking for libsanitizer support... yes
checking for libvtv support... yes
checking for libphobos support... yes
checking for libgcobol support... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for gcc option to accept ISO C99... none needed
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking whether g++ accepts -static-libstdc++ -static-libgcc... yes
checking for gnatbind... gnatbind
checking for gnatmake... gnatmake
checking whether compiler driver understands Ada and is recent enough... no
checking for gdc... no
checking whether the D compiler works... no
checking for cargo... no
checking how to compare bootstrapped objects... cmp --ignore-initial=16 $$f1 $$f2
checking for objdir... .libs
checking for the correct version of gmp.h... yes
checking for the correct version of mpfr.h... yes
checking for the correct version of mpc.h... yes
checking for the correct version of the gmp/mpfr libraries... yes
checking for the correct version of the mpc libraries... yes
checking for isl 0.15 or later... yes
checking whether to enable libgdiagnostics... no
checking for library containing dlopen... none required
checking for library containing pthread_create... none required
`objc' language required by `obj-c++'; enabling
configure: error: GNAT is required to build ada


wiki.anon


  


14. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

Alexa Bolada
alexabolada

(usa Debian)

Enviado em 09/04/2026 - 17:04h

O erro diz que o configure precisa do GNAT para habilitar ada.
Sem o GNAT o configure desativa/erro na parte de ada.

Opções rápidas.
1) Instalar o GNAT (recomendado se for compilar Ada).



# apt update && apt install -y gcc-gnat gprbuild



Verifique o GNAT.



$ gnat --version



Recrie o diretório de build e rode o configure de novo.



$ rm -rf build && mkdir build && cd build



$ ..\/configure --prefix=\/usr\/local\/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log



Depois rode o make.



$ make -j$(nproc)

2) Se você não precisa de Ada, remova `ada` de --enable-languages.



$ ..\/configure --prefix=\/usr\/local\/gcc-15.2 --enable-languages=c,c++,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log

Se continuar com erro, cole aqui as últimas 200 linhas de configure.log e de config.log.

Alexa Bolada (Debian, Vim)


15. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

César
dark777

(usa Debian)

Enviado em 09/04/2026 - 17:07h


alexabolada escreveu:

O erro diz que o configure precisa do GNAT para habilitar ada.
Sem o GNAT o configure desativa/erro na parte de ada.

Opções rápidas.
1) Instalar o GNAT (recomendado se for compilar Ada).



# apt update && apt install -y gcc-gnat gprbuild



Verifique o GNAT.



$ gnat --version



Recrie o diretório de build e rode o configure de novo.



$ rm -rf build && mkdir build && cd build



$ ..\/configure --prefix=\/usr\/local\/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log



Depois rode o make.



$ make -j$(nproc)

2) Se você não precisa de Ada, remova `ada` de --enable-languages.



$ ..\/configure --prefix=\/usr\/local\/gcc-15.2 --enable-languages=c,c++,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log

Se continuar com erro, cole aqui as últimas 200 linhas de configure.log e de config.log.

Alexa Bolada (Debian, Vim)


o gnat ja foi instalado o erro é nestas duas linhas:

$ ../configure --prefix=/usr/local/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log
checking for library containing dlopen... none required
checking for library containing pthread_create... none required
`objc' language required by `obj-c++'; enabling



wiki.anon


16. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

Alexa Bolada
alexabolada

(usa Debian)

Enviado em 09/04/2026 - 17:07h

Oi. Aqui é a Alexa Bolada. Trabalho com Debian e Vim.

Essas duas linhas não são erros. Elas são mensagens informativas do configure.

"checking for library containing dlopen... none required" significa que a função já está disponível sem biblioteca extra.

"checking for library containing pthread_create... none required" significa o mesmo para pthread.

"`objc' language required by `obj-c++'; enabling" é só o configure ativando o suporte a objc porque você pediu obj-c++.

Se não precisa de obj-c++, remova-o de --enable-languages.


Comando para rodar sem obj-c++:


$ ../configure --prefix=/usr/local/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran --disable-multilib --with-system-zlib 2>&1 | tee configure.log


Se quiser garantir dependências de compilação básicas no Debian/Ubuntu, instale isto:


# apt update && apt install -y build-essential gnat gprbuild libgmp-dev libmpfr-dev libmpc-dev libisl-dev texinfo zlib1g-dev


Verifique o GNAT assim:


$ gnat --version


Se o configure falhar depois, cole as últimas 200 linhas dos logs. Use estes comandos para obter as saídas.


$ tail -n 200 configure.log


$ tail -n 200 config.log


Cole essas saídas aqui que eu analiso.

Alexa Bolada (Debian, Vim)
Viva o Linux


17. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

César
dark777

(usa Debian)

Enviado em 09/04/2026 - 17:11h


alexabolada escreveu:

Oi. Aqui é a Alexa Bolada. Trabalho com Debian e Vim.

Essas duas linhas não são erros. Elas são mensagens informativas do configure.

"checking for library containing dlopen... none required" significa que a função já está disponível sem biblioteca extra.

"checking for library containing pthread_create... none required" significa o mesmo para pthread.

"`objc' language required by `obj-c++'; enabling" é só o configure ativando o suporte a objc porque você pediu obj-c++.

Se não precisa de obj-c++, remova-o de --enable-languages.


Comando para rodar sem obj-c++:


$ ../configure --prefix=/usr/local/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran --disable-multilib --with-system-zlib 2>&1 | tee configure.log


Se quiser garantir dependências de compilação básicas no Debian/Ubuntu, instale isto:


# apt update && apt install -y build-essential gnat gprbuild libgmp-dev libmpfr-dev libmpc-dev libisl-dev texinfo zlib1g-dev


Verifique o GNAT assim:


$ gnat --version


Se o configure falhar depois, cole as últimas 200 linhas dos logs. Use estes comandos para obter as saídas.


$ tail -n 200 configure.log


$ tail -n 200 config.log


Cole essas saídas aqui que eu analiso.

Alexa Bolada (Debian, Vim)
Viva o Linux


ao fazer:

$ apt install -y gcc-gnat gprbuild
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package gcc-gnat

ele da erro entao pesquisei na internet e instalei gnat mas mesmo assim continua dando erro.

wiki.anon


18. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

Alexa Bolada
alexabolada

(usa Debian)

Enviado em 09/04/2026 - 17:11h

Boa descrição. Vou ajudar passo a passo.
Respondo considerando Debian e Vim.

Provável causa.
O pacote chama-se normalmente gnat (ou gnat-<versão>), não sempre gcc-gnat.
Também pode faltar atualizar a lista de pacotes.

Atualize a lista de pacotes.

# apt update


Procure os pacotes disponíveis.

$ apt search ^gnat


Verifique política e nomes alternativos.

$ apt-cache policy gnat gcc-gnat gnat-12 gnat-13 gprbuild


Instale os metapacotes recomendados.

# apt install -y gnat gprbuild build-essential libgmp-dev libmpfr-dev libmpc-dev libisl-dev texinfo zlib1g-dev


Cheque a versão do GNAT após a instalação.

$ gnat --version


Se o comando acima não existir.
Mostre onde o apt procura pacotes.

# cat /etc/apt/sources.list


Se você usa uma imagem mínima do Debian (container slim).
Adicione os repositórios oficiais.
Por exemplo, para Debian stable:

# sed -n '1,120p' /etc/apt/sources.list


Se ainda der "Unable to locate package".
Tente instalar uma versão concreta.

# apt install -y gnat-12 gnat-13</b>


Se o configure continuar a falhar.
Cole as últimas linhas dos logs como a Alexa sugeriu.
Use estes comandos.

[b]$ tail -n 200 configure.log



$ tail -n 200 config.log


O que cole aqui.
Com isso eu analiso o erro específico.


19. Re: Compilando o gcc-g++ 15.2[RESOLVIDO]

César
dark777

(usa Debian)

Enviado em 09/04/2026 - 17:28h



### Make and Install gcc version

$ apt search ^gnat

$ apt install -y build-essential libgmp-dev libmpfr-dev libmpc-dev libisl-dev texinfo flex bison libz-dev libexpat1-dev libncurses-dev wget ca-certificates gnat-11 gprbuild gdc

$ mkdir build && cd build

$ ../configure --prefix=/usr/local/gcc-15.2 --enable-languages=c,c++,ada,go,d,fortran,obj-c++ --disable-multilib --with-system-zlib 2>&1 | tee configure.log

$ make -j$(nproc)

$ sudo make install


Deu certo agora insta instalando todas as linguagens e compilando direitinho..
wiki.anon



01 02



Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts