2020-12-04 14:14:53 -08:00
|
|
|
cmake_minimum_required (VERSION 3.11.0)
|
2020-11-18 19:04:52 -08:00
|
|
|
|
|
|
|
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
|
|
|
|
|
|
|
|
include(git_version)
|
|
|
|
|
|
|
|
project (browser
|
|
|
|
VERSION ${GIT_TAG_VERSION}
|
|
|
|
DESCRIPTION "Browser - Decentralized WWW"
|
|
|
|
LANGUAGES C CXX)
|
|
|
|
|
|
|
|
message("CMAKE_BUILD_TYPE = ${CMAKE_BUILD_TYPE}")
|
|
|
|
message("PROJECT_VERSION = ${PROJECT_VERSION}")
|
|
|
|
|
|
|
|
# Production build
|
|
|
|
if("${CMAKE_BUILD_TYPE}" STREQUAL "Release")
|
|
|
|
# Include CPack packaging settings
|
|
|
|
include(packaging)
|
|
|
|
endif()
|
2020-11-12 14:27:47 -08:00
|
|
|
|
2021-03-01 09:12:36 -08:00
|
|
|
# Disable CTest testcases & install in cpp-ipfs-http-client
|
2020-12-04 14:14:53 -08:00
|
|
|
set (BUILD_TESTING OFF CACHE BOOL "Disable CTest" FORCE)
|
2021-03-01 09:12:36 -08:00
|
|
|
set (DISABLE_INSTALL ON CACHE BOOL "Disable Install" FORCE)
|
2020-12-04 14:14:53 -08:00
|
|
|
|
2020-11-12 18:06:05 -08:00
|
|
|
add_subdirectory (lib/commonmarker/src)
|
2020-11-12 18:43:03 -08:00
|
|
|
add_subdirectory (lib/commonmarker/extensions)
|
2020-12-04 13:57:00 -08:00
|
|
|
add_subdirectory (lib/ipfs-http-client)
|
2020-11-18 19:04:52 -08:00
|
|
|
add_subdirectory (src)
|
|
|
|
|
2021-02-28 14:47:21 -08:00
|
|
|
# Additional install files
|
|
|
|
install(FILES misc/dweb-browser.desktop DESTINATION share/applications)
|
2021-03-01 13:44:35 -08:00
|
|
|
install(PROGRAMS go-ipfs/ipfs DESTINATION share/dweb-browser/go-ipfs)
|
2021-02-28 14:47:21 -08:00
|
|
|
install(DIRECTORY images DESTINATION share/dweb-browser)
|
|
|
|
install(FILES images/icons/dweb-browser.png DESTINATION share/icons/hicolor/48x48/apps)
|
|
|
|
install(FILES images/icons/dweb-browser.svg DESTINATION share/icons/hicolor/scalable/apps)
|