diff options
author | iphydf <iphydf@users.noreply.github.com> | 2020-04-23 16:18:15 +0000 |
---|---|---|
committer | iphydf <iphydf@users.noreply.github.com> | 2020-04-26 16:13:24 +0000 |
commit | a2d586b78254f6ba3b12d20f2398f31e9ee66235 (patch) | |
tree | 699a4d40fe84547a129743ce9e32454baf2b8464 /cmake | |
parent | 087eede3a3e75cd7861e7a9b9c949bf36016829e (diff) |
Rework the toxchat/bootstrap-node Docker image.
* Use fully static build for the bootstrap daemon.
* Store a sha256sum of the binary in the repo.
* Updated documentation for it.
* Add support for fully static build in cmake.
* Enable the docker build on every PR, so we catch changes to the
checksum. I realise this is adding toil, but having the checksum is
valuable for security of released binaries.
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/ModulePackage.cmake | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cmake/ModulePackage.cmake b/cmake/ModulePackage.cmake index 77911b1d..9cc21863 100644 --- a/cmake/ModulePackage.cmake +++ b/cmake/ModulePackage.cmake | |||
@@ -9,6 +9,16 @@ if(NOT ENABLE_SHARED AND NOT ENABLE_STATIC) | |||
9 | set(ENABLE_SHARED ON) | 9 | set(ENABLE_SHARED ON) |
10 | endif() | 10 | endif() |
11 | 11 | ||
12 | option(FULLY_STATIC "Build fully static executables" OFF) | ||
13 | if(FULLY_STATIC) | ||
14 | set(CMAKE_EXE_LINKER_FLAGS "-static -no-pie") | ||
15 | # remove -Wl,-Bdynamic | ||
16 | set(CMAKE_EXE_LINK_DYNAMIC_C_FLAGS) | ||
17 | set(CMAKE_EXE_LINK_DYNAMIC_CXX_FLAGS) | ||
18 | set(ENABLE_SHARED OFF) | ||
19 | set(ENABLE_STATIC ON) | ||
20 | endif() | ||
21 | |||
12 | find_package(PkgConfig) | 22 | find_package(PkgConfig) |
13 | 23 | ||
14 | function(pkg_use_module mod pkg) | 24 | function(pkg_use_module mod pkg) |