Het installeren van de GCC-compiler in Ubuntu kan worden gedaan door deze stappen te volgen:
1. Open een terminaltoepassing op uw Ubuntu-systeem.
2. Update de pakketlijsten van uw systeem:
```
sudo apt-update
```
3. Installeer het build-essential-pakket, dat de GCC-compiler en andere noodzakelijke ontwikkelingstools bevat:
```
sudo apt install build-essential
```
4. Deze opdracht zou gcc en alle noodzakelijke afhankelijkheden moeten installeren.
5. Controleer de installatie van de GCC-compiler door de versie-informatie af te drukken:
```
gcc-v
```
Deze opdracht zou een uitvoer moeten weergeven die er ongeveer als volgt uitziet:
```
Ingebouwde specificaties gebruiken.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/9/lto-wrapper
Doel:x86_64-linux-gnu
Geconfigureerd met:../src/configure -v --with-pkgversion='Ubuntu 9.3.0-17ubuntu1~20.04' --with-bugurl=file:///usr/share/doc/gcc-9/README. Bugs --enable-talen=c,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=/usr --with-gcc-major-version-only --with-system-zlib --enable-shared --enable-linker-build-id --with-threads=posix --libexecdir=/usr/lib --with-arch-32=x86_32 --with-tune=generic --enable-checking =release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu --program-suffix=-9 --with-default-libstdcxx-abi=new -- enable-gri=no --with-gcc-parallelism=1 --with-mpfr-dir=/usr/lib/x86_64-linux-gnu/mpfr --with-gmp-dir=/usr/lib/x86_64-linux -gnu/gmp --with-mpc-dir=/usr/lib/x86_64-linux-gnu/mpc --with-isl-dir=/usr/lib/x86_64-linux-gnu/isl --enable-libatomic - -with-libgomp-dir=/usr/lib/x86_64-linux-gnu --enable-libstdcxx-filesystem-ts --enable-libstdcxx-time-ts --with-default-libstdcxx-fs-compatibel --enable- gnu-unique-object --enable-plugin --with-system-libunwind --with-plugin-opt=-D_GLIBCXX_USE_CXX11_ABI=0 --enable-linker-build-id --enable-lto --with-linker-hash -style=gnu --with-gold --enable-default-pie --enable-default-ssp --with-linker-output-file=ld --enable-threads=posix
Draadmodel:posix
gcc versie 9.3.0 (Ubuntu 9.3.0-17ubuntu1~20.04)
``` |