Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build-cmake-pkg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
cmake --build build --config Release
cmake --install build --prefix "$PREFIX" --config Release

export LLAMA_CONFIG="$PREFIX"/lib/cmake/llama/llama-config.cmake
export LLAMA_CONFIG="$PREFIX"/share/llama/llama-config.cmake
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just for my understanding, does not runners defines in the yaml file? how come we use different runners than upstream repo?

Copy link
Author

@jesusmb1995 jesusmb1995 Oct 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They are using self-hosted runners, even for Linux in order to test in multiple hardware. That already could be causing some differences in the default install dir of the environment.

However, I think you are right. This one might not be related to runners at all since GH Linux Ubuntu runner should still use the default /lib (edited the description). Looking more closely at our changes I think its related to the modified CMakeLists.txt where we added the following:

install(
  EXPORT llama-targets
  FILE llama-targets.cmake
  NAMESPACE llama::
  DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/llama)

install(
  FILES ${CMAKE_CURRENT_BINARY_DIR}/llama-config.cmake
  DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/llama)

tclsh <<'EOF'
set build(commit) [string trim [exec git rev-parse --short HEAD]]
set build(number) [string trim [exec git rev-list --count HEAD]]
Expand All @@ -47,5 +47,5 @@ jobs:
EOF

cd examples/simple-cmake-pkg
cmake -S . -B build -DCMAKE_PREFIX_PATH="$PREFIX"/lib/cmake
cmake -S . -B build -DCMAKE_PREFIX_PATH="$PREFIX"/share
cmake --build build
2 changes: 1 addition & 1 deletion examples/simple-cmake-pkg/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ find_package(Llama REQUIRED)

add_executable(${TARGET} ${CMAKE_CURRENT_LIST_DIR}/../simple/simple.cpp)
install(TARGETS ${TARGET} RUNTIME)
target_link_libraries(${TARGET} PRIVATE llama ggml::all ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(${TARGET} PRIVATE llama::llama ggml::all ${CMAKE_THREAD_LIBS_INIT})
target_compile_features(${TARGET} PRIVATE cxx_std_17)
Loading