Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion buildenv/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,14 @@ RUN mkdir /buildenv

WORKDIR /buildenv

RUN curl -JO 'https://developer.apple.com/file/?file=security&agree=Yes' -H 'Referer: https://developer.apple.com/security/' && unzip corecrypto.zip
RUN curl -JO 'https://developer.apple.com/file/?file=security&agree=Yes' -H 'Referer: https://developer.apple.com/security/' && unzip corecrypto.zip && rm -rf __MACOSX && (test -d corecrypto || mv corecrypto-*/ corecrypto)
# Apple's zip references scripts/code-coverage.cmake but doesn't ship it - it's an
# external helper from https://github.com/StableCoder/cmake-scripts that CMakeLists.txt
# assumes is present (normally added via a submodule/build step not included in the zip).
RUN mkdir -p /buildenv/corecrypto/scripts && curl -sL -o /buildenv/corecrypto/scripts/code-coverage.cmake "https://raw.githubusercontent.com/StableCoder/cmake-scripts/main/code-coverage.cmake"
# CoreCryptoSources.cmake references "corecrypto_static/ccrng_static.c" but the public zip
# ships the file flat at the top level - symlink it into place under the expected path.
RUN mkdir -p /buildenv/corecrypto/corecrypto_static && ln -s ../ccrng_static.c /buildenv/corecrypto/corecrypto_static/ccrng_static.c
WORKDIR /buildenv/corecrypto
RUN mkdir build; cd build; CC=clang CXX=clang++ cmake ..;
WORKDIR /buildenv/corecrypto/build
Expand Down