Skip to content

Commit 029bb39

Browse files
alitariq4589akifejazCISC
authored
ci : enable RVV1.0 native build (ggml-org#15386)
* Changed the CI file to hw * Changed the CI file to hw * Added to sudoers for apt * Removed the clone command and used checkout * Added libcurl * Added gcc-14 * Checking gcc --version * added gcc-14 symlink * added CC and C++ variables * Added the gguf weight * Changed the weights path * Added system specification * Removed white spaces * ci: Replace Jenkins riscv native build Cloud-V pipeline with GitHub Actions workflow Removed the legacy .devops/cloud-v-pipeline Jenkins CI configuration and introduced .github/workflows/build-riscv-native.yml for native RISC-V builds using GitHub Actions. * removed trailing whitespaces * Added the trigger at PR creation * Corrected OS name * Added ccache as setup package * Added ccache for self-hosted runner * Added directory for ccache size storage Co-authored-by: Sigbjørn Skjæret <[email protected]> * Changed the build command and added ccache debug log * Added the base dir for the ccache * Re-trigger CI * Cleanup and refactored ccache steps * Cleanup and refactored ccache steps --------- Co-authored-by: Akif Ejaz <[email protected]> Co-authored-by: Sigbjørn Skjæret <[email protected]>
1 parent 30649ca commit 029bb39

File tree

1 file changed

+33
-16
lines changed

1 file changed

+33
-16
lines changed
Lines changed: 33 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
name: Build on RISCV Linux Machine by Cloud-V
22
on:
3+
pull_request:
34
workflow_dispatch:
45
workflow_call:
56

67
jobs:
7-
bianbu-riscv64-native: # Bianbu 2.2
8+
debian-13-riscv64-native: # Bianbu 2.2
89
runs-on: self-hosted
910

1011
steps:
@@ -20,24 +21,40 @@ jobs:
2021
build-essential \
2122
gcc-14-riscv64-linux-gnu \
2223
g++-14-riscv64-linux-gnu \
24+
ccache \
2325
cmake
2426
27+
- name: Setup ccache
28+
run: |
29+
mkdir -p $HOME/.ccache
30+
ccache -M 5G -d $HOME/.ccache
31+
export CCACHE_LOGFILE=/home/runneruser/ccache_debug/ccache.log
32+
export CCACHE_DEBUGDIR="/home/runneruser/ccache_debug"
33+
echo "$GITHUB_WORKSPACE"
34+
echo "CCACHE_LOGFILE=$CCACHE_LOGFILE" >> $GITHUB_ENV
35+
echo "CCACHE_DEBUGDIR=$CCACHE_DEBUGDIR" >> $GITHUB_ENV
36+
echo "CCACHE_BASEDIR=$GITHUB_WORKSPACE" >> $GITHUB_ENV
37+
echo "CCACHE_DIR=$HOME/.ccache" >> $GITHUB_ENV
38+
2539
- name: Build
2640
run: |
27-
cmake -B build -DLLAMA_CURL=OFF \
28-
-DCMAKE_BUILD_TYPE=Release \
29-
-DGGML_OPENMP=OFF \
30-
-DLLAMA_BUILD_EXAMPLES=ON \
31-
-DLLAMA_BUILD_TOOLS=ON \
32-
-DLLAMA_BUILD_TESTS=OFF \
33-
-DCMAKE_SYSTEM_NAME=Linux \
34-
-DCMAKE_SYSTEM_PROCESSOR=riscv64 \
35-
-DCMAKE_C_COMPILER=riscv64-linux-gnu-gcc-14 \
36-
-DCMAKE_CXX_COMPILER=riscv64-linux-gnu-g++-14 \
37-
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
38-
-DCMAKE_FIND_ROOT_PATH=/usr/lib/riscv64-linux-gnu \
39-
-DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER \
40-
-DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY \
41-
-DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=BOTH
41+
cmake -B build \
42+
-DLLAMA_CURL=OFF \
43+
-DCMAKE_BUILD_TYPE=Release \
44+
-DGGML_OPENMP=OFF \
45+
-DLLAMA_BUILD_EXAMPLES=ON \
46+
-DLLAMA_BUILD_TOOLS=ON \
47+
-DLLAMA_BUILD_TESTS=OFF \
48+
-DCMAKE_SYSTEM_NAME=Linux \
49+
-DCMAKE_SYSTEM_PROCESSOR=riscv64 \
50+
-DCMAKE_C_COMPILER=riscv64-linux-gnu-gcc-14 \
51+
-DCMAKE_CXX_COMPILER=riscv64-linux-gnu-g++-14 \
52+
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
53+
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
54+
-DCMAKE_POSITION_INDEPENDENT_CODE=ON \
55+
-DCMAKE_FIND_ROOT_PATH=/usr/lib/riscv64-linux-gnu \
56+
-DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER \
57+
-DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY \
58+
-DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=BOTH
4259
4360
cmake --build build --config Release -j $(nproc)

0 commit comments

Comments
 (0)