-
Notifications
You must be signed in to change notification settings - Fork 106
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Refactor CMake build files * Created separate `bladebit_harvester` target meant to be used as a dependency. * Spelling fixes and build fixes. * Fixed CUDA harvesting qualities * Updated CI to for new harvester target * Other bug fixed * Made harvester API more portable, and able to be dynamically loaded * Add API to get compression info directly into the harvester API * version bump alpha4 Co-authored-by: Kyle Altendorf <k.altendorf@chia.net> Co-authored-by: William Allen <w.allen@chia.net>
- Loading branch information
1 parent
e08ee8c
commit ec28f18
Showing
46 changed files
with
1,437 additions
and
2,458 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,44 @@ | ||
#!/usr/bin/env bash | ||
set -eo pipefail | ||
|
||
artifact_name=green_reaper.tar.gz | ||
|
||
while true; do | ||
case $1 in | ||
--artifact) | ||
shift && artifact_name=$1 || exit 1 | ||
;; | ||
esac | ||
shift || break | ||
done | ||
|
||
echo "Harvester artifact: ${artifact_name}" | ||
echo 'cmake --version' | ||
cmake --version | ||
|
||
mkdir -p build-harvester | ||
pushd build-harvester | ||
cmake .. -DCMAKE_BUILD_TYPE=Release -DBB_HARVESTER_ONLY=ON | ||
|
||
cmake --build . --config Release --target bladebit_harvester -j$(nproc --all) | ||
cmake --install . --prefix harvester_dist | ||
|
||
pushd harvester_dist/green_reaper | ||
artifact_files=$(find . -name '*.*' | cut -c3-) | ||
sha256sum ${artifact_files} > sha256checksum | ||
|
||
artifact_files="${artifact_files} sha256checksum" | ||
|
||
tar --version | ||
tar -czvf ${artifact_name} ${artifact_files} | ||
|
||
popd | ||
mv harvester_dist/green_reaper/${artifact_name} ./ | ||
sha256sum ${artifact_name} > ${artifact_name}.sha256.txt | ||
ls -la | ||
cat ${artifact_name}.sha256.txt | ||
|
||
echo "harvester_artifact_path=$(pwd)/${artifact_name}*" >> $GITHUB_ENV | ||
|
||
popd | ||
ls -la |
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,33 @@ | ||
#!/usr/bin/env bash | ||
set -eo pipefail | ||
ref_cmake_sha256='39e1c2eccda989b0d000dc5f4ee2cb031bdda799163780d855acc0bd9eda9d92' | ||
cmake_name='cmake-3.23.3-linux-x86_64' | ||
|
||
curl -L https://github.com/Kitware/CMake/releases/download/v3.23.3/cmake-3.23.3-linux-x86_64.tar.gz > cmake.tar.gz | ||
|
||
cmake_sh_sha256=$(sha256sum cmake.tar.gz | cut -f1 -d' ') | ||
if [[ "${ref_cmake_sha256}" != "${cmake_sh_sha256}" ]]; then | ||
2>&1 echo "sha256 mismatch!: " | ||
2>&1 echo "Got : '${cmake_sh_sha256}'" | ||
2>&1 echo "Expected: '${ref_cmake_sha256}'" | ||
exit 1 | ||
fi | ||
|
||
rm -f /usr/bin/cmake && rm -f /usr/local/bin/cmake | ||
mkdir -p /usr/local/bin | ||
mkdir -p /usr/local/share | ||
|
||
cmake_prefix=$(pwd)/${cmake_name} | ||
tar -xzvf cmake.tar.gz | ||
ls -la | ||
ls -la ${cmake_prefix} | ||
|
||
cp -r ${cmake_prefix}/bin/* /usr/local/bin/ | ||
cp -r ${cmake_prefix}/share/* /usr/local/share/ | ||
|
||
echo 'Cmake Info:' | ||
which cmake | ||
cmake --version | ||
|
||
echo 'Done.' | ||
exit 0 |
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.