Skip to content

Commit

Permalink
fix build locally
Browse files Browse the repository at this point in the history
  • Loading branch information
ratankaliani committed Jan 4, 2025
1 parent d11b5f0 commit d641503
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion proposer/op/Dockerfile.op_proposer
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,19 @@ ARG TARGETOS
ARG TARGETARCH
ENV GOOS=$TARGETOS
ENV GOARCH=$TARGETARCH
ENV CGO_ENABLED=1

# Install cross-compilation tools for ARM64
# Install cross-compilation tools for ARM64 and set MUSL flags
RUN if [ "$TARGETARCH" = "arm64" ]; then \
apk add --no-cache gcc-aarch64-none-elf musl-dev; \
export CC=aarch64-none-elf-gcc; \
export CXX=aarch64-none-elf-g++; \
export LDFLAGS="-static"; \
fi

# Fix SQLite compilation for ARM64
ENV CGO_CFLAGS="-D_LARGEFILE64_SOURCE"

WORKDIR /optimism

# Cache go modules
Expand Down

0 comments on commit d641503

Please sign in to comment.