ci: build elc from dist/platform/elc.c with system curl/ssl headers
Deploy marketing to Cloud Run / deploy (push) Has been cancelled
Deploy marketing to Cloud Run / deploy (push) Has been cancelled
elc-bootstrap.c isn't committed to engram-lang; the actual C source is dist/platform/elc.c. Add libcurl4-openssl-dev/libssl-dev install step so cc has the right headers.
This commit is contained in:
@@ -74,16 +74,20 @@ jobs:
|
|||||||
- name: Configure docker auth for Artifact Registry
|
- name: Configure docker auth for Artifact Registry
|
||||||
run: gcloud auth configure-docker us-central1-docker.pkg.dev --quiet
|
run: gcloud auth configure-docker us-central1-docker.pkg.dev --quiet
|
||||||
|
|
||||||
|
- name: Install C build deps for elc
|
||||||
|
run: |
|
||||||
|
sudo apt-get update -qq
|
||||||
|
sudo apt-get install -y --no-install-recommends build-essential libcurl4-openssl-dev libssl-dev
|
||||||
|
|
||||||
- name: Build elc fresh on the runner
|
- name: Build elc fresh on the runner
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
# The committed dist/platform/elc may be from a different architecture
|
# The committed dist/platform/elc is arm64 from Will's mac. We
|
||||||
# (e.g. Will's macOS arm64 dev box). Compile from elc-bootstrap.c on
|
# rebuild from dist/platform/elc.c (the canonical C source) so
|
||||||
# the runner so the binary matches linux/amd64.
|
# the binary matches the runner's linux/amd64.
|
||||||
cd "$EL_HOME"
|
cd "$EL_HOME"
|
||||||
mkdir -p dist/platform
|
|
||||||
cc -O2 -o dist/platform/elc \
|
cc -O2 -o dist/platform/elc \
|
||||||
dist/elc-bootstrap.c \
|
dist/platform/elc.c \
|
||||||
el-compiler/runtime/el_runtime.c \
|
el-compiler/runtime/el_runtime.c \
|
||||||
-I el-compiler/runtime \
|
-I el-compiler/runtime \
|
||||||
-lcurl -lpthread -ldl -lm -lssl -lcrypto
|
-lcurl -lpthread -ldl -lm -lssl -lcrypto
|
||||||
|
|||||||
Reference in New Issue
Block a user