This has two main advantages: firstly it means that the Dockerfile is being tested
as part of the pipeline when changes are merged into master, and secondly it allows
testing of Linux builds without requiring a separate job for Docker that can consume
even more CI minutes.
In order to test the container image it is necessary to manually start the build
image using docker run, execute the tests, and then copy the results back to the
host ready for publishing.
Note that since the base OS image is now handled by docker we can switch the host
to use the 'ubuntu-latest' image rather than the older 'ubuntu-20.04' image.
Use the docker multi-stage build functionality to perform the Retro68 build in a
temporary build image, and then copy the final build directory into a fresh
release image. This reduces the final release image size from 9.2GB to 2.6GB.
Update Dockerfile to use Ubuntu 20.04 and the updated package list from
azure-pipelines.yml. Also explicitly include the g++ package into the container
without which configure will error out with a 'configure: error: C++ preprocessor
"/lib/cpp" fails sanity check' error.
Following the instructions as is on macOS results in `build-toolchain.bash` failing with `WARNING: 'makeinfo' is missing on your system`. The readme was updated in #59 but only for Ubuntu.
Specify parameters for all C functions. Not specifying parameters is the
same as specifying "void" in C++ and in C23 and later but that's not the
case in C prior to C23.
Compile C files with the same warnings as C++ files, additionally making
the strict prototypes warning an error to catch such problems in the
future. This commit isn't intended to address all the other warnings now
being emitted.
When copying files from the system disk image to the new disk image,
preserve all attributes (creation date, modification date, bundle bit,
locked bit, etc.), except clear the inited bit so that the Finder
chooses new icon positions, otherwise (under System 6 at least) the
icons pile up on top of each other. Preserving the bundle bit in
particular tells the Finder to look in the file for icon information
when building the desktop database, without which the files all show
generic icons in the Finder.
Move the System file resource-reading code out of GetSystemVersion and
into a new ReadSystemResources method which stores the resources in a
new member variable so that it can be used by multiple methods.
* Convert all field values from host order to big-endian so they aren't
byte-swapped when created on little-endian systems.
* Pack the struct so the compiler doesn't insert padding on 64-bit
systems.
* Fix the volume and file creation timestamps by converting them from
UNIX to Macintosh time base, using a function copied from hfsutils.
* Pad volume and file names with null bytes instead of random memory.
* Add the "end of variable-length data" marker so the OS doesn't crash
when trying to resolve the alias.
* Set the alias flag so the OS treats the file as an alias.
This allows generated rez files to be listed in add_application by their
full path in the build directory, e.g. ${CMAKE_CURRENT_BINARY_DIR}/foo.r
Closes#176