docker4AmigaVBCC is a project that contains a few docker images with VBCC compiler, for cross compiling software for AmigaOS 3, AmigaOS 4 and MorphOS. It is based on Ubuntu OS and has everything needed (vbcc compiler, SDKs, libraries) for compiling your applications.
The purpose of the project is to be an up to date, flexible and out of the box solution for cross compiling applications for Amiga environments, using the VBCC C/C++ compiler. Those images can be used on CI/CD solution for automatic testing, compiling, packaging and deployment.
The docker4amigavbcc:latest-m68k image contains the following software, including the Base image software:
app | version | source |
---|---|---|
vbcc | 0.9h p3 (29-Apr-2022) | http://sun.hasenbraten.de/vbcc/ |
vasm | v1.9f (11-Nov-2023) | http://phoenix.owl.de/tags/ |
NDK | 3.9 | http://www.haage-partner.de/download/AmigaOS/ |
NDK | 3.2R4 | https://aminet.net/package/dev/misc/NDK3.2R3 |
AmiSSL SDK | 5.12 | https://github.com/jens-maus/amissl/releases/tag/5.12 |
MUI 3.x dev | 3.8 | https://github.com/amiga-mui/muidev/releases/tag/3.8 |
MUI 5.x dev | MUI 5.0-20210831 | https://github.com/amiga-mui/muidev/releases/tag/MUI-5.0-20210831 |
MCC_GuiGfx | 19.2 (only on MUI3SDK) | http://aminet.net/package/dev/mui/MCC_Guigfx |
MCC_TextEditor | 15.56 | http://aminet.net/package/dev/mui/MCC_TextEditor-15.56 |
Roadshow SDK | 1.4 (15.3.2019) | https://www.amigafuture.de/app.php/dlext/?view=detail&df_id=3658 |
Posix Lib | 2.6 | http://aminet.net/package/dev/c/vbcc_PosixLib |
sqlite | 3.34.0 | https://aminet.net/package/biz/dbase/sqlite-3.34.0-amiga |
The docker4amigavbcc:latest-ppc image contains the following software, including the Base image software:
app | version | source |
---|---|---|
vbcc | 0.9h p3 (29-Apr-2022) | http://sun.hasenbraten.de/vbcc/ |
vasm | v1.9f (11-Nov-2023) | http://phoenix.owl.de/tags/ |
AmiSSL SDK | 5.12 | https://github.com/jens-maus/amissl/releases/tag/5.12 |
AmigaOS 4 SDK | 54.16 | http://www.hyperion-entertainment.com/ |
MUI 5.x dev | MUI 5.0-20210831 | https://github.com/amiga-mui/muidev/releases/tag/MUI-5.0-20210831 |
MCC_GuiGfx | Since MUI 5.0-2020R2 this is included in MUI | |
sqlite | 3.34.0 | https://aminet.net/package/biz/dbase/sqlite-3.34.0-amiga |
The docker4amigavbcc:latest-mos image contains the following software, including the Base image software:
app | version | source |
---|---|---|
vbcc | 0.9h p3 (29-Apr-2022) | http://sun.hasenbraten.de/vbcc/ |
vasm | v1.9f (11-Nov-2023) | http://phoenix.owl.de/tags/ |
AmiSSL SDK | 5.12 | https://github.com/jens-maus/amissl/releases/tag/5.12 |
MUI 3.x dev | 3.8 | https://github.com/amiga-mui/muidev/releases/tag/3.8 |
MUI 5.x dev | MUI 5.0-20210831 | https://github.com/amiga-mui/muidev/releases/tag/MUI-5.0-20210831 |
MCC_GuiGfx | 19.2 (only on MUI3SDK) | http://aminet.net/package/dev/mui/MCC_Guigfx |
MCC_TextEditor | 15.56 | http://aminet.net/package/dev/mui/MCC_TextEditor-15.56 |
sqlite | 3.34.0 | https://aminet.net/package/biz/dbase/sqlite-3.34.0-amiga |
The docker4amigavbcc:latest-base image contains software that is common on all images, as listed bellow:
app | version | source |
---|---|---|
vlink | 0.17a (22-Sep-2022) | http://sun.hasenbraten.de/vlink/ |
FlexCat | 2.18 | https://github.com/jens-maus/amissl/releases/tag/5.5 |
lha | 1.14i-ac20220213 | https://github.com/jca02266/lha.git |
To create a container based on one of these images, run in the terminal:
docker run -it --rm --name amigavbcc-m68k -v ${PWD}/code:/opt/code -w /opt/code walkero/docker4amigavbcc:latest-m68k /bin/bash
docker run -it --rm --name amigavbcc-ppc -v ${PWD}/code:/opt/code -w /opt/code walkero/docker4amigavbcc:latest-ppc /bin/bash
docker run -it --rm --name amigavbcc-mos -v ${PWD}/code:/opt/code -w /opt/code walkero/docker4amigavbcc:latest-mos /bin/bash
If you want to use it with docker-compose, you can create a docker-compose.yml file, with the following content:
version: '3'
services:
vbcc-m68k:
image: 'walkero/docker4amigavbcc:latest-m68k'
volumes:
- './code:/opt/code'
vbcc-ppc:
image: 'walkero/docker4amigavbcc:latest-ppc'
volumes:
- './code:/opt/code'
vbcc-mos:
image: 'walkero/docker4amigavbcc:latest-mos'
volumes:
- './code:/opt/code'
And then you can create and get into the container by doing the following:
docker-compose up -d
docker-compose vbcc-m68k exec bash
docker-compose vbcc-ppc exec bash
docker-compose vbcc-mos exec bash
To compile your project you have to get into the container, inside the /opt/code/projectname folder, which is shared with the host machine, and run the compilation.
The docker4amigavbcc:latest-m68k image has the following ENV variables set:
- VBCC: /opt/vbcc
- PATH: /opt/vbcc/bin
- NDK_INC: /opt/sdk/NDK_3.9/Include/include_h
- NDK_LIB: /opt/sdk/NDK_3.9/Include/linker_libs
- NDK32_INC: /opt/sdk/NDK3.2/Include_H
- NDK32_LIB: /opt/sdk/NDK3.2/lib
- MUI38_INC: /opt/sdk/MUI_3.8/C/Include
- MUI50_INC: /opt/sdk/MUI_5.0/C/include
- TCP_INC: /opt/sdk/Roadshow-SDK/include
- NET_INC: /opt/sdk/Roadshow-SDK/netinclude
- AMISSL_INC: /opt/sdk/AmiSSL/include
- POSIXLIB_INC: /opt/sdk/PosixLib/include
- SQLITE_INC: /opt/sdk/sqlite/include
The docker4amigavbcc:latest-ppc image has the following ENV variables set:
- VBCC: /opt/vbcc
- PATH: /opt/vbcc/bin
- AOS4_SDK_INC: /opt/sdk/ppc-amigaos/Include/include_h
- AOS4_NET_INC: /opt/sdk/ppc-amigaos/Include/netinclude
- AOS4_NLIB_INC: /opt/sdk/ppc-amigaos/newlib/include
- AOS4_CLIB_INC: /opt/sdk/ppc-amigaos/clib2/include
- MUI50_INC: /opt/sdk/MUI_5.0/C/include
The docker4amigavbcc:latest-mos image has the following ENV variables set:
- VBCC: /opt/vbcc
- PATH: /opt/vbcc/bin
- NDK_INC: /opt/sdk/NDK_3.9/Include/include_h
- NDK_LIB: /opt/sdk/NDK_3.9/Include/linker_libs
- MUI38_INC: /opt/sdk/MUI_5.0/C/include
- MUI50_INC: /opt/sdk/MUI_5.0/C/include
- AMISSL_INC: /opt/sdk/AmiSSL/include
- SQLITE_INC: /opt/sdk/sqlite/include
You can set your own paths, if you want, by using environment variables on docker execution or inside the docker-compose.yml file, like:
docker run -it --rm --name amigavbcc-m68k -v ${PWD}/code:/opt/code -w /opt/code -e NDK_INC="/your/folder/path" walkero/docker4amigavbcc:latest-m68k /bin/bash
docker run -it --rm --name amigavbcc-ppc -v ${PWD}/code:/opt/code -w /opt/code -e AOS4_SDK_INC="/your/folder/path" walkero/docker4amigavbcc:latest-ppc /bin/bash
docker run -it --rm --name amigavbcc-mos -v ${PWD}/code:/opt/code -w /opt/code -e MOS_SDK_INC="/your/folder/path" walkero/docker4amigavbcc:latest-mos /bin/bash
docker-compose.yml
version: '3'
services:
vbcc-m68k:
image: 'walkero/docker4amigavbcc:latest-m68k'
environment:
NDK_INC: "/opt/ext_sdk/NDK_3.9/Include/include_h"
volumes:
- './code:/opt/code'
- './ext_sdk:/opt/ext_sdk'
vbcc-ppc:
image: 'walkero/docker4amigavbcc:latest-ppc'
environment:
AOS4_SDK_INC: "/opt/ext_sdk/SDK_install/Include/include_h"
volumes:
- './code:/opt/code'
- './ext_sdk:/opt/ext_sdk'
vbcc-mos:
image: 'walkero/docker4amigavbcc:latest-mos'
environment:
MOS_SDK_INC: "/opt/ext_sdk/Development/gg/include"
volumes:
- './code:/opt/code'
- './ext_sdk:/opt/ext_sdk'
Roadshow SDK is included in docker4amigavbcc:latest-m68k image since version tag 1.1-m68k, with the kind permission from Andreas Magerl. Thank you Andreas for your help.
Under the folder code
you will find some demo scripts that can be compiled with this vbcc docker installation
- m68k/hello.c - Just a simple Hello World script
- m68k/openwin.c - This is a simple code that opens a window on Workbench, as found at Ozzyboshi DockerAmigaVbcc repo
- m68k/Amiga_C_MUI_Examples - A couple of MUI examples as found at Amiga C MUI Examples with update Makefiles to use VBCC
- aosppc/Window - A few example codes from AmigaOS 4 SDK
- aosppc/https.c - An amissl example file as found at AmiSSL SDK
The images have a user named vbcc, and a group with the same name. The user and group ID is 1000, which match with host's machine user IDs. This way both users, from the host and from the container, should have the same permissions on the files created.
If you need to change the IDs with your own, set the following ENV variables when you start the docker containers
VBCC_USER_ID
VBCC_GROUP_ID
I recommend to use VSCode with Remote - Containers extension installed. You can use that extension to connect on the running VBCC container. If you want automatically to set the extensions, set the user and other configuration for each container, after you attach to it select from action menu (F1) the "Remote-Containers: Open Container Configuration FIle" and add the configuration based on your preference. Below is my own example:
{
"extensions": [
"donjayamanne.githistory",
"eamodio.gitlens",
"EditorConfig.EditorConfig",
"Gruntfuggly.todo-tree",
"ms-vscode.cpptools",
"patricklee.vsnotes",
"prb28.amiga-assembly",
"SanaAjani.taskrunnercode"
],
"workspaceFolder": "/opt/code",
"remoteUser": "amidev"
}
If you have any issues with the images or you need help on using them or you would like to request any new feature, please contact me by opening an issue at https://github.com/walkero-gr/docker4AmigaVBCC/issues
The docker4amigavbcc:latest-m68k docker image is based on the following sources: