Return to Image List

gcc

gcc

The GNU Compiler Collection (GCC) is a compiler system produced by the GNU Project that supports various programming languages. GCC is a key component of the GNU toolchain. The Free Software Foundation (FSF) distributes GCC under the GNU General Public License (GNU GPL). GCC has played an important role in the growth of free software, as both a tool and an example.

See gcc.gnu.org for more information

This image is built by IBM to run on the IBM Z architecture and is not affiliated with any other community that provides a version of this image.


License

View license information here

As with all Docker images, these likely also contain other software which may be under other licenses (such as Bash, etc from the base distribution, along with any direct or indirect dependencies of the primary software being contained).

As for any pre-built image usage, it is the image user's responsibility to ensure that any use of this image complies with any relevant licenses for all software contained within.


Versions

Use the pull string below for the version of this image you require.
11.2.0 docker pull icr.io/ibmz/gcc@sha256:f2a5a7c9cc342753031ab5df23e9e1f5edbbfb039de277bb3d9a2806390d18df Vulnerability Report01-02-2025
12 docker pull icr.io/ibmz/gcc@sha256:75dc55ec78967e7d84c038a7f12ee2294c6ad9bbe1e0d955a2cb4722c56c31d5 Vulnerability Report01-02-2025
12.1.0-bullseye docker pull icr.io/ibmz/gcc@sha256:4a0661a610d06bdac6ed83b5634b8d82447ab57e5b582bfc17d996e1743ad53d Vulnerability Report01-02-2025
12.2.0-bullseye docker pull icr.io/ibmz/gcc@sha256:018fcc69cd907d2687bd6d32563d81bdd1cefc4617ed8358b1c21173785bfda1 Vulnerability Report01-02-2025
Version Pull String Security (IBM Cloud) Created

Usage Notes

Start a GCC instance running your app:


The most straightforward way to use this image is to use a gcc container as both the build and runtime environment. In your Dockerfile, writing something along the lines of the following will compile and run your project:

FROM icr.io/ibmz/gcc:[version]
COPY . /usr/src/myapp
WORKDIR /usr/src/myapp
RUN gcc -o myapp main.c
CMD ["./myapp"]

Then, build and run the Docker image:

docker build -t my-gcc-app .


docker run -it --rm --name my-running-app my-gcc-app