Skip to content

Commit

Permalink
ci: Build GMP and CLN from source for releases (cvc5#11053)
Browse files Browse the repository at this point in the history
This ensures that the GMP and CLN libraries are included in the release
packages.
  • Loading branch information
daniel-larraz authored Jul 17, 2024
1 parent 0cf3c1b commit ffb224b
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 9 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
build:
- name: ubuntu:production
os: ubuntu-20.04
config: production --auto-download --all-bindings --editline --docs --docs-ga
config: production --auto-download --all-bindings --editline --docs --docs-ga -DBUILD_GMP=1
cache-key: production
strip-bin: strip
python-bindings: true
Expand Down Expand Up @@ -119,15 +119,15 @@ jobs:
# GPL versions
- name: ubuntu:production-gpl
os: ubuntu-20.04
config: production --auto-download --editline --gpl --cln --glpk --cocoa
config: production --auto-download --editline --gpl --cln --glpk --cocoa -DBUILD_GMP=1 -DBUILD_CLN=1
cache-key: production-gpl
strip-bin: strip
package-name: cvc5-Linux-x86_64
gpl-tag: -gpl

- name: macos:production-gpl
os: macos-13
config: production --auto-download --editline --gpl --cln --glpk --cocoa -DBUILD_GMP=1
config: production --auto-download --editline --gpl --cln --glpk --cocoa -DBUILD_GMP=1 -DBUILD_CLN=1
cache-key: production-gpl
strip-bin: strip
package-name: cvc5-macOS-x86_64
Expand All @@ -136,7 +136,7 @@ jobs:

- name: macos:production-arm64-gpl
os: macos-14
config: production --auto-download --editline --gpl --cln --glpk --cocoa -DBUILD_GMP=1
config: production --auto-download --editline --gpl --cln --glpk --cocoa -DBUILD_GMP=1 -DBUILD_CLN=1
cache-key: production-arm64-gpl
strip-bin: strip
package-name: cvc5-macOS-arm64
Expand Down
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,8 @@ option(BUILD_BINDINGS_JAVA "Build Java bindings based on new C++ API ")
option(BUILD_DOCS "Build Api documentation")
option(BUILD_DOCS_GA "Build API documentation with Google Analytics")

option(BUILD_GMP "Build GMP from sources")
option(BUILD_GMP "Build GMP from source")
option(BUILD_CLN "Build CLN from source")

# Link against static system libraries
cvc5_option(STATIC_BINARY "Link against static system libraries \
Expand Down
6 changes: 4 additions & 2 deletions cmake/FindCLN.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@

include(deps-helper)

find_path(CLN_INCLUDE_DIR NAMES cln/cln.h)
find_library(CLN_LIBRARIES NAMES cln)
if (NOT BUILD_CLN)
find_path(CLN_INCLUDE_DIR NAMES cln/cln.h)
find_library(CLN_LIBRARIES NAMES cln)
endif()

set(CLN_FOUND_SYSTEM FALSE)
if(CLN_INCLUDE_DIR AND CLN_LIBRARIES)
Expand Down
2 changes: 0 additions & 2 deletions contrib/arm64-gpl.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ RUN apt-get update && apt-get install -y \
automake \
cmake \
g++ \
libcln-dev \
libgmp-dev \
libtool \
openjdk-11-jdk \
python3 \
Expand Down

0 comments on commit ffb224b

Please sign in to comment.