Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmake: Add configuration for Cmake Package #553

Merged
merged 2 commits into from
Sep 30, 2020
Merged

cmake: Add configuration for Cmake Package #553

merged 2 commits into from
Sep 30, 2020

Conversation

chfast
Copy link
Collaborator

@chfast chfast commented Sep 24, 2020

No description provided.

@codecov
Copy link

codecov bot commented Sep 24, 2020

Codecov Report

Merging #553 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #553   +/-   ##
=======================================
  Coverage   98.64%   98.64%           
=======================================
  Files          61       61           
  Lines        8959     8959           
=======================================
  Hits         8838     8838           
  Misses        121      121           

lib/fizzy/CMakeLists.txt Outdated Show resolved Hide resolved
@chfast chfast changed the base branch from cmake_fizzy_internal to public_capi September 25, 2020 12:19
@@ -100,5 +104,12 @@ if(FIZZY_TESTING)
add_subdirectory(test)
endif()

set(CMAKE_INSTALL_CMAKEPACKAGEDIR ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME})

write_basic_package_version_file(fizzyConfigVersion.cmake COMPATIBILITY ExactVersion)
Copy link
Member

Choose a reason for hiding this comment

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

What is this?

# This example shows how to use the fizzy library from the fizzy CMake package.
cmake_minimum_required(VERSION 3.15)
project(use_fizzy LANGUAGES CXX)
find_package(fizzy CONFIG REQUIRED)
Copy link
Member

Choose a reason for hiding this comment

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

So this use_fizzy directory is a test for find_package(fizzy)?

Copy link
Member

@axic axic left a comment

Choose a reason for hiding this comment

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

My understanding is limited, but looks okay-ish.

Base automatically changed from public_capi to master September 30, 2020 13:30
Copy link
Collaborator Author

@chfast chfast left a comment

Choose a reason for hiding this comment

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

CMake package consist of a number of special files.

CMake docs in subject: https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html

In summary: there is a shit lot of boilerplate here and essential parts well hidden in-between.

@axic axic merged commit 88cca3e into master Sep 30, 2020
@axic axic deleted the cmake_package branch September 30, 2020 15:38
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.

3 participants