forked from Silverfish/proton-bridge
Other: Added top-level CMake project. [skip ci]
This commit is contained in:
34
internal/frontend/CMakeLists.txt
Normal file
34
internal/frontend/CMakeLists.txt
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
# Copyright (c) 2022 Proton AG
|
||||||
|
#
|
||||||
|
# This file is part of Proton Mail Bridge.
|
||||||
|
#
|
||||||
|
# Proton Mail Bridge is free software: you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation, either version 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# Proton Mail Bridge is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with Proton Mail Bridge. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
|
||||||
|
cmake_minimum_required(VERSION 3.22)
|
||||||
|
|
||||||
|
|
||||||
|
#*****************************************************************************************************************************************************
|
||||||
|
# Project
|
||||||
|
#*****************************************************************************************************************************************************
|
||||||
|
|
||||||
|
|
||||||
|
set(VCPKG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../extern/vcpkg")
|
||||||
|
include("bridge_setup.cmake")
|
||||||
|
|
||||||
|
project(frontend)
|
||||||
|
|
||||||
|
add_subdirectory(bridgepp)
|
||||||
|
add_subdirectory(bridge-gui)
|
||||||
|
|
||||||
@ -15,12 +15,10 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with Proton Mail Bridge. If not, see <https://www.gnu.org/licenses/>.
|
# along with Proton Mail Bridge. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.22)
|
cmake_minimum_required(VERSION 3.22)
|
||||||
|
|
||||||
|
|
||||||
include_guard()
|
|
||||||
set(VCPKG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../../extern/vcpkg")
|
set(VCPKG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../../extern/vcpkg")
|
||||||
include(../bridgepp/bridge_setup.cmake)
|
include(../bridge_setup.cmake)
|
||||||
|
|
||||||
|
|
||||||
#*****************************************************************************************************************************************************
|
#*****************************************************************************************************************************************************
|
||||||
@ -69,9 +67,11 @@ message(STATUS "Using Qt ${Qt6_VERSION}")
|
|||||||
#*****************************************************************************************************************************************************
|
#*****************************************************************************************************************************************************
|
||||||
|
|
||||||
|
|
||||||
configure_file(Version.h.in ${CMAKE_SOURCE_DIR}/Version.h)
|
configure_file(Version.h.in ${CMAKE_CURRENT_SOURCE_DIR}/Version.h)
|
||||||
|
|
||||||
|
if (NOT TARGET bridgepp)
|
||||||
add_subdirectory(../bridgepp bridgepp)
|
add_subdirectory(../bridgepp bridgepp)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
set(DOCK_ICON_SRC_FILE DockIcon/DockIcon.mm)
|
set(DOCK_ICON_SRC_FILE DockIcon/DockIcon.mm)
|
||||||
|
|||||||
@ -25,7 +25,10 @@ include_guard()
|
|||||||
# We rely on vcpkg for to get gRPC / Protobuf
|
# We rely on vcpkg for to get gRPC / Protobuf
|
||||||
# run build.sh / build.ps1 to get gRPC / Protobuf and dependencies installed.
|
# run build.sh / build.ps1 to get gRPC / Protobuf and dependencies installed.
|
||||||
|
|
||||||
set(VCPKG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../../extern/vcpkg")
|
if (NOT DEFINED VCPKG_ROOT)
|
||||||
|
message(FATAL_ERROR "VCPKG_ROOT is not defined.")
|
||||||
|
endif()
|
||||||
|
|
||||||
message(STATUS "VCPKG_ROOT is ${VCPKG_ROOT}")
|
message(STATUS "VCPKG_ROOT is ${VCPKG_ROOT}")
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
find_program(VCPKG_EXE "${VCPKG_ROOT}/vcpkg.exe")
|
find_program(VCPKG_EXE "${VCPKG_ROOT}/vcpkg.exe")
|
||||||
@ -17,11 +17,8 @@
|
|||||||
|
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.22)
|
cmake_minimum_required(VERSION 3.22)
|
||||||
|
|
||||||
|
|
||||||
include_guard()
|
|
||||||
set(VCPKG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../../extern/vcpkg")
|
set(VCPKG_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/../../../extern/vcpkg")
|
||||||
include(bridge_setup.cmake)
|
include(../bridge_setup.cmake)
|
||||||
|
|
||||||
|
|
||||||
#****************************************************************************************************************************************************
|
#****************************************************************************************************************************************************
|
||||||
@ -38,6 +35,7 @@ else()
|
|||||||
message(STATUS "Bridge version is ${BRIDGE_APP_VERSION}")
|
message(STATUS "Bridge version is ${BRIDGE_APP_VERSION}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
||||||
#****************************************************************************************************************************************************
|
#****************************************************************************************************************************************************
|
||||||
# Qt
|
# Qt
|
||||||
#****************************************************************************************************************************************************
|
#****************************************************************************************************************************************************
|
||||||
|
|||||||
Reference in New Issue
Block a user