Skip to content

[PyTorch CI ] CMake should launcher sccache correctly #47

Closed

Description

@yuzibo

🐛 Describe the bug

The change should be:

--- a/Dockerfile.build-2044
+++ b/Dockerfile.build-2044
@@ -90,7 +90,9 @@ RUN \
   python3 /home/jenkins/scripts/collect_env.py && \
   chmod +x /home/jenkins/sccache/sccache && \
   export PATH="/home/jenkins/sccache:$PATH" && \
-  export CC="sccache gcc" && export CXX="sccache g++" && \
+  export CC="gcc" && export CXX="g++" && \
+  export CMAKE_C_COMPILER_LAUNCHER=sccache && \
+  export CMAKE_CXX_COMPILER_LAUNCHER=sccache && \
   sccache --start-server && \
   # network switch
   cd  ${PYTORCH_SRC} && \

Versions

no

Activity

  1. yuzibo commented on Aug 31, 2026

    @yuzibo
    CollaboratorAuthor

    The issue was found from

    ...
    
    #12 145.0 -- </FindZVECTOR>
    #12 145.0 -- <FindRVV>
    #12 145.0 -- Performing Test COMPILE_OUT_RVV
    #12 147.2 -- Performing Test COMPILE_OUT_RVV - Success
    #12 147.3 error: unexpected argument '-m' found
    #12 147.3 
    #12 147.3   tip: to pass '-m' as a value, use '-- -m'
    #12 147.3 
    #12 147.3 Usage: sccache [OPTIONS] <--dist-auth|--debug-preprocessor-cache|--dist-status|--show-stats|--show-adv-stats|--start-server|--stop-server|--zero-stats|--package-toolchain <EXE> <OUT>|CMD>
    #12 147.3 
    #12 147.3 For more information, try '--help'.
    #12 147.3 CMake Error at cmake/Modules/FindRVV.cmake:43 (message):
    #12 147.3   Could not compile RISC-V Vector Length Check: 2
    #12 147.3 Call Stack (most recent call first):
    #12 147.3   cmake/Dependencies.cmake:1657 (find_package)
    #12 147.3   CMakeLists.txt:1108 (include)
    #12 147.3 
    #12 147.3 
    #12 147.3 -- Configuring incomplete, errors occurred!
    #12 147.4 
    #12 147.4 *** CMake configuration failed
    ...
    
  2. yuzibo commented on Aug 31, 2026

    @yuzibo
    CollaboratorAuthor

    close the issue as the commit fix it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions