2022-05-05 00:05:29 +08:00
|
|
|
FROM ubuntu:20.04
|
2022-04-21 14:17:14 +08:00
|
|
|
|
2022-05-05 22:45:18 +08:00
|
|
|
ADD ubuntu20_sources.list /etc/apt/sources.list
|
2022-04-21 14:17:14 +08:00
|
|
|
|
|
|
|
RUN echo 'Asia/Shanghai' >/etc/timezone
|
|
|
|
|
|
|
|
# Update new packages
|
|
|
|
RUN apt-get update
|
|
|
|
RUN DEBIAN_FRONTEND=noninteractive apt install -y tzdata
|
|
|
|
RUN apt-get install -y \
|
|
|
|
build-essential \
|
|
|
|
make \
|
|
|
|
g++ \
|
|
|
|
gcc \
|
|
|
|
git \
|
|
|
|
vim \
|
|
|
|
cmake \
|
|
|
|
sudo \
|
2022-05-04 23:56:38 +08:00
|
|
|
curl \
|
|
|
|
python3
|
2022-04-21 14:17:14 +08:00
|
|
|
|
|
|
|
RUN git clone --branch v1.6.1 https://gitee.com/mirrors/google-benchmark benchmark && \
|
|
|
|
cd benchmark && \
|
|
|
|
git clone https://gitee.com/mirrors/googletest && \
|
|
|
|
cmake -E make_directory "build" && \
|
|
|
|
cmake -E chdir "build" cmake -DBENCHMARK_DOWNLOAD_DEPENDENCIES=on -DCMAKE_BUILD_TYPE=Release ../ && \
|
2022-05-04 23:56:38 +08:00
|
|
|
cmake --build "build" --config Release -j && \
|
|
|
|
sudo cmake --build "build" --config Release --target install -j
|
2022-04-21 14:17:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
# Get Rust
|
|
|
|
ENV RUSTUP_DIST_SERVER=https://mirrors.ustc.edu.cn/rust-static
|
|
|
|
ENV RUSTUP_UPDATE_ROOT=https://mirrors.ustc.edu.cn/rust-static/rustup
|
|
|
|
RUN curl https://sh.rustup.rs -sSf | bash -s -- -y
|
|
|
|
|
|
|
|
ENV PATH="/root/.cargo/bin:${PATH}"
|
|
|
|
|
|
|
|
|
2022-04-21 14:29:23 +08:00
|
|
|
RUN git config --global --add safe.directory /usr/src/pikascript
|
2022-05-02 18:17:46 +08:00
|
|
|
RUN git config --global user.email "liang6516@outlook.com"
|
|
|
|
RUN git config --global user.name "lyon"
|
2022-04-21 14:29:23 +08:00
|
|
|
|
2022-05-02 18:11:12 +08:00
|
|
|
|
2022-05-04 23:56:38 +08:00
|
|
|
RUN apt-get install -y \
|
|
|
|
ninja-build \
|
|
|
|
valgrind \
|
|
|
|
mingw-w64 \
|
|
|
|
mingw-w64-tools \
|
|
|
|
mingw-w64-i686-dev \
|
|
|
|
mingw-w64-x86-64-dev \
|
2022-05-05 22:45:18 +08:00
|
|
|
wine \
|
|
|
|
cbindgen
|
2022-05-04 23:56:38 +08:00
|
|
|
|
|
|
|
RUN dpkg --add-architecture i386 && apt-get update && apt-get install wine32 -y
|
|
|
|
|
2022-05-05 09:32:38 +08:00
|
|
|
RUN apt-get install -y golang
|
|
|
|
RUN go env -w GO111MODULE=on
|
|
|
|
RUN go env -w GOPROXY=https://goproxy.cn
|
2022-05-04 23:56:38 +08:00
|
|
|
|
2022-05-05 22:45:18 +08:00
|
|
|
RUN git clone https://gitee.com/lyon1998/pikascript root/pikascript
|
|
|
|
|
|
|
|
ADD rust_config /root/.cargo/config
|
|
|
|
RUN rustup target add i686-pc-windows-gnu
|
|
|
|
|
|
|
|
|
2022-05-05 16:06:57 +08:00
|
|
|
|