Skip to content

Commit bb523cc

Browse files
committed
Move config file template from src/beman/exemplar to cmake/
This change is needed in order for us to support both header-only and source-based repositories with exemplar; in both cases, the config file template will live in the cmake/ directory. This commit bumps infra/ to the latest version to pick up a change to beman-install-library-config.cmake.
1 parent 9626060 commit bb523cc

18 files changed

Lines changed: 10 additions & 272 deletions

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ include(infra/cmake/beman-install-library-config.cmake)
2929

3030
add_subdirectory(src/beman/exemplar)
3131

32+
find_package(beman-install-library REQUIRED)
33+
beman_install_library(beman.exemplar)
34+
3235
if(BEMAN_EXEMPLAR_BUILD_TESTS)
3336
enable_testing()
3437
add_subdirectory(tests/beman/exemplar)
File renamed without changes.

cookiecutter/{{cookiecutter.project_name}}/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ include(infra/cmake/beman-install-library-config.cmake)
2929

3030
add_subdirectory(src/beman/{{cookiecutter.project_name}})
3131

32+
find_package(beman-install-library REQUIRED)
33+
beman_install_library(beman.{{cookiecutter.project_name}})
34+
3235
if(BEMAN_{{cookiecutter.project_name.upper()}}_BUILD_TESTS)
3336
enable_testing()
3437
add_subdirectory(tests/beman/{{cookiecutter.project_name}})

cookiecutter/{{cookiecutter.project_name}}/src/beman/{{cookiecutter.project_name}}/beman.{{cookiecutter.project_name}}-config.cmake.in renamed to cookiecutter/{{cookiecutter.project_name}}/cmake/beman.{{cookiecutter.project_name}}-config.cmake.in

File renamed without changes.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[beman_submodule]
22
remote=https://github.com/bemanproject/infra.git
3-
commit_hash=ec701785a8106c2b7088c7928d6fe861e27d67bc
3+
commit_hash=9f89e813b844915267b783289d386a09c69560d1

cookiecutter/{{cookiecutter.project_name}}/infra/.github/workflows/beman-tidy.yml

Lines changed: 0 additions & 111 deletions
This file was deleted.

cookiecutter/{{cookiecutter.project_name}}/infra/.pre-commit-config.yaml

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,3 @@ repos:
1919
- id: gersemi
2020
name: CMake linting
2121
exclude: ^.*/tests/.*/data/ # Exclude test data directories
22-
23-
# Python linting and formatting
24-
# config file: ruff.toml (not currently present but add if needed)
25-
# https://docs.astral.sh/ruff/configuration/
26-
- repo: https://github.com/astral-sh/ruff-pre-commit
27-
rev: v0.13.2
28-
hooks:
29-
- id: ruff-check
30-
files: ^tools/beman-tidy/
31-
- id: ruff-format
32-
files: ^tools/beman-tidy/

cookiecutter/{{cookiecutter.project_name}}/infra/.pre-commit-hooks.yaml

Lines changed: 0 additions & 7 deletions
This file was deleted.

cookiecutter/{{cookiecutter.project_name}}/infra/README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22

33
<!-- SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -->
44

5-
[![beman-tidy tests](https://github.com/bemanproject/infra/actions/workflows/beman-tidy.yml/badge.svg)](https://github.com/bemanproject/infra/actions/workflows/beman-tidy.yml)
6-
75
This repository contains the infrastructure for The Beman Project. This is NOT a library repository,
86
so it does not respect the usual structure of a Beman library repository nor The Beman Standard!
97

cookiecutter/{{cookiecutter.project_name}}/infra/cmake/beman-install-library-config.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ function(beman_install_library name)
121121
find_file(
122122
config_file_template
123123
NAMES "${package_name}-config.cmake.in"
124-
PATHS "${CMAKE_CURRENT_SOURCE_DIR}"
124+
PATHS "${PROJECT_SOURCE_DIR}/cmake"
125125
NO_DEFAULT_PATH
126126
NO_CACHE
127127
REQUIRED

0 commit comments

Comments
 (0)