Skip to content
Open
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
16 changes: 16 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,22 @@ jobs:
run: |
make amalgamated_timing

CMake-subproject:
runs-on: ubuntu-22.04
strategy:
matrix:
shared: [ 'Off', 'On' ]
steps:
- uses: actions/checkout@v4
- name: build and install from a parent project
run: |
cmake -S demo/cmake_subproject -B build-subproject \
-DBUILD_SHARED_LIBS=${{ matrix.shared }} -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX="$PWD/install-subproject" \
-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON
cmake --build build-subproject --parallel 2
cmake --install build-subproject

CMake:
runs-on: ${{ matrix.os }}
strategy:
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ write_basic_package_version_file(
# Windows uses a different help sytem.
if((NOT WIN32) AND (NOT CMAKE_HOST_WIN32))
# install manpage (not gzipped, some BSD's do not want it compressed?)
install(FILES ${CMAKE_SOURCE_DIR}/doc/tommath.3
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/doc/tommath.3
DESTINATION ${CMAKE_INSTALL_MANDIR}/man3/
)
endif()
Expand Down
6 changes: 6 additions & 0 deletions demo/cmake_subproject/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# SPDX-License-Identifier: Unlicense

cmake_minimum_required(VERSION 3.10)
project(libtommath_parent C)

add_subdirectory(../.. libtommath)