mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-22 11:32:09 +00:00
e2a6f5a6ea
* PRYSM-2849 first cut at multi-arch cross compiling toolchain. currently supports arm64 and amd64 via docker cross compiler image * picky linter * some readme cleanup * remove arm 8.2 revision for arm64 builds (cortex a72 is ARMv8.0-A) remove arm32 toolchain from multiarch dockerfile * remove extranous WORKSPACE entries * add docker remote execution configs for amd64 and arm64 * add osx bazelrc configs * working osx toolchain * update readme * cleanup for amd, arm and osx cross before beginning windows * initial stab at mingw windows cross * add docker target for windows_amd64 and update readme for cross-compiling * little more cleanup for readability * Check in generated RBE. Still tweaking config but linux amd64 -> linux amd64 on RBE works OK. Cross compile does not work properly in RBE yet. * fix * update image * Making some progress * delete artifacts * Working build * Add remote config * remove some things I added to README * Tidy * Update readme * remove 2 commented lines * buildifer * Merge pull request #1 from prysmaticlabs/cross-compile-with-suburbandad Cross compile with suburbandad * Merge branch 'master' into clang-cross-compile * buildifier on generated stuff * Merge branch 'master' into clang-cross-compile * Merge branch 'master' into clang-cross-compile * Merge branch 'master' into clang-cross-compile
41 lines
1.3 KiB
Docker
41 lines
1.3 KiB
Docker
# Prysmatic Labs Remote Build Execution Image with Cross Compile Support.
|
|
#
|
|
# Update instructions.
|
|
# - Build the docker image.
|
|
# - Push to gcr.io.
|
|
# - Update _PRYSM_BUILD_IMAGE_DIGEST in //tools/cross-toolchain/rbe_toolchains_config.bzl
|
|
# - Run ./tools/cross-toolchain/regenerate.sh
|
|
# - Add and commit the newly generated configs.
|
|
# - Done!
|
|
#
|
|
# docker build -t gcr.io/prysmaticlabs/rbe-worker:latest .
|
|
# gcloud docker -- push gcr.io/prysmaticlabs/rbe-worker:latest
|
|
|
|
FROM debian:buster as build
|
|
|
|
# install gnu/gcc cross-build toolchain (gcc 8.3)
|
|
ENV DOCKER_CLI_EXPERIMENTAL=enabled
|
|
RUN apt-get update && \
|
|
apt-get install -y \
|
|
curl xz-utils \
|
|
gcc g++ mingw-w64 \
|
|
gcc-aarch64-linux-gnu g++-aarch64-linux-gnu \
|
|
cmake libssl-dev libxml2-dev vim apt-transport-https \
|
|
zip unzip libtinfo5 patch zlib1g-dev autoconf libtool \
|
|
pkg-config make docker.io gnupg2
|
|
|
|
# install llvm/clang cross-build toolchains
|
|
ENV INSTALL_LLVM_VERSION=10.0.0-rc2
|
|
ADD install_clang_cross10.sh /tmp/install_clang_cross.sh
|
|
RUN /tmp/install_clang_cross.sh
|
|
|
|
# install osxcross
|
|
ADD install_osxcross.sh /tmp/install_osxcross.sh
|
|
RUN /tmp/install_osxcross.sh
|
|
|
|
# containerized development environment
|
|
FROM build as devel
|
|
RUN mkdir /workdir
|
|
WORKDIR /workdir
|
|
RUN echo 'PS1="\[$(tput setaf 3)$(tput bold)[\]devel@\\h:\\W]#\[$(tput sgr0) \]"' >> /root/.bashrc
|