aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.appveyor.yml3
-rw-r--r--.gitmodules6
-rw-r--r--.travis.yml10
m---------3rdparty/libQtOlm0
-rw-r--r--CMakeLists.txt17
-rw-r--r--cmake/FindOlm.cmake30
m---------lib/libQtOlm0
7 files changed, 15 insertions, 51 deletions
diff --git a/.appveyor.yml b/.appveyor.yml
index 410ad12e..fb5903c1 100644
--- a/.appveyor.yml
+++ b/.appveyor.yml
@@ -26,6 +26,9 @@ init:
before_build:
- git submodule update --init --recursive
+- cd 3rdparty/libQtOlm
+- git clone https://gitlab.matrix.org/matrix-org/olm.git
+- cd ../..
- if %MAKETOOL% == cmake cmake -G "NMake Makefiles JOM" -H. -Bbuild -DCMAKE_CXX_FLAGS="/EHsc /W3" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX="%DEPLOY_DIR%"
build_script:
diff --git a/.gitmodules b/.gitmodules
index 23158cd2..eb4c1815 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -1,3 +1,3 @@
-[submodule "lib/libQtOlm"]
- path = lib/libQtOlm
- url = git@gitlab.com:aa13q/libqtolm.git
+[submodule "3rdparty/libQtOlm"]
+ path = 3rdparty/libQtOlm
+ url = https://gitlab.com/b0/libqtolm.git
diff --git a/.travis.yml b/.travis.yml
index 72be46cb..859cabfc 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -32,13 +32,9 @@ before_install:
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then USE_NINJA="-GNinja"; VALGRIND="valgrind $VALGRIND_OPTIONS"; . /opt/qt57/bin/qt57-env.sh; fi
install:
-# olm
-- if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew update; else sudo apt-get update -qq; fi
-- if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew install qt5; export PATH="$PATH:/usr/local/opt/qt/bin"; else sudo apt-get install -y qt5-default; fi
-- git clone https://matrix.org/git/olm.git && cd olm && make && sudo make install && cd ..
-- mkdir build && cd build
-- cmake ..
-# matrix-doc and gtad
+- pushd 3rdparty/libQtOlm
+- git clone https://gitlab.matrix.org/matrix-org/olm.git
+- popd
- git clone https://github.com/QMatrixClient/matrix-doc.git
- git clone --recursive https://github.com/KitsuneRal/gtad.git
- pushd gtad
diff --git a/3rdparty/libQtOlm b/3rdparty/libQtOlm
new file mode 160000
+Subproject f610197ba38ef87bbab8bcff1053bda684a5994
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d3906ffb..19fbdcbe 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -10,11 +10,6 @@ if (NOT WIN32)
include(GNUInstallDirs)
endif(NOT WIN32)
-set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
-
-# Find includes in corresponding build directories
-set(CMAKE_INCLUDE_CURRENT_DIR ON)
-
# Instruct CMake to run moc automatically when needed.
set(CMAKE_AUTOMOC ON)
@@ -54,9 +49,9 @@ find_package(Qt5 5.4.1 REQUIRED Network Gui Multimedia)
get_filename_component(Qt5_Prefix "${Qt5_DIR}/../../../.." ABSOLUTE)
if ((NOT DEFINED USE_INTREE_LIBQOLM OR USE_INTREE_LIBQOLM)
- AND EXISTS ${PROJECT_SOURCE_DIR}/lib/libQtOlm/lib/utils.h)
- add_subdirectory(lib/libQtOlm EXCLUDE_FROM_ALL)
- include_directories(lib/libQtOlm)
+ AND EXISTS ${PROJECT_SOURCE_DIR}/3rdparty/libQtOlm/lib/utils.h)
+ add_subdirectory(3rdparty/libQtOlm EXCLUDE_FROM_ALL)
+ include_directories(3rdparty/libQtOlm)
if (NOT DEFINED USE_INTREE_LIBQOLM)
set (USE_INTREE_LIBQOLM 1)
endif ()
@@ -100,10 +95,10 @@ if (USE_INTREE_LIBQOLM)
if (GIT_FOUND)
execute_process(COMMAND
"${GIT_EXECUTABLE}" rev-parse -q HEAD
- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/lib/libQtOlm/lib
- OUTPUT_VARIABLE LIB_GIT_SHA1
+ WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}/3rdparty/libQtOlm
+ OUTPUT_VARIABLE QTOLM_GIT_SHA1
OUTPUT_STRIP_TRAILING_WHITESPACE)
- message( STATUS " Library git SHA1: ${LIB_GIT_SHA1}")
+ message( STATUS " Library git SHA1: ${QTOLM_GIT_SHA1}")
endif (GIT_FOUND)
else ()
message( STATUS "Using libQtOlm ${QtOlm_VERSION} at ${QtOlm_DIR}")
diff --git a/cmake/FindOlm.cmake b/cmake/FindOlm.cmake
deleted file mode 100644
index 3fea7b46..00000000
--- a/cmake/FindOlm.cmake
+++ /dev/null
@@ -1,30 +0,0 @@
-# - Try to find LibOlm
-
-# Uses the following variables to help find libolm:
-# Olm_INCLUDE_DIR - include files
-# Olm_LIBRARY_DIR - libraries
-# Once done this will define
-# Olm_FOUND - System has olm
-# Olm_INCLUDE_DIRS - The olm include directories
-# Olm_LIBRARIES - The libraries needed to use olm
-
-find_path(Olm_INCLUDE_DIRS NAMES
- olm/olm.h
- olm/inbound_group_session.h
- olm/outbound_group_session.h
- PATHS "${Olm_INCLUDE_DIR}"
- DOC "Path to a directory with libolm header files"
-)
-
-find_library(Olm_LIBRARIES NAMES olm
- PATHS "${Olm_LIBRARY_DIR}"
- DOC "Path to a directory with libolm libraries"
-)
-
-include(FindPackageHandleStandardArgs)
-# handle the QUIETLY and REQUIRED arguments and set OLM_FOUND to TRUE
-# if all listed variables are TRUE
-find_package_handle_standard_args(olm DEFAULT_MSG
- Olm_LIBRARIES Olm_INCLUDE_DIRS)
-
-mark_as_advanced(Olm_INCLUDE_DIRS Olm_LIBRARIES)
diff --git a/lib/libQtOlm b/lib/libQtOlm
deleted file mode 160000
-Subproject 5bfc42417d8ee741d2f5a723a2939c895734b92