-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
23be831
commit e412fc4
Showing
37 changed files
with
8,153 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
# hadolint global ignore=DL3033,SC3044 | ||
FROM fedora:20 | ||
|
||
SHELL ["/bin/bash", "-o", "pipefail", "-c"] | ||
|
||
ENV PATH="${PATH}:/root/.cargo/bin/" | ||
|
||
COPY .github/builder/rsrc/rust-nightly-x86_64-unknown-linux-gnu.tar.xz /install/rust-nightly-x86_64-unknown-linux-gnu.tar.xz | ||
COPY .github/builder/rsrc/make-4.4.1.tar.gz /install/make-4.4.1.tar.gz | ||
COPY .github/builder/rsrc/cmake-3.29.3-linux-x86_64.tar.gz /install/cmake-3.29.3-linux-x86_64.tar.gz | ||
COPY .github/builder/rsrc/lld-5.0.2.src.tar.xz /install/lld-5.0.2.src.tar.xz | ||
COPY .github/builder/rsrc/cfe-5.0.2.src.tar.xz /install/cfe-5.0.2.src.tar.xz | ||
COPY .github/builder/rsrc/llvm-5.0.2.src.tar.xz /install/llvm-5.0.2.src.tar.xz | ||
COPY .github/builder/rsrc/rpms /install/rpms | ||
COPY .github/builder/rsrc/simics-7 /simics | ||
COPY .github/builder/rsrc/ispm /simics/ispm | ||
|
||
RUN yum -y install /install/rpms/*.rpm && yum clean all | ||
|
||
RUN tar -C /install -xvf /install/rust-nightly-x86_64-unknown-linux-gnu.tar.xz && \ | ||
/install/rust-nightly-x86_64-unknown-linux-gnu/install.sh && \ | ||
mkdir -p /make && \ | ||
tar -C /make --strip-components=1 -xf /install/make-4.4.1.tar.gz && \ | ||
pushd /make && \ | ||
./configure && \ | ||
make && \ | ||
make install && \ | ||
make clean && \ | ||
popd && \ | ||
tar -C /usr/local/ --strip-components=1 -xf /install/cmake-3.29.3-linux-x86_64.tar.gz && \ | ||
mkdir -p /llvm/tools/clang && \ | ||
mkdir -p /llvm/tools/lld && \ | ||
tar -C /llvm --strip-components=1 -xf /install/llvm-5.0.2.src.tar.xz && \ | ||
tar -C /llvm/tools/clang --strip-components=1 -xf /install/cfe-5.0.2.src.tar.xz && \ | ||
tar -C /llvm/tools/lld --strip-components=1 -xf /install/lld-5.0.2.src.tar.xz && \ | ||
mkdir -p /llvm/build && \ | ||
pushd /llvm/build && \ | ||
cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE="MinSizeRel" -DLLVM_TARGETS_TO_BUILD="X86" .. && \ | ||
make -j "$(nproc)" && \ | ||
make install && \ | ||
make clean && \ | ||
rm -rf /llvm/build/ && \ | ||
popd && \ | ||
rm -rf /make /llvm | ||
|
||
WORKDIR / | ||
|
||
ENV PATH="${PATH}:/simics/ispm/" | ||
ENV PATH="${PATH}:/root/.cargo/bin/" | ||
|
||
COPY . /tsffs/ | ||
|
||
WORKDIR /tsffs/ | ||
|
||
RUN ispm settings install-dir /simics && \ | ||
ispm packages --list | ||
|
||
RUN RUSTFLAGS="-C linker=clang -C link-arg=-fuse-ld=$(which ld.lld)" && \ | ||
export RUSTFLAGS && \ | ||
cargo install cargo-simics-build && \ | ||
SIMICS_PACKAGE_VERSION="$(ispm packages --list-installed | grep 1000 | awk '{print $3}' | cut -d '.' -f1).$(grep -E '^version = ' < Cargo.toml | sed -n '$p' | grep -oE '\"[^\"]+\"' | tr -d '\"' | cut -d'.' -f2-)" && \ | ||
export SIMICS_PACKAGE_VERSION && \ | ||
cargo simics-build -r && \ | ||
mkdir -p /packages-internal && \ | ||
cp target/release/*.ispm /packages-internal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.