Skip to content

Fix cmake binary output dir + enable build CI on PRs#7

Merged
lmangani merged 3 commits intomainfrom
copilot/fix-cmake-openmp-issue
Mar 1, 2026
Merged

Fix cmake binary output dir + enable build CI on PRs#7
lmangani merged 3 commits intomainfrom
copilot/fix-cmake-openmp-issue

Conversation

Copy link
Contributor

Copilot AI commented Mar 1, 2026

When acestep.cpp is built via cmake, ggml's CMakeLists.txt silently redirects all executables to ${CMAKE_BINARY_DIR}/bin when used as a subdirectory — so ace-qwen3 and dit-vae land in build/bin/ instead of build/. Every binary search in this repo only looked in build/, so builds appeared to produce nothing.

Additionally, the build-test CI job was gated on workflow_dispatch only, meaning the fix was never automatically verified on PRs.

Changes

install.py + nodes.py — fix binary output directory

  • Pass -DCMAKE_RUNTIME_OUTPUT_DIRECTORY={build_dir} to cmake so new builds always emit binaries into build/ directly
  • Add _binary_exists (install.py) and _binary_in_build (nodes.py) helpers that check both build/ and build/bin/ — preserving compatibility with existing installations built without the flag
  • get_binary_path() and AcestepCPPBuilder.build() both use _binary_in_build for consistent fallback search
# ggml CMakeLists.txt when used as subdirectory:
if (NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY)
    set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)  # ← the culprit
endif()

.github/workflows/ci.yml — actually test the build

  • Removed if: github.event_name == 'workflow_dispatch' gate from build-test; it now runs on every PR and push to main
  • Updated "Verify binaries exist" shell check to mirror _binary_in_build: checks build/$bin then falls back to build/bin/$bin

Tests

  • tests/test_install.py — new, covers _binary_exists for both search paths
  • tests/test_nodes.pyTestBinaryInBuild and TestGetBinaryPath covering the helper and config/PATH/not-found lookup chain

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix CMake configuration to resolve OpenMP not found warnings Fix binary not found after cmake build: handle ggml's build/bin/ output directory Mar 1, 2026
…spatch

Co-authored-by: lmangani <1423657+lmangani@users.noreply.github.com>
Copilot AI changed the title Fix binary not found after cmake build: handle ggml's build/bin/ output directory Fix cmake binary output dir + enable build CI on PRs Mar 1, 2026
@lmangani lmangani marked this pull request as ready for review March 1, 2026 17:35
@lmangani lmangani merged commit b6294de into main Mar 1, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants