Package Details: stable-diffusion.cpp-hipblas-git r256.5900ef6-1

Git Clone URL: https://aur.archlinux.org/stable-diffusion.cpp-hipblas-git.git (read-only, click to copy)
Package Base: stable-diffusion.cpp-hipblas-git
Description: Stable Diffusion in pure C/C++ (with AMD ROCm optimizations)
Upstream URL: https://github.com/leejet/stable-diffusion.cpp
Licenses: MIT
Conflicts: stable-diffusion.cpp, stable-diffusion.cpp-hipblas
Provides: stable-diffusion.cpp, stable-diffusion.cpp-hipblas
Submitter: robertfoster
Maintainer: robertfoster
Last Packager: robertfoster
Votes: 2
Popularity: 0.35
First Submitted: 2025-04-12 14:29 (UTC)
Last Updated: 2025-08-18 11:59 (UTC)

Latest Comments

harre commented on 2025-09-03 22:58 (UTC)

I get build error:

==> Starting build()...
-- The C compiler identification is Clang 19.0.0
-- The CXX compiler identification is Clang 19.0.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /opt/rocm/llvm/bin/clang - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - failed
-- Check for working CXX compiler: /opt/rocm/llvm/bin/clang++
-- Check for working CXX compiler: /opt/rocm/llvm/bin/clang++ - broken
CMake Error at /usr/share/cmake/Modules/CMakeTestCXXCompiler.cmake:73 (message):
  The C++ compiler

    "/opt/rocm/llvm/bin/clang++"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: '/home/markus/.cache/yay/stable-diffusion.cpp-hipblas-git/src/build/CMakeFiles/CMakeScratch/TryCompile-6PdKiH'

    Run Build Command(s): /usr/bin/cmake -E env VERBOSE=1 /usr/bin/make -f Makefile cmTC_27b32/fast
    /usr/bin/make  -f CMakeFiles/cmTC_27b32.dir/build.make CMakeFiles/cmTC_27b32.dir/build
    make[1]: Entering directory '/home/markus/.cache/yay/stable-diffusion.cpp-hipblas-git/src/build/CMakeFiles/CMakeScratch/TryCompile-6PdKiH'
    Building CXX object CMakeFiles/cmTC_27b32.dir/testCXXCompiler.cxx.o
    /opt/rocm/llvm/bin/clang++   -march=x86-64 -mtune=generic -O2 -pipe -fno-plt-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fcf-protection=none  -MD -MT CMakeFiles/cmTC_27b32.dir/testCXXCompiler.cxx.o -MF CMakeFiles/cmTC_27b32.dir/testCXXCompiler.cxx.o.d -o CMakeFiles/cmTC_27b32.dir/testCXXCompiler.cxx.o -c /home/markus/.cache/yay/stable-diffusion.cpp-hipblas-git/src/build/CMakeFiles/CMakeScratch/TryCompile-6PdKiH/testCXXCompiler.cxx
    clang++: error: unknown argument: '-fno-plt-march=x86-64'
    make[1]: *** [CMakeFiles/cmTC_27b32.dir/build.make:82: CMakeFiles/cmTC_27b32.dir/testCXXCompiler.cxx.o] Error 1
    make[1]: Leaving directory '/home/markus/.cache/yay/stable-diffusion.cpp-hipblas-git/src/build/CMakeFiles/CMakeScratch/TryCompile-6PdKiH'
    make: *** [Makefile:134: cmTC_27b32/fast] Error 2





  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:2 (project)


-- Configuring incomplete, errors occurred!

jona2000 commented on 2025-05-28 11:48 (UTC) (edited on 2025-05-28 11:49 (UTC) by jona2000)

Encountered two errors during building:

Error 1:

-- The HIP compiler identification is unknown
CMake Error at /usr/share/cmake/Modules/CMakeDetermineHIPCompiler.cmake:174 (message):
  Failed to find ROCm root directory.
Call Stack (most recent call first):
  ggml/src/ggml-hip/CMakeLists.txt:36 (enable_language)

Reason: env vars missing in makepkg build environment

Fix: Add this at the start of build() in PKGBUILD

  export ROCM_PATH=/opt/rocm
  export PATH=$ROCM_PATH/bin:$PATH
  export LD_LIBRARY_PATH=$ROCM_PATH/lib:$ROCM_PATH/lib64:$LD_LIBRARY_PATH

Error 2 (compiler error):

/pikaur/build/stable-diffusion.cpp-hipblas-git/src/stable-diffusion.cpp-hipblas/common.hpp:59:13: error: no matching function for call to 'ggml_upscale'

Reason: Latest ggml from git is incompatible.

Fix: Use compatible commit referenced in stable-diffusion.cpp upstream repository and insert it into the sources array of the PKGBUILD, e.g. git+https://github.com/ggerganov/ggml.git#commit=ff9052988b76e137bcf92bb335733933ca196ac0

Had to clean build dir and rebuild afterwards