Sign inSign up

megahertz/fpc-trunk

By megahertz

•Updated about 5 years ago

Free Pascal Compiler built from trunk repository using alpine linux image

Image
1

6.9K

megahertz/fpc-trunk repository overview

⁠fpc-trunk

Free Pascal Compiler built weekly from trunk repository using alpine linux image⁠.

This image is built from trunk repository which contains all fixes and improvements since the last official release, so please try it if you have any problems. Of course, it may also contain new bugs.

If you need the latest stable FPC image instead of dev build, try the frolvlad's image⁠.

⁠Usage

  1. Create a program, for example:

    { app.pas }
    program app;
    
    begin
      WriteLn('Hi from docker');
    end.
    
    
  2. Create a Dockerfile

    # Dockerfile
    FROM megahertz/fpc-trunk:3.1.1-39472
    
    COPY app.pas /src/my-program/app.pas
    RUN fpc /src/my-program/app.pas
    CMD /src/my-program/app
    
    
  3. Build the image and run

    docker build . -t app
    docker run app
    
⁠Troubleshooting
⁠My app can't be run on another alpine image

In most cases, the app can't find ld-linux-x86-64.so.2. There are two ways to fix that:

  • Add to your Dockerfile for the target image:

    RUN ln -s /lib /lib64 && \
        ln -s /lib/ld-musl-x86_64.so.1 /lib/ld-linux-x86-64.so.2
    
  • Compile your app with the following FPC flag:

    -FL/lib/libc.musl-x86_64.so.1

Tag summary

Content type

Image

Digest

Size

86.9 MB

Last updated

about 5 years ago

docker pull megahertz/fpc-trunk:3.3.1-49634