Update command.

This commit is contained in:
Shang Chieh Tseng
2025-10-28 18:42:49 +08:00
parent 92acf0f91e
commit 6024408ea5
2 changed files with 6 additions and 6 deletions

View File

@@ -29,13 +29,13 @@ jobs:
- name: Configure CMake - name: Configure CMake
run: | run: |
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ cmake -B build cmake -B build
env: env:
CMAKE_BUILD_TYPE: Release CMAKE_BUILD_TYPE: Release
- name: Build C++/CUDA components - name: Build C++/CUDA components
run: | run: |
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ cmake --build build --config Release cmake --build build --config Release
timeout-minutes: 30 timeout-minutes: 30
- name: Build Go binary - name: Build Go binary

View File

@@ -37,8 +37,8 @@ git clone https://github.com/dogkeeper886/ollama37
cd ollama37 cd ollama37
# If compiling from source (requires GCC 10): # If compiling from source (requires GCC 10):
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ cmake -B build cmake -B build
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ cmake --build build -j$(nproc) cmake --build build -j$(nproc)
go build -o ollama . go build -o ollama .
# If using pre-built binary (GCC 10 not required): # If using pre-built binary (GCC 10 not required):
@@ -522,13 +522,13 @@ go version
3. **CMake Configuration:** 3. **CMake Configuration:**
Set compiler variables and configure the build system: Set compiler variables and configure the build system:
```bash ```bash
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ cmake -B build cmake -B build
``` ```
4. **CMake Build:** 4. **CMake Build:**
Compile the C++ components (parallel build): Compile the C++ components (parallel build):
```bash ```bash
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ cmake --build build -j$(nproc) cmake --build build -j$(nproc)
``` ```
> **Note:** `-j$(nproc)` enables parallel compilation using all available CPU cores. You can specify a number like `-j4` to limit the number of parallel jobs. > **Note:** `-j$(nproc)` enables parallel compilation using all available CPU cores. You can specify a number like `-j4` to limit the number of parallel jobs.