[SCM] ktp-auth-handler packaging branch, master, updated. debian/15.12.1-2-282-g080758e
Maximiliano Curia
maxy at moszumanska.debian.org
Fri May 27 23:58:26 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-auth-handler.git;a=commitdiff;h=a1fcabb
The following commit has been merged in the master branch:
commit a1fcabbe563a35009a4237932de8b4ae3d919d8d
Author: Dario Freddi <dario.freddi at collabora.com>
Date: Thu Nov 24 20:17:07 2011 +0100
Port to new internal KTelepathy library
---
CMakeLists.txt | 21 ++++-----------------
cmake/modules/FindKTelepathy.cmake | 37 +++++++++++++++++++++++++++++++++++++
main.cpp | 5 +++--
password-prompt.cpp | 5 +++--
sasl-auth-op.cpp | 7 ++++---
sasl-handler.cpp | 7 ++++---
tls-handler.cpp | 7 ++++---
7 files changed, 59 insertions(+), 30 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index fcebaa1..42cd8e6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -5,9 +5,11 @@ set (CMAKE_MODULE_PATH
${CMAKE_MODULE_PATH}
)
+set(IS_TELEPATHY_KDE_INTERNAL_MODULE TRUE)
set(KDE_MIN_VERSION "4.4.75")
find_package (KDE4 4.4.75 REQUIRED)
find_package (TelepathyQt4 0.7.3 REQUIRED)
+find_package (KTelepathy REQUIRED)
include (KDE4Defaults)
include (MacroLibrary)
@@ -17,23 +19,7 @@ add_definitions (${KDE4_DEFINITIONS}
include_directories (${KDE4_INCLUDES}
${TELEPATHY_QT4_INCLUDE_DIR}
-)
-
-
-if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/.gitmodules)
-execute_process(COMMAND git submodule init
- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
-)
-
-execute_process(COMMAND git submodule update
- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
-)
-endif(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/.gitmodules)
-
-
-set (telepathy_kde_common_internals_SRCS
- common/telepathy-handler-application.cpp
- common/wallet-interface.cpp
+ ${KTELEPATHY_INCLUDE_DIR}
)
set(telepathy_kde_auth_handler_SRCS
@@ -56,6 +42,7 @@ target_link_libraries(telepathy-kde-auth-handler
${QT_QTXML_LIBRARY}
${QT_QTCORE_LIBRARY}
${TELEPATHY_QT4_LIBRARIES}
+ ${KTELEPATHY_LIBRARIES}
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
)
diff --git a/cmake/modules/FindKTelepathy.cmake b/cmake/modules/FindKTelepathy.cmake
new file mode 100644
index 0000000..4a0e704
--- /dev/null
+++ b/cmake/modules/FindKTelepathy.cmake
@@ -0,0 +1,37 @@
+# Try to find the KTelepathy library
+# KTELEPATHY_FOUND
+# KTELEPATHY_INCLUDE_DIR
+# KTELEPATHY_LIBRARIES
+# KTELEPATHY_MODELS_LIBRARIES
+
+# Copyright (c) 2011, Dario Freddi <drf at kde.org>
+#
+# Redistribution and use is allowed according to the terms of the BSD license.
+# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
+
+if (NOT IS_TELEPATHY_KDE_INTERNAL_MODULE)
+ message (FATAL_ERROR "KTelepathy can be used just from internal components at this time")
+endif (NOT IS_TELEPATHY_KDE_INTERNAL_MODULE)
+
+SET (KTELEPATHY_FIND_REQUIRED ${KTelepathy_FIND_REQUIRED})
+if (KTELEPATHY_INCLUDE_DIRS AND KTELEPATHY_LIBRARIES)
+ # Already in cache, be silent
+ set(KTELEPATHY_FIND_QUIETLY TRUE)
+endif (KTELEPATHY_INCLUDE_DIRS AND KTELEPATHY_LIBRARIES)
+
+find_path(KTELEPATHY_INCLUDE_DIR
+ NAMES KTelepathy/presence.h
+ PATHS ${KDE4_INCLUDE_DIR}
+ PATH_SUFFIXES telepathy-1.0
+)
+
+find_library(KTELEPATHY_LIBRARIES NAMES telepathykdecommoninternalsprivate )
+find_library(KTELEPATHY_MODELS_LIBRARIES NAMES telepathykdemodelsprivate )
+
+include(FindPackageHandleStandardArgs)
+FIND_PACKAGE_HANDLE_STANDARD_ARGS(KTelepathy DEFAULT_MSG
+ KTELEPATHY_LIBRARIES
+ KTELEPATHY_MODELS_LIBRARIES
+ KTELEPATHY_INCLUDE_DIR)
+
+mark_as_advanced(KTELEPATHY_INCLUDE_DIRS KTELEPATHY_LIBRARIES)
diff --git a/main.cpp b/main.cpp
index 69161f9..4b91b9c 100644
--- a/main.cpp
+++ b/main.cpp
@@ -34,7 +34,8 @@
#include "sasl-handler.h"
#include "tls-handler.h"
-#include "common/telepathy-handler-application.h"
+
+#include <KTelepathy/telepathy-handler-application.h>
// FIXME: Move this to tp-qt4 itself
#include "types.h"
@@ -49,7 +50,7 @@ int main(int argc, char *argv[])
aboutData.setProductName("telepathy/auth-handler");
KCmdLineArgs::init(argc, argv, &aboutData);
- KTelepathy::TelepathyHandlerApplication app;
+ KTp::TelepathyHandlerApplication app;
// FIXME: Move this to tp-qt4 itself
registerTypes();
diff --git a/password-prompt.cpp b/password-prompt.cpp
index 93d47db..b2cb280 100644
--- a/password-prompt.cpp
+++ b/password-prompt.cpp
@@ -18,7 +18,8 @@
#include "password-prompt.h"
#include "ui_password-prompt.h"
-#include "common/wallet-interface.h"
+
+#include <KTelepathy/wallet-interface.h>
#include <KIcon>
#include <KDebug>
@@ -35,7 +36,7 @@ PasswordPrompt::PasswordPrompt(const Tp::AccountPtr &account, QWidget *parent)
ui->accountIcon->setPixmap(KIcon("dialog-password").pixmap(60,60));
ui->title->setPixmap(KIcon(account->iconName()).pixmap(22,22));
- KTelepathy::WalletInterface wallet(this->effectiveWinId());
+ KTp::WalletInterface wallet(this->effectiveWinId());
if (wallet.isOpen()) {
ui->savePassword->setChecked(true);
diff --git a/sasl-auth-op.cpp b/sasl-auth-op.cpp
index e081d03..1174196 100644
--- a/sasl-auth-op.cpp
+++ b/sasl-auth-op.cpp
@@ -26,7 +26,8 @@
#include <KLocalizedString>
#include "password-prompt.h"
-#include "common/wallet-interface.h"
+
+#include <KTelepathy/wallet-interface.h>
SaslAuthOp::SaslAuthOp(const Tp::AccountPtr &account,
const Tp::ConnectionPtr &connection,
@@ -85,7 +86,7 @@ void SaslAuthOp::gotProperties(Tp::PendingOperation *op)
void SaslAuthOp::onSASLStatusChanged(uint status, const QString &reason,
const QVariantMap &details)
{
- KTelepathy::WalletInterface wallet(0);
+ KTp::WalletInterface wallet(0);
if (status == Tp::SASLStatusNotStarted) {
kDebug() << "Requesting password";
promptUser (m_canTryAgain || !wallet.hasEntry(m_account, QLatin1String("lastLoginFailed")));
@@ -130,7 +131,7 @@ void SaslAuthOp::promptUser(bool isFirstRun)
QString password;
kDebug() << "Trying to load from wallet";
- KTelepathy::WalletInterface wallet(0);
+ KTp::WalletInterface wallet(0);
if (wallet.hasPassword(m_account) && isFirstRun) {
password = wallet.password(m_account);
} else {
diff --git a/sasl-handler.cpp b/sasl-handler.cpp
index 45a3b10..8121e6f 100644
--- a/sasl-handler.cpp
+++ b/sasl-handler.cpp
@@ -21,7 +21,8 @@
#include "sasl-handler.h"
#include "sasl-auth-op.h"
-#include "common/telepathy-handler-application.h"
+
+#include <KTelepathy/telepathy-handler-application.h>
#include <QDBusConnection>
@@ -59,7 +60,7 @@ void SaslHandler::handleChannels(const Tp::MethodInvocationContextPtr<> &context
Q_ASSERT(channels.size() == 1);
- KTelepathy::TelepathyHandlerApplication::newJob();
+ KTp::TelepathyHandlerApplication::newJob();
SaslAuthOp *auth = new SaslAuthOp(
account, connection, channels.first());
connect(auth,
@@ -90,7 +91,7 @@ void SaslHandler::onAuthFinished(Tp::PendingOperation *op)
}
mAuthContexts.remove(auth);
- KTelepathy::TelepathyHandlerApplication::jobFinished();
+ KTp::TelepathyHandlerApplication::jobFinished();
}
#include "sasl-handler.moc"
diff --git a/tls-handler.cpp b/tls-handler.cpp
index c535af5..62fda8f 100644
--- a/tls-handler.cpp
+++ b/tls-handler.cpp
@@ -20,7 +20,8 @@
#include "tls-handler.h"
#include "tls-cert-verifier-op.h"
-#include "common/telepathy-handler-application.h"
+
+#include <KTelepathy/telepathy-handler-application.h>
#include <QDBusConnection>
@@ -58,7 +59,7 @@ void TlsHandler::handleChannels(const Tp::MethodInvocationContextPtr<> &context,
Q_ASSERT(channels.size() == 1);
- KTelepathy::TelepathyHandlerApplication::newJob();
+ KTp::TelepathyHandlerApplication::newJob();
TlsCertVerifierOp *verifier = new TlsCertVerifierOp(
account, connection, channels.first());
connect(verifier,
@@ -89,7 +90,7 @@ void TlsHandler::onCertVerifierFinished(Tp::PendingOperation *op)
}
mVerifiers.remove(verifier);
- KTelepathy::TelepathyHandlerApplication::jobFinished();
+ KTp::TelepathyHandlerApplication::jobFinished();
}
#include "tls-handler.moc"
--
ktp-auth-handler packaging
More information about the pkg-kde-commits
mailing list