[X2Go-Commits] [x2goclient] 01/02: x2goclient.pro: detect libssh and libssh_threads via pkgconfig on UNIX-based platforms.
git-admin at x2go.org
git-admin at x2go.org
Tue Oct 30 14:50:59 CET 2018
This is an automated email from the git hooks/post-receive script.
x2go pushed a commit to branch master
in repository x2goclient.
commit b9665ba6c93dc7066c8cd57db1719c87c4f55d41
Author: Mihai Moldovan <ionic at ionic.de>
Date: Tue Oct 30 13:57:30 2018 +0100
x2goclient.pro: detect libssh and libssh_threads via pkgconfig on UNIX-based platforms.
libssh_threads is optional if the libssh version is high enough.
---
debian/changelog | 3 +++
x2goclient.pro | 22 +++++++++++++++++++++-
2 files changed, 24 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index 0a43c2d..e079673 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -29,6 +29,9 @@ x2goclient (4.1.2.2-0x2go1) UNRELEASED; urgency=medium
Qt 5.11+. Fixes: #1307.
- macbuild.sh: switch to bundling PulseAudio 12.1 since it's now available
in MacPorts.
+ - x2goclient.pro: detect libssh and libssh_threads via pkgconfig on
+ UNIX-based platforms. libssh_threads is optional if the libssh version
+ is high enough.
-- X2Go Release Manager <git-admin at x2go.org> Tue, 26 Jun 2018 00:39:28 +0200
diff --git a/x2goclient.pro b/x2goclient.pro
index f628fa3..63c5b9a 100644
--- a/x2goclient.pro
+++ b/x2goclient.pro
@@ -6,6 +6,7 @@ include (x2goclientconfig.pri)
CONFIG += $$(X2GO_CLIENT_TARGET)
CONFIG += $$(X2GO_LINUX_STATIC)
+CONFIG += link_pkgconfig
#CONFIG += console
VERSION = "$$cat($${PWD}/VERSION)"
@@ -132,7 +133,26 @@ SOURCES += src/sharewidget.cpp \
src/compat.cpp \
src/pulsemanager.cpp
-LIBS += -lssh -lssh_threads
+unix {
+ isEmpty(PKG_CONFIG):PKG_CONFIG = pkg-config
+
+ PKGCONFIG += libssh
+
+ # Failure to find libssh_threads is non-fatal, since newer libssh versions
+ # don't ship a separate library any longer.
+ $$system($$PKG_CONFIG --exists "libssh < 0.8.0"):PKGCONFIG += libssh_threads
+}
+win32 {
+ # pkgconfig is... tricky on Windows.
+ # We'll hardcode stuff here. Make sure that it's consistent with the
+ # libraries we use on Windows.
+ LIBS += -lssh -lssh_threads
+}
+else {
+ # For backwards-compatibility.
+ LIBS += -lssh -lssh_threads
+}
+
win32:LIBS += -lAdvAPI32 -lshell32 -lUser32
RC_FILE = res/x2goclient.rc
--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
More information about the x2go-commits
mailing list