summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2017-03-26 11:20:39 +0200
committerAndreas Sturmlechner <asturm@gentoo.org>2017-03-26 11:24:33 +0200
commitc61e8ac69f13196253142b90d46346c28c57c67f (patch)
tree3d3732ec303ed721b9e062b34c050e75c7ffa7ed /net-im/psi
parentdev-python/translate-toolkit: Drop old (diff)
downloadgentoo-c61e8ac69f13196253142b90d46346c28c57c67f.tar.gz
gentoo-c61e8ac69f13196253142b90d46346c28c57c67f.tar.bz2
gentoo-c61e8ac69f13196253142b90d46346c28c57c67f.zip
net-im/psi: Fix configure w/ >=qconf-2.0
Thanks-to: Rion <rion4ik@gmail.com> Gentoo-bug: 607644 Package-Manager: Portage-2.3.3, Repoman-2.3.1
Diffstat (limited to 'net-im/psi')
-rw-r--r--net-im/psi/files/psi-0.15-qconf-2.patch87
-rw-r--r--net-im/psi/psi-0.15.ebuild3
2 files changed, 89 insertions, 1 deletions
diff --git a/net-im/psi/files/psi-0.15-qconf-2.patch b/net-im/psi/files/psi-0.15-qconf-2.patch
new file mode 100644
index 000000000000..fb62e66f726a
--- /dev/null
+++ b/net-im/psi/files/psi-0.15-qconf-2.patch
@@ -0,0 +1,87 @@
+--- a/qcm/recursiveprl.qcm
++++ a/qcm/recursiveprl.qcm
+@@ -39,10 +39,11 @@ public:
+ return false;
+ }
+
++ QFileInfo fi(qc_getenv("QC_COMMAND"));
+ QStringList args;
+ args += "-prl";
+ args += "-r";
+- args += qc_getenv("QC_PROFILE");
++ args += fi.dir().filePath(qc_getenv("QC_PROFILE"));
+ if(conf->doCommand(conf->qmake_path, args) != 0)
+ {
+ success = false;
+@@ -91,9 +92,9 @@ public:
+ if(!conf->DEFINES.isEmpty())
+ str += "DEFINES += " + conf->DEFINES + '\n';
+ if(!conf->INCLUDEPATH.isEmpty())
+- str += "INCLUDEPATH += " + conf->INCLUDEPATH + '\n';
++ str += "INCLUDEPATH += " + conf->escapedIncludes() + '\n';
+ if(!conf->LIBS.isEmpty())
+- str += "LIBS += " + conf->LIBS + '\n';
++ str += "LIBS += " + conf->escapedLibs() + '\n';
+ if(!conf->extra.isEmpty())
+ str += conf->extra;
+ str += '\n';
+--- a/qcm/zlib.qcm
++++ a/qcm/zlib.qcm
+@@ -21,6 +21,8 @@ public:
+ QStringList incs;
+ QString version, libs, other;
+ QString s;
++
++
+
+ if(!conf->findPkgConfig("zlib", VersionAny, "", &version, &incs, &libs, &other)) {
+
+@@ -33,21 +35,37 @@ public:
+ if(!conf->findHeader("zlib.h", QStringList(), &s))
+ return false;
+ }
+- incs.append(s.replace("\\\", "\\\\\\\"));
+
+- s = conf->getenv("QC_WITH_ZLIB_LIB");
+- if(!s.isEmpty()) {
+- if(!conf->checkLibrary(s, "z"))
+- return false;
+- }
+- else {
+- if(!conf->findLibrary("z", &s))
+- return false;
++ QStringList libNames = QStringList() << "z";
++ QString libName;
++#ifdef Q_OS_WIN
++ libNames << (qc_buildmode_debug? "zlibd" : "zlib");
++#endif
++ for (;;) {
++ s = conf->getenv("QC_WITH_ZLIB_LIB");
++ if(!s.isEmpty()) {
++ foreach (const QString l, libNames)
++ if(conf->checkLibrary(s, l)) {
++ libName = l;
++ break;
++ }
++ } else {
++ foreach (const QString l, libNames)
++ if(conf->findLibrary(l, &s)) {
++ libName = l;
++ break;
++ }
++ }
++
++ if(!libName.isEmpty())
++ break;
++
++ return false;
+ }
+ if (!s.isEmpty()) {
+- libs = QString("-L%1 -lz").arg(s.replace("\\\", "\\\\\\\"));
++ libs = QString("-L%1 -l%2").arg(s, libName);
+ } else {
+- libs = s.isEmpty()? "-lz" : QString("-L%1 -lz").arg(s);
++ libs = s.isEmpty()? QString("-l")+libName : QString("-L%1 -l%2").arg(s, libName);
+ }
+ }
+
diff --git a/net-im/psi/psi-0.15.ebuild b/net-im/psi/psi-0.15.ebuild
index 17f983d83415..2c60b4f0e879 100644
--- a/net-im/psi/psi-0.15.ebuild
+++ b/net-im/psi/psi-0.15.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@@ -51,6 +51,7 @@ FORCE_PRINT_ELOG=1
src_prepare() {
epatch "${FILESDIR}/${PN}-0.14-drop-debug-cflags.patch"
+ epatch "${FILESDIR}/${P}-qconf-2.patch"
epatch_user
qconf || die "Failed to create ./configure."