summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-im/psi')
-rw-r--r--net-im/psi/Manifest18
-rw-r--r--net-im/psi/files/psi-0.14-drop-debug-cflags.patch35
-rw-r--r--net-im/psi/files/psi-0.14-input-validation.patch257
-rw-r--r--net-im/psi/files/psi-0.14-minizip-detection.patch284
-rw-r--r--net-im/psi/files/psi-0.14-qt-compat.patch40
-rw-r--r--net-im/psi/metadata.xml21
-rw-r--r--net-im/psi/psi-0.14-r4.ebuild171
-rw-r--r--net-im/psi/psi-0.15.ebuild129
-rw-r--r--net-im/psi/psi-9999.ebuild215
9 files changed, 1170 insertions, 0 deletions
diff --git a/net-im/psi/Manifest b/net-im/psi/Manifest
new file mode 100644
index 000000000000..266581a98435
--- /dev/null
+++ b/net-im/psi/Manifest
@@ -0,0 +1,18 @@
+DIST psi-0.14.tar.bz2 2168801 SHA256 aa014a20d59beb23ce2e853fac3d1d70b4b029591627ae0f0a6a3b9f7150a4c0 SHA512 c68e5384afa1a40f1eb5622aa73dd9b1a7902d77b49cad26ac65bf495d688aff17376a738a98e3ff48d3d154abb3a20aad170b95e35bebd1d4e360268746ab3d WHIRLPOOL 95c577c295fad5e4cd54717c34ea2269156be82c480931cce1f140853eaa24be9bf9635d7c192b5da62acc85c145bb61980e00433466a42481ce9a0c3ce8d4da
+DIST psi-0.14_langpack_for_packagers_2009-12-02.zip 2553616 SHA256 27e5cec1847454c9ac3726122b204d923e87c11e1e37e8960c49c17fd4d74dc2 SHA512 5700534afc8f32843c5c56a678aff710edb6619ae4c6c92763c70553221e0078b881f25aa47a6752cfa58582fe617e797bdff32db3071b91521a5ce7f70bdbc9 WHIRLPOOL 79703d1e8a053ab9c0dd09088b26d4adee85d50d69436bff66475860b2bccda675ec5924b22b074fcebaee7cd56a58966a94e9a59f8468015f967eb701bb858a
+DIST psi-0.15.tar.bz2 1984777 SHA256 593b5ddd7934af69c245afb0e7290047fd7dedcfd8765baca5a3a024c569c7e6 SHA512 17e972adc8dfc541977e3717c21eb694f4e1268e4719e97432f260682867290d7034b98a345b6efd73026f98a425493e9159fef9c0e0af4c83b02e07d29a704a WHIRLPOOL 6a8953fe22342dca7347af78da3ea80d5a61a14caa6d62d6910b81730b07b76f156d8d5e1331b2a96dabe5a261353da7af565d999bc7246c25d0d88e010fd983
+DIST psi-0.15_be.qm 255759 SHA256 0e9dbd9e4e738c8fcdd098dde4a17042600b35346a26d2176caa85f6253b6eb6 SHA512 90d623abe9f031af83185fc76d35d5ac390cd726490c6722bdf9ea5b1a6e0179aca650c230280a6390cc121d0e18cb9e2bd1bfd75d9e817eb4e8584d844ed3ad WHIRLPOOL f9d531127f861e5a07659f71433a12cd1d8ad6b805efb83e2d94d219c1e718a28f1390d7025122cdc94d563de99f8f245f4c8ab0297f622ad5712cc6eb4b9667
+DIST psi-0.15_cs.qm 242386 SHA256 d579a7059466c11d4264d8197188a9be49b82e2af35405053ea772c0edea6718 SHA512 46eb273794a99045702f52e10aae2122dfd3db5a49bf68b27e36bf8a1443d8dfbdbcdf550dd0ac3e3ff3014e52010682880f7e883f0d1a0d41d8a678d1e16f2f WHIRLPOOL d2ae4a6045ea1072045032a726927439fe57ae8dfad813f718dd230b36a794945e0600ad1a55f0ac74d73a0d0be4ccf9ffecc5ec9e289ccef5d28566535fbe31
+DIST psi-0.15_de.qm 261756 SHA256 a9470932306466bd41bf08975b2b36eba0c56a8f265d998700f0e929ff345bae SHA512 3e81826215a784f1f58e633bd0fb4c0322370aa0f9c24d18ee38ff1b8a8e85e833e26349806922d1435b99433ee3296c4432a99c5fd8effc383308e168866cb0 WHIRLPOOL 77b7bbe300e450e53dff8a3175e21a8bae6f80ec0524c85599c37ed091c344cbbc63f829ea880f2b3e4c04e2cd06e9cf768ab0a674b9fb79e6c85b1a89290550
+DIST psi-0.15_fr.qm 269774 SHA256 733ec88f9bfbb30e6b21358b233e39319d3ea64223b211566ce1a0b8fe370d1c SHA512 109036baa476ad55cffd2c8109d6e99b91894eb6807ef394ea945973418af0c32641b705da172026a762e041c93b0412f61793fe6858a6c7af44bfec9c13dd1f WHIRLPOOL b51228b2ae93671aae676a0ee7519b290b6edb738f0ca8789b48a4d5b92ee8b32f99675c5f64cf5575a2d4cbbd5ea50e0001f3e06081914fc5a3d003f6f082c0
+DIST psi-0.15_it.qm 257779 SHA256 16d17cc5578f0ef6e8b2ac8dc433e7e050255014d41f2a56651f968829d2a991 SHA512 0cff1398248f7a4802f883cb912e46f27782556e675cc742af4c257910d029237849ce2cb49413f6464b7808296ea2079e5be6d5eb98b39d0dccb8e93d8d89a4 WHIRLPOOL 5e02f342f31518197477055293ae6c4e7c51931c5f985b1d46dadf7b6ef3fcb0a9af4ffe1766d7aeadab82e4f3a45b563cd88cabecf8ef49ebef3e5b56d1d3d6
+DIST psi-0.15_ja.qm 195566 SHA256 e77209493428ae06581e91435eb05ff96f442b60481dbd1a0a1d340e7ba5afc9 SHA512 e34abc4a64832cd7b4d5292a9de3d4a6e58742aa4f3fc2c0ebe60ee14e89bd8ab37b2706ea3faab6b6e7108f4bfcf7c220aae018710fa041930f23efc410ae43 WHIRLPOOL df8acef571d5686f8947e5a92ba4b4ad78cf64cae5ec205ad85c3fb926b18738ac779c30ff51dadc67853a20ffbfc827022adceef4ecdb2271955889658378fd
+DIST psi-0.15_pl.qm 258292 SHA256 abb03e2ef132a343991bdc7b437fe38d24ae77a2ad39500202d645408b919f40 SHA512 8f7b5012a9d68ef50f53e4b8e3671f1cd78eb30f9a464d99225f6f5d3abeb5cea1e941255d7f8729f664d016b89cf42ceb9bd18e3a7b0d68bd4d62954abc6cb0 WHIRLPOOL 1e9c8637b6753286c159dc73d80326fc2ecaf70a5e1bf92c569aeb74192bbd63e7e0e35e69f518f11599cd5828168b2e0a6280f770f9189c811fbe8a9480237f
+DIST psi-0.15_pt_BR.qm 254917 SHA256 b85d2355ebe32cd38ff091fce0444e4fc584c8a6e59c215d820dcc57fd99e3d4 SHA512 c138b1506d60bc2934dea8f06a34dc2f81c2d7cf8a5c35d95b3bd28a0a77a58f4d7e74d2bf13c55f49bd824d7c262087d14c8fcb9e341a42a966fd782d34a394 WHIRLPOOL c710deaa983f772233d39c719b6b65c929533f816b03745337ecbaff3bd69599b721d82748d81612c53e08ede1e03bb6984619823d1c0c2b0a08d2d230b52d79
+DIST psi-0.15_ru.qm 241491 SHA256 24fd952eb457ee20778f8fa2d7486521ec00571743aa1df51ad63ceb6f368527 SHA512 876695f2501661554a865873f11ad7a466ce96e4b3f896c7b3c1e049647d9968e88f9ea893d4aace8837d4387a936973b2fd36e1034b6856d45bd73088446176 WHIRLPOOL cb18bd74ed3eec6071531c468cdc972e448ad34f79f092c981a13a24f05f2100ec3660dce59033a439733eb0a35dde6cb14c2506b96c16f9ff78e1c4af3527fc
+DIST psi-0.15_sl.qm 248478 SHA256 5be33716a12b297d609ec7493f9da21a23b3ab89303dc6be62a2240c0992adec SHA512 5aa316f05441524b16803a78f394b7e823c2019fb2828dc83b0cdab1b8eb0d8da2b8f3496aa34381bcea17bb7225a67582ff3f5321011bce4dae499aafdf76d6 WHIRLPOOL e4e8f74ab8538fe12f82bc0951823be94c59b91a494500e0c2f00ebc0bd95900f008664a397acf8e03565b3bfde8d6eefb7234367876372a33e49833f41fa718
+DIST psi-0.15_sv.qm 246214 SHA256 fc5822011ada2b7452c9d15baf74c90e1a58e05536e9a7cc1d81e163f44d3ca2 SHA512 b8dd5e7692512af5ec302b5fee562feb68292988160d1c9e4fac951562bd8b30bc1f67f4d39bbd437eee84b14f6aefd83a8666f0e77d02b539d65e89aee7c1aa WHIRLPOOL 6078437c20881babb731d8915952b40d415e5cc01ab7431be1930fbe887289988abc7ef9a76e09254ad8519146bd94633eba69872bee7cdb504dfc3237f1c1d0
+DIST psi-0.15_ur_PK.qm 244903 SHA256 0101370007c9ce735c50dd9bf6dfd8680c5cd562a3213b960ee507367582b3e6 SHA512 df0786f1b625ecc3144bb9be0ce51558ae45901213405997b5f8ea3c791c64328b049a48a1b88372f7b0cb5bde3b795b306ad16847d91933eedc233f8dea8bc2 WHIRLPOOL 3dc2f807d5e1dce36609854e9360d9521a7fe36d61161a2c0cf195bf58e21a4efa9b8d977a6503f41588d8befb06ca678e6e629168c93f0ab90f0ec42ffe98a5
+DIST psi-0.15_zh_TW.qm 171993 SHA256 a68897a3fe5653b4ea9651a7dc05486aadc9327fcfa96ceae84a6cfbeed4187a SHA512 69b20e18f346af244f7cfd2bc447fcb934786f7ff3d85a16ac471e275c78fb36cfb2008368d81413dbfc6ed5bd4edba3c1ab8185dae72b8aeb9bfa29fde9c871 WHIRLPOOL 2dd1e8e724007248128d69ec9389014d482d38b64df3dbcb1a17c90b94d193d793b17769d78cd36fd15d8409f1eac44eca4a2d7739d885316754df5b557a7344
+DIST psi-extra-iconsets-r1428.tar.bz2 3214991 SHA256 1c7cb4a6915c43e7728b96d8eadd4d1359561f40169f10f1051a2c63c3bfbe1c SHA512 b6a74fc9b043800040c519504b14bcb5f44864b9115ea167b235a791bafc17c96986ffaf5b6f9ebe4dd3b467b8e472e7c9bf253893e59581a29ad2342b122bfc WHIRLPOOL a030ca57a5f11f46d17a19d8b2f109d043e6b4eed20fbdf406dd71b647a8bb923ecf24f1ed3f2197cdcaf9637b67fd39d52fd7ef6a174a4fc352cc5008da5759
+DIST psi-extra-patches-r1428.tar.bz2 131700 SHA256 a458f44773c53abe369b174d220038d3b1dce6bbab981d6baf7ca48ec211cf48 SHA512 6fe55bb5c97e672c05eb125defa590cce9575be339a7366d49c2c50aff19fc7d9a5dcf7feece4781e88cd3504c8e959a637c1a4a3e571d52c42e63edc0f60a78 WHIRLPOOL 9e70a07eb8fef72606e28ae2151003aebba724f86b29f9c46f3850a77b1647d9ce5746576c3e41f79b885b162b9889f233f77c2c5766103f5add6d5bc8088b40
diff --git a/net-im/psi/files/psi-0.14-drop-debug-cflags.patch b/net-im/psi/files/psi-0.14-drop-debug-cflags.patch
new file mode 100644
index 000000000000..227265696ae6
--- /dev/null
+++ b/net-im/psi/files/psi-0.14-drop-debug-cflags.patch
@@ -0,0 +1,35 @@
+Drop -g from CFLAGS
+
+--- qcm/buildmodeapp.qcm 2011-10-19 14:38:55.621699641 +0200
++++ qcm/buildmodeapp.qcm 2011-10-19 14:39:11.868700486 +0200
+@@ -130,8 +130,6 @@
+ if(qc_buildmode_separate_debug_info)
+ {
+ opts += "separate_debug_info";
+- other += "*-g++*:QMAKE_CFLAGS += -g\n";
+- other += "*-g++*:QMAKE_CXXFLAGS += -g\n";
+ }
+
+ QString str = QString("CONFIG += ") + opts.join(" ") + '\n';
+--- iris/qcm/extra.qcm.old 2011-10-19 14:39:40.268701738 +0200
++++ iris/qcm/extra.qcm 2011-10-19 14:40:01.904699887 +0200
+@@ -55,8 +55,6 @@
+ if(debug_info)
+ {
+ str += QString("CONFIG += separate_debug_info\n");
+- str += "QMAKE_CFLAGS += -g\n";
+- str += "QMAKE_CXXFLAGS += -g\n";
+ }
+ if(universal)
+ {
+--- iris/qcm/buildmode.qcm.old 2011-10-19 14:40:23.794701147 +0200
++++ iris/qcm/buildmode.qcm 2011-10-19 14:40:42.157701302 +0200
+@@ -186,8 +186,6 @@
+ if(qc_buildmode_separate_debug_info)
+ {
+ opts += "separate_debug_info";
+- other += "QMAKE_CFLAGS += -g\n";
+- other += "QMAKE_CXXFLAGS += -g\n";
+ }
+
+ QString str = QString("CONFIG += ") + opts.join(" ") + '\n';
diff --git a/net-im/psi/files/psi-0.14-input-validation.patch b/net-im/psi/files/psi-0.14-input-validation.patch
new file mode 100644
index 000000000000..7260c80e1ff9
--- /dev/null
+++ b/net-im/psi/files/psi-0.14-input-validation.patch
@@ -0,0 +1,257 @@
+commit c68fdd9926a38b2820bc5df97fd1905355a2640d
+Author: rion <rion4ik@gmail.com>
+Date: Fri Oct 7 22:19:05 2011 +0600
+
+ Fixed QLabel CVE
+
+--- src/Certificates/CertificateDisplay.ui 2011-10-19 08:30:15 +0000
++++ src/Certificates/CertificateDisplay.ui 2011-10-19 08:31:23 +0000
+@@ -1,105 +1,118 @@
+-<ui version="4.0" >
++<?xml version="1.0" encoding="UTF-8"?>
++<ui version="4.0">
+ <class>CertificateDisplay</class>
+- <widget class="QDialog" name="CertificateDisplay" >
+- <property name="geometry" >
++ <widget class="QDialog" name="CertificateDisplay">
++ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+- <width>518</width>
++ <width>525</width>
+ <height>369</height>
+ </rect>
+ </property>
+- <property name="windowTitle" >
++ <property name="windowTitle">
+ <string>Certificate Information</string>
+ </property>
+- <layout class="QVBoxLayout" >
+- <property name="margin" >
++ <layout class="QVBoxLayout">
++ <property name="spacing">
++ <number>6</number>
++ </property>
++ <property name="margin">
+ <number>11</number>
+ </property>
+- <property name="spacing" >
+- <number>6</number>
+- </property>
+ <item>
+- <layout class="QHBoxLayout" >
+- <property name="margin" >
++ <layout class="QHBoxLayout">
++ <property name="spacing">
++ <number>6</number>
++ </property>
++ <property name="margin">
+ <number>0</number>
+ </property>
+- <property name="spacing" >
+- <number>6</number>
+- </property>
+ <item>
+- <layout class="QVBoxLayout" >
+- <property name="margin" >
++ <layout class="QVBoxLayout">
++ <property name="spacing">
++ <number>6</number>
++ </property>
++ <property name="margin">
+ <number>0</number>
+ </property>
+- <property name="spacing" >
+- <number>6</number>
+- </property>
+ <item>
+- <widget class="QLabel" name="textLabel4" >
+- <property name="text" >
++ <widget class="QLabel" name="textLabel4">
++ <property name="text">
+ <string>Certificate Validation:</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="lb_valid" >
+- <property name="text" >
++ <widget class="QLabel" name="lb_valid">
++ <property name="text">
+ <string/>
+ </property>
++ <property name="textFormat">
++ <enum>Qt::PlainText</enum>
++ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="textLabel2" >
+- <property name="text" >
++ <widget class="QLabel" name="textLabel2">
++ <property name="text">
+ <string>Valid From:</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="lb_notBefore" >
+- <property name="text" >
++ <widget class="QLabel" name="lb_notBefore">
++ <property name="text">
+ <string/>
+ </property>
++ <property name="textFormat">
++ <enum>Qt::PlainText</enum>
++ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="textLabel3" >
+- <property name="text" >
++ <widget class="QLabel" name="textLabel3">
++ <property name="text">
+ <string>Valid Until:</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="lb_notAfter" >
+- <property name="text" >
++ <widget class="QLabel" name="lb_notAfter">
++ <property name="text">
+ <string/>
+ </property>
++ <property name="textFormat">
++ <enum>Qt::PlainText</enum>
++ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="textLabel1" >
+- <property name="text" >
++ <widget class="QLabel" name="textLabel1">
++ <property name="text">
+ <string>Serial Number:</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+- <widget class="QLabel" name="lb_sn" >
+- <property name="text" >
++ <widget class="QLabel" name="lb_sn">
++ <property name="text">
+ <string/>
+ </property>
++ <property name="textFormat">
++ <enum>Qt::PlainText</enum>
++ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer>
+- <property name="orientation" >
++ <property name="orientation">
+ <enum>Qt::Vertical</enum>
+ </property>
+- <property name="sizeType" >
++ <property name="sizeType">
+ <enum>QSizePolicy::Expanding</enum>
+ </property>
+- <property name="sizeHint" >
++ <property name="sizeHint" stdset="0">
+ <size>
+ <width>20</width>
+ <height>106</height>
+@@ -110,14 +123,14 @@
+ </layout>
+ </item>
+ <item>
+- <widget class="QTextBrowser" name="tb_cert" >
+- <property name="minimumSize" >
++ <widget class="QTextBrowser" name="tb_cert">
++ <property name="minimumSize">
+ <size>
+ <width>350</width>
+ <height>300</height>
+ </size>
+ </property>
+- <property name="horizontalScrollBarPolicy" >
++ <property name="horizontalScrollBarPolicy">
+ <enum>Qt::ScrollBarAlwaysOff</enum>
+ </property>
+ </widget>
+@@ -125,35 +138,35 @@
+ </layout>
+ </item>
+ <item>
+- <widget class="Line" name="line1" >
+- <property name="frameShape" >
++ <widget class="Line" name="line1">
++ <property name="frameShape">
+ <enum>QFrame::HLine</enum>
+ </property>
+- <property name="frameShadow" >
++ <property name="frameShadow">
+ <enum>QFrame::Sunken</enum>
+ </property>
+- <property name="orientation" >
++ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ </widget>
+ </item>
+ <item>
+- <layout class="QHBoxLayout" >
+- <property name="margin" >
++ <layout class="QHBoxLayout">
++ <property name="spacing">
++ <number>6</number>
++ </property>
++ <property name="margin">
+ <number>0</number>
+ </property>
+- <property name="spacing" >
+- <number>6</number>
+- </property>
+ <item>
+ <spacer>
+- <property name="orientation" >
++ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+- <property name="sizeType" >
++ <property name="sizeType">
+ <enum>QSizePolicy::Expanding</enum>
+ </property>
+- <property name="sizeHint" >
++ <property name="sizeHint" stdset="0">
+ <size>
+ <width>421</width>
+ <height>20</height>
+@@ -162,17 +175,17 @@
+ </spacer>
+ </item>
+ <item>
+- <widget class="QPushButton" native="1" name="pb_close">
+- <property name="text">
+- <string>Close</string>
+- </property>
+- </widget>
++ <widget class="QPushButton" name="pb_close">
++ <property name="text">
++ <string>Close</string>
++ </property>
++ </widget>
+ </item>
+ </layout>
+ </item>
+ </layout>
+ </widget>
+- <layoutdefault spacing="6" margin="11" />
++ <layoutdefault spacing="6" margin="11"/>
+ <pixmapfunction>qPixmapFromMimeSource</pixmapfunction>
+ <tabstops>
+ <tabstop>tb_cert</tabstop>
+
diff --git a/net-im/psi/files/psi-0.14-minizip-detection.patch b/net-im/psi/files/psi-0.14-minizip-detection.patch
new file mode 100644
index 000000000000..1eff6dadec4d
--- /dev/null
+++ b/net-im/psi/files/psi-0.14-minizip-detection.patch
@@ -0,0 +1,284 @@
+=== modified file 'conf_windows.pri'
+--- conf_windows.pri 2011-10-25 10:03:42 +0000
++++ conf_windows.pri 2011-10-25 10:04:13 +0000
+@@ -5,7 +5,7 @@
+ #CONFIG += qca-static
+
+ # tell iris to use our internal libz
+-CONFIG += psi-zip
++CONFIG += psi-winzlib
+
+ # OpenSSL
+ qca-static {
+
+=== modified file 'configure'
+--- configure 2011-10-25 10:03:42 +0000
++++ configure 2011-10-25 10:04:13 +0000
+@@ -955,41 +955,68 @@
+ {
+ #ifdef Q_OS_WIN
+ // HACK: on windows, always use psi's bundled zlib
+- conf->addExtra("CONFIG += psi-zip");
++ conf->addExtra("CONFIG += psi-winzlib psi-minizip");
+ return true;
+ #else
+- QString inc, lib;
++ QStringList incs;
++ QString version, libs, other;
+ QString s;
+
+- s = conf->getenv("QC_WITH_ZLIB_INC");
+- if(!s.isEmpty()) {
+- if(!conf->checkHeader(s, "zlib.h"))
+- return false;
+- inc = s;
+- }
+- else {
+- if(!conf->findHeader("zlib.h", QStringList(), &s))
+- return false;
+- inc = s;
+- }
+-
+- s = conf->getenv("QC_WITH_ZLIB_LIB");
+- if(!s.isEmpty()) {
+- if(!conf->checkLibrary(s, "z"))
+- return false;
+- lib = s;
+- }
+- else {
+- if(!conf->findLibrary("z", &s))
+- return false;
+- lib = s;
+- }
+-
+- if(!inc.isEmpty())
++ if(!conf->findPkgConfig("zlib", VersionAny, "", &version, &incs, &libs, &other)) {
++
++ s = conf->getenv("QC_WITH_ZLIB_INC");
++ if(!s.isEmpty()) {
++ if(!conf->checkHeader(s, "zlib.h"))
++ return false;
++ }
++ else {
++ if(!conf->findHeader("zlib.h", QStringList(), &s))
++ return false;
++ }
++ incs.append(s);
++
++ 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;
++ }
++ libs = QString("-L%1 -lz").arg(s);
++ }
++
++ foreach(const QString &inc, incs) {
+ conf->addIncludePath(inc);
+- if(!lib.isEmpty())
+- conf->addLib(QString("-L") + s);
+- conf->addLib("-lz");
++ }
++ conf->addLib(libs);
++
++ incs.clear();
++ libs.clear();
++ if(!conf->findPkgConfig("minizip", VersionAny, "", &version, &incs, &libs, &other)) {
++
++ s = conf->getenv("QC_WITH_MINIZIP_INC");
++ if ((!s.isEmpty() && conf->checkHeader(s, "unzip.h")) ||
++ (s.isEmpty() && conf->findHeader("unzip.h", QStringList(), &s))) {
++ incs.append(s);
++ }
++
++ s = conf->getenv("QC_WITH_MINIZIP_LIB");
++ if((!s.isEmpty() && conf->checkLibrary(s, "minizip")) ||
++ (s.isEmpty() && conf->findLibrary("minizip", &s))) {
++ libs = QString("-L%1 -lminizip").arg(s);
++ }
++ }
++
++ if (!incs.isEmpty() && !libs.isEmpty()) {
++ foreach(const QString &inc, incs) {
++ conf->addIncludePath(inc);
++ }
++ conf->addLib(libs);
++ } else {
++ conf->addExtra("CONFIG += psi-minizip");
++ }
+
+ return true;
+ #endif
+
+=== modified file 'qcm/zlib.qcm'
+--- qcm/zlib.qcm 2011-10-25 10:03:42 +0000
++++ qcm/zlib.qcm 2011-10-25 10:04:13 +0000
+@@ -26,41 +26,68 @@
+ {
+ #ifdef Q_OS_WIN
+ // HACK: on windows, always use psi's bundled zlib
+- conf->addExtra("CONFIG += psi-zip");
++ conf->addExtra("CONFIG += psi-winzlib psi-minizip");
+ return true;
+ #else
+- QString inc, lib;
++ QStringList incs;
++ QString version, libs, other;
+ QString s;
+
+- s = conf->getenv("QC_WITH_ZLIB_INC");
+- if(!s.isEmpty()) {
+- if(!conf->checkHeader(s, "zlib.h"))
+- return false;
+- inc = s;
+- }
+- else {
+- if(!conf->findHeader("zlib.h", QStringList(), &s))
+- return false;
+- inc = s;
+- }
+-
+- s = conf->getenv("QC_WITH_ZLIB_LIB");
+- if(!s.isEmpty()) {
+- if(!conf->checkLibrary(s, "z"))
+- return false;
+- lib = s;
+- }
+- else {
+- if(!conf->findLibrary("z", &s))
+- return false;
+- lib = s;
+- }
+-
+- if(!inc.isEmpty())
++ if(!conf->findPkgConfig("zlib", VersionAny, "", &version, &incs, &libs, &other)) {
++
++ s = conf->getenv("QC_WITH_ZLIB_INC");
++ if(!s.isEmpty()) {
++ if(!conf->checkHeader(s, "zlib.h"))
++ return false;
++ }
++ else {
++ if(!conf->findHeader("zlib.h", QStringList(), &s))
++ return false;
++ }
++ incs.append(s);
++
++ 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;
++ }
++ libs = QString("-L%1 -lz").arg(s);
++ }
++
++ foreach(const QString &inc, incs) {
+ conf->addIncludePath(inc);
+- if(!lib.isEmpty())
+- conf->addLib(QString("-L") + s);
+- conf->addLib("-lz");
++ }
++ conf->addLib(libs);
++
++ incs.clear();
++ libs.clear();
++ if(!conf->findPkgConfig("minizip", VersionAny, "", &version, &incs, &libs, &other)) {
++
++ s = conf->getenv("QC_WITH_MINIZIP_INC");
++ if ((!s.isEmpty() && conf->checkHeader(s, "unzip.h")) ||
++ (s.isEmpty() && conf->findHeader("unzip.h", QStringList(), &s))) {
++ incs.append(s);
++ }
++
++ s = conf->getenv("QC_WITH_MINIZIP_LIB");
++ if((!s.isEmpty() && conf->checkLibrary(s, "minizip")) ||
++ (s.isEmpty() && conf->findLibrary("minizip", &s))) {
++ libs = QString("-L%1 -lminizip").arg(s);
++ }
++ }
++
++ if (!incs.isEmpty() && !libs.isEmpty()) {
++ foreach(const QString &inc, incs) {
++ conf->addIncludePath(inc);
++ }
++ conf->addLib(libs);
++ } else {
++ conf->addExtra("CONFIG += psi-minizip");
++ }
+
+ return true;
+ #endif
+
+=== modified file 'src/conf_iris.pri'
+--- src/conf_iris.pri 2011-10-25 10:03:42 +0000
++++ src/conf_iris.pri 2011-10-25 10:04:13 +0000
+@@ -13,11 +13,6 @@
+ CONFIG += crypto
+ }
+
+-# use zlib from psi if necessary
+-psi-zip {
+- INCLUDEPATH += $$PWD/libpsi/tools/zip/minizip/win32
+-}
+-
+ mac {
+ # Universal binaries
+ qc_universal:contains(QT_CONFIG,x86):contains(QT_CONFIG,ppc) {
+
+=== modified file 'src/libpsi/tools/zip/zip.cpp'
+--- src/libpsi/tools/zip/zip.cpp 2011-10-25 10:03:42 +0000
++++ src/libpsi/tools/zip/zip.cpp 2011-10-25 10:04:13 +0000
+@@ -22,7 +22,11 @@
+ #include <QStringList>
+ #include <QFile>
+
++#ifdef PSIMINIZIP
+ #include "minizip/unzip.h"
++#else
++#include <minizip/unzip.h>
++#endif
+ #include "zip.h"
+
+ class UnZipPrivate
+
+=== modified file 'src/libpsi/tools/zip/zip.pri'
+--- src/libpsi/tools/zip/zip.pri 2011-10-25 10:03:42 +0000
++++ src/libpsi/tools/zip/zip.pri 2011-10-25 10:04:13 +0000
+@@ -2,17 +2,20 @@
+ $$PWD/zip.h
+
+ SOURCES += \
+- $$PWD/zip.cpp \
+- $$PWD/minizip/unzip.c
+-
+-INCLUDEPATH += $$PWD
+-DEPENDPATH += $$PWD
+-
+-win32: {
++ $$PWD/zip.cpp
++
++psi-minizip {
++ SOURCES += $$PWD/minizip/unzip.c
++ DEFINES += PSIMINIZIP
++ INCLUDEPATH += $$PWD
++ DEPENDPATH += $$PWD
++}
++
++psi-winzlib {
+ INCLUDEPATH += $$PWD/minizip/win32
+ DEPENDPATH += $$PWD/minizip/win32
+ LIBS += $$PWD/minizip/win32/libz.a
+ }
+-mac: {
++mac {
+ QMAKE_LFLAGS += -lz
+ }
+
diff --git a/net-im/psi/files/psi-0.14-qt-compat.patch b/net-im/psi/files/psi-0.14-qt-compat.patch
new file mode 100644
index 000000000000..99fa30794590
--- /dev/null
+++ b/net-im/psi/files/psi-0.14-qt-compat.patch
@@ -0,0 +1,40 @@
+commit ec91add0e6398ad20c7a8f14a1a08c5e3282c5bd
+Author: Michail Pishchagin <mblsha@users.sourceforge.net>
+Date: Tue Oct 19 11:26:31 2010 +0400
+
+ Fix crash in MUCAffiliationsModel on Qt 4.7 (closes #1087)
+ Based on 1610-psi-fix-crash-in-muc-configurator.diff from Psi+
+
+diff --git a/src/mucaffiliationsmodel.cpp b/src/mucaffiliationsmodel.cpp
+index 722b762..fd0a830 100644
+--- a/src/mucaffiliationsmodel.cpp
++++ b/src/mucaffiliationsmodel.cpp
+@@ -150,15 +150,18 @@ void MUCAffiliationsModel::resetAffiliationLists()
+
+ void MUCAffiliationsModel::resetAffiliationList(MUCItem::Affiliation a)
+ {
++ emit layoutAboutToBeChanged();
+ enabled_[(AffiliationListIndex) affiliationToIndex(a)] = false;
+ QModelIndex index = affiliationListIndex(a);
+ if (hasChildren(index)) {
+ removeRows(0,rowCount(index),index);
+ }
++ emit layoutChanged();
+ }
+
+ void MUCAffiliationsModel::setAffiliationListEnabled(MUCItem::Affiliation a, bool b)
+ {
++ emit layoutAboutToBeChanged();
+ QModelIndex index = affiliationListIndex(a);
+ enabled_[(AffiliationListIndex) index.row()] = b;
+ emit layoutChanged();
+@@ -208,6 +211,9 @@ void MUCAffiliationsModel::addItems(const QList<MUCItem>& items)
+ foreach(MUCItem item, items) {
+ QModelIndex list = affiliationListIndex(item.affiliation());
+ if (list.isValid() && !item.jid().isEmpty()) {
++ if (!dirty) {
++ emit layoutAboutToBeChanged();
++ }
+ int row = rowCount(list);
+ if (row == 0) {
+ enabled_[(AffiliationListIndex) list.row()] = true;
diff --git a/net-im/psi/metadata.xml b/net-im/psi/metadata.xml
new file mode 100644
index 000000000000..4c567f244b8b
--- /dev/null
+++ b/net-im/psi/metadata.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>net-im</herd>
+<herd>proxy-maintainers</herd>
+<maintainer>
+ <email>nikoli@gmx.us</email>
+ <name>Nikoli</name>
+</maintainer>
+<longdescription>Psi is a very good jabber client that uses QT</longdescription>
+<use>
+ <flag name='enchant'>Use enchant spell engine instead of aspell</flag>
+ <flag name='extras'>Enables extra non official patches</flag>
+ <flag name='iconsets'>Install additional iconsets, some of them has not clear licensing</flag>
+ <flag name='plugins'>Enable plugins support</flag>
+ <flag name='powersave'>Disable some non critical timers for much less CPU usage</flag>
+ <flag name='webkit'>Enable chatlog rendering using webkit</flag>
+ <flag name='whiteboarding'>Enable experimental interactive SVG drawing</flag>
+ <flag name='xscreensaver'>Use X screensaver protocol extension to monitor idle/active status based on mouse/keyboard events</flag>
+</use>
+</pkgmetadata>
diff --git a/net-im/psi/psi-0.14-r4.ebuild b/net-im/psi/psi-0.14-r4.ebuild
new file mode 100644
index 000000000000..c67b4e010128
--- /dev/null
+++ b/net-im/psi/psi-0.14-r4.ebuild
@@ -0,0 +1,171 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+inherit eutils qt4-r2 multilib
+
+MY_P="${P/_rc/-rc}"
+
+DESCRIPTION="Qt4 Jabber client, with Licq-like interface"
+HOMEPAGE="http://psi-im.org/"
+# Langpack:
+# http://lists.affinix.com/pipermail/psi-devel-affinix.com/2009-August/008798.html
+# Later found his site: http://fs.scs-tsa.de/psi_l10n/
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.bz2
+ http://fs.scs-tsa.de/psi_l10n/psi-0.14_langpack_for_packagers_2009-12-02.zip
+ extras? ( mirror://gentoo/${PN}-extra-patches-r1428.tar.bz2
+ mirror://gentoo/${PN}-extra-iconsets-r1428.tar.bz2 )"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ~arm hppa ppc ppc64 x86 ~x86-fbsd"
+IUSE="crypt dbus debug doc extras jingle spell ssl xscreensaver webkit"
+RESTRICT="test"
+
+LANGS="be cs de fr it ja pl pt_BR ru sl sv ur_PK zh_TW"
+for LNG in ${LANGS}; do
+ IUSE="${IUSE} linguas_${LNG}"
+ #SRC_URI="${SRC_URI} http://psi-im.org/download/lang/psi_${LNG/ur_PK/ur_pk}.qm"
+done
+
+RDEPEND="
+ app-arch/unzip
+ =app-crypt/qca-2.0*[qt4(+)]
+ dev-qt/qt3support:4
+ dev-qt/qtcore:4
+ dev-qt/qtgui:4[qt3support]
+ >=sys-libs/zlib-1.2.5.1-r2[minizip]
+ dbus? ( dev-qt/qtdbus:4 )
+ extras? ( webkit? ( dev-qt/qtwebkit:4 ) )
+ spell? ( >=app-text/enchant-1.3.0 )
+ xscreensaver? ( x11-libs/libXScrnSaver )
+"
+DEPEND="${RDEPEND}
+ sys-devel/qconf
+ doc? ( app-doc/doxygen )
+"
+PDEPEND="
+ crypt? ( app-crypt/qca:2[gpg] )
+ jingle? (
+ net-im/psimedia
+ app-crypt/qca:2[openssl]
+ )
+ ssl? ( app-crypt/qca:2[openssl] )
+"
+
+S=${WORKDIR}/${MY_P}
+
+src_prepare() {
+ epatch "${FILESDIR}/psi-0.14-qt-compat.patch"
+ epatch "${FILESDIR}/psi-0.14-minizip-detection.patch"
+ epatch "${FILESDIR}/psi-0.14-input-validation.patch"
+ epatch "${FILESDIR}/psi-0.14-drop-debug-cflags.patch"
+ sed -i '/#include <errno.h>/a #include <unistd.h>' \
+ iris/src/irisnet/corelib/netinterface_unix.cpp || die 'sed failed'
+
+ if use extras; then
+ # some patches from psi+ project http://code.google.com/p/psi-dev
+ ewarn "You're about to build heavily patched version of Psi called Psi+."
+ ewarn "It has really nice features but still is under heavy development."
+ ewarn "Take a look at homepage for more info: http://code.google.com/p/psi-dev"
+ ewarn "If you wish to disable some patches just put"
+ ewarn "MY_EPATCH_EXCLUDE=\"list of patches\""
+ ewarn "into /etc/portage/env/${CATEGORY}/${PN} file."
+ ewarn
+ ewarn "Note: some patches depend on other. So if you disabled some patch"
+ ewarn "and other started to fail to apply, you'll have to disable patches"
+ ewarn "that fail too."
+
+ EPATCH_EXCLUDE="${MY_EPATCH_EXCLUDE}
+ 005-less-includes.diff
+ 755-psiplus-fix-application-info-defines.diff
+ 9999-psiplus-application-info.diff" \
+ EPATCH_SUFFIX="diff" EPATCH_FORCE="yes" epatch
+ sed -e 's/\(^#define PROG_CAPS_NODE \).*/\1"http:\/\/psi-dev.googlecode.com\/caps";/' \
+ -e 's:\(^#define PROG_NAME "Psi\):\1+:' \
+ -i src/applicationinfo.cpp || die
+ else
+ if use webkit; then
+ ewarn "Webkit support disabled as it is only available in Psi+"
+ ewarn "(USE='extras' enabled)."
+ fi
+ fi
+
+ qconf || die "Failed to create ./configure."
+ rm -rf third-party/qca || die # We use system libraries.
+}
+
+src_configure() {
+ # unable to use econf because of non-standard configure script
+ # disable growl as it is a MacOS X extension only
+ local confcmd="./configure
+ --prefix=/usr
+ --qtdir=/usr
+ --disable-bundled-qca
+ --disable-growl
+ $(use dbus || echo '--disable-qdbus')
+ $(use debug && echo '--debug')
+ $(use spell || echo '--disable-aspell')
+ $(use spell || echo '--disable-enchant')
+ $(use xscreensaver || echo '--disable-xss')
+ $(use extras && { use webkit && echo '--enable-qtwebkit';} )"
+
+ echo ${confcmd}
+ ${confcmd} || die "configure failed"
+ # Makefile is not always created...
+ [[ ! -f Makefile ]] && die "configure failed"
+}
+
+src_compile() {
+ eqmake4
+
+ emake
+
+ if use doc; then
+ cd doc || die
+ mkdir -p api || die # 259632
+ emake api_public
+ fi
+}
+
+src_install() {
+ emake INSTALL_ROOT="${D}" install
+ rm "${D}"/usr/share/psi/{COPYING,README} || die
+
+ # this way the docs will be installed in the standard gentoo dir
+ newdoc iconsets/roster/README README.roster
+ newdoc iconsets/system/README README.system
+ newdoc certs/README README.certs
+ dodoc README
+
+ if use doc; then
+ cd doc || die
+ dohtml -r api
+ fi
+
+ # install translations
+ cd "${WORKDIR}" || die
+ insinto /usr/share/${PN}/
+ local nolangs=true
+ for LNG in ${LANGS}; do
+ if use linguas_${LNG}; then
+ doins ${LNG}/${PN}_${LNG}.qm
+ newins ${LNG}/INFO INFO.${LNG}
+ nolangs=false
+ fi
+ done
+
+ # if linguas is empty install all translations
+ if ${nolangs}; then
+ for LNG in ${LANGS}; do
+ doins ${LNG}/${PN}_${LNG}.qm
+ newins ${LNG}/INFO INFO.${LNG}
+ done
+ fi
+
+ if use extras; then
+ cp -a "${WORKDIR}"/iconsets/* "${D}"/usr/share/${PN}/iconsets/ || die
+ fi
+}
diff --git a/net-im/psi/psi-0.15.ebuild b/net-im/psi/psi-0.15.ebuild
new file mode 100644
index 000000000000..57c82bc86d5e
--- /dev/null
+++ b/net-im/psi/psi-0.15.ebuild
@@ -0,0 +1,129 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+PLOCALES="be cs de fr it ja pl pt_BR ru sl sv ur_PK zh_TW"
+inherit eutils l10n multilib gnome2-utils qt4-r2 readme.gentoo
+
+DESCRIPTION="Qt4 Jabber client, with Licq-like interface"
+HOMEPAGE="http://psi-im.org/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
+
+for LNG in ${PLOCALES}; do
+ SRC_URI="${SRC_URI}
+ linguas_${LNG}? ( http://psi-im.org/download/lang/${PN}_${LNG}.qm -> ${P}_${LNG}.qm )"
+done
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ~arm ~hppa ~ppc ~ppc64 x86 ~x86-fbsd"
+IUSE="crypt dbus debug doc jingle spell ssl xscreensaver whiteboarding"
+RESTRICT="test"
+
+RDEPEND="
+ app-arch/unzip
+ >=app-crypt/qca-2.0.2:2[qt4(+)]
+ dev-qt/qtcore:4
+ dev-qt/qtgui:4
+ >=sys-libs/zlib-1.2.5.1-r2[minizip]
+ x11-libs/libX11
+ dbus? ( dev-qt/qtdbus:4 )
+ spell? ( >=app-text/enchant-1.3.0 )
+ whiteboarding? ( dev-qt/qtsvg:4 )
+ xscreensaver? ( x11-libs/libXScrnSaver )
+"
+DEPEND="${RDEPEND}
+ sys-devel/qconf
+ doc? ( app-doc/doxygen )
+"
+PDEPEND="
+ crypt? ( app-crypt/qca:2[gpg] )
+ jingle? (
+ net-im/psimedia
+ app-crypt/qca:2[openssl]
+ )
+ ssl? ( app-crypt/qca:2[openssl] )
+"
+
+DOC_CONTENTS='Psi+ support(USE="extras") was removed from ebuild since 0.15'
+FORCE_PRINT_ELOG=1
+
+src_prepare() {
+ epatch "${FILESDIR}/${PN}-0.14-drop-debug-cflags.patch"
+ epatch_user
+
+ qconf || die "Failed to create ./configure."
+}
+
+src_configure() {
+ # unable to use econf because of non-standard configure script
+ # disable growl as it is a MacOS X extension only
+ local confcmd="./configure
+ --prefix=/usr
+ --qtdir=/usr
+ --disable-growl
+ $(use dbus || echo '--disable-qdbus')
+ $(use debug && echo '--debug')
+ $(use spell || echo '--disable-aspell')
+ $(use spell || echo '--disable-enchant')
+ $(use xscreensaver || echo '--disable-xss')
+ $(use whiteboarding && echo '--enable-whiteboarding')"
+
+ echo ${confcmd}
+ ${confcmd} || die "configure failed"
+ # Makefile is not always created...
+ [[ ! -f Makefile ]] && die "configure failed"
+}
+
+src_compile() {
+ eqmake4
+
+ emake
+
+ if use doc; then
+ cd doc || die
+ mkdir -p api || die # 259632
+ emake api_public
+ fi
+}
+
+src_install() {
+ install_locale() {
+ newins "${DISTDIR}/${P}_${1}.qm" "${PN}_${1}.qm"
+ }
+
+ emake INSTALL_ROOT="${D}" install
+ rm "${D}"/usr/share/psi/{COPYING,README} || die
+
+ readme.gentoo_create_doc
+
+ # this way the docs will be installed in the standard gentoo dir
+ newdoc iconsets/roster/README README.roster
+ newdoc iconsets/system/README README.system
+ newdoc certs/README README.certs
+ dodoc README
+
+ if use doc; then
+ cd doc || die
+ dohtml -r api
+ fi
+
+ # install translations
+ insinto /usr/share/${PN}
+ l10n_for_each_locale_do install_locale
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ readme.gentoo_pkg_postinst
+ gnome2_icon_cache_update
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+}
diff --git a/net-im/psi/psi-9999.ebuild b/net-im/psi/psi-9999.ebuild
new file mode 100644
index 000000000000..dddf070f8d20
--- /dev/null
+++ b/net-im/psi/psi-9999.ebuild
@@ -0,0 +1,215 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+LANGS="be bg ca cs de en eo es et fi fr hu it ja mk nl pl pt pt_BR ru sk sl sr@latin sv sw uk ur_PK vi zh_CN zh_TW"
+
+EGIT_REPO_URI="git://github.com/psi-im/psi.git"
+EGIT_HAS_SUBMODULES=1
+LANGS_REPO_URI="git://github.com/psi-plus/psi-plus-l10n.git"
+
+PSI_PLUS_URI="git://github.com/psi-plus/main.git"
+PSI_PLUS_RESOURCES_URI="git://github.com/psi-plus/resources.git"
+
+inherit eutils gnome2-utils qt4-r2 multilib git-2 subversion
+
+DESCRIPTION="Qt4 Jabber client, with Licq-like interface"
+HOMEPAGE="http://psi-im.org/"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS=""
+IUSE="crypt dbus debug doc enchant extras jingle iconsets spell ssl xscreensaver powersave
+plugins whiteboarding webkit"
+
+REQUIRED_USE="
+ iconsets? ( extras )
+ plugins? ( extras )
+ powersave? ( extras )
+ webkit? ( extras )
+"
+
+RDEPEND="
+ app-arch/unzip
+ >=app-crypt/qca-2.0.2:2[qt4(+)]
+ dev-qt/qtcore:4
+ dev-qt/qtgui:4
+ >=sys-libs/zlib-1.2.5.1-r2[minizip]
+ x11-libs/libX11
+ dbus? ( dev-qt/qtdbus:4 )
+ extras? ( webkit? ( dev-qt/qtwebkit:4 ) )
+ spell? (
+ enchant? ( >=app-text/enchant-1.3.0 )
+ !enchant? ( app-text/aspell )
+ )
+ whiteboarding? ( dev-qt/qtsvg:4 )
+ xscreensaver? ( x11-libs/libXScrnSaver )
+"
+DEPEND="${RDEPEND}
+ extras? (
+ ${SUBVERSION_DEPEND}
+ sys-devel/qconf
+ )
+ doc? ( app-doc/doxygen )
+ virtual/pkgconfig
+"
+PDEPEND="
+ crypt? ( app-crypt/qca:2[gpg] )
+ jingle? (
+ net-im/psimedia
+ app-crypt/qca:2[openssl]
+ )
+ ssl? ( app-crypt/qca:2[openssl] )
+"
+RESTRICT="test"
+
+pkg_setup() {
+ MY_PN=psi
+ if use extras; then
+ MY_PN=psi-plus
+ echo
+ ewarn "You're about to build heavily patched version of Psi called Psi+."
+ ewarn "It has really nice features but still is under heavy development."
+ ewarn "Take a look at homepage for more info: http://code.google.com/p/psi-dev"
+ ewarn "If you wish to disable some patches just put"
+ ewarn "MY_EPATCH_EXCLUDE=\"list of patches\""
+ ewarn "into /etc/portage/env/${CATEGORY}/${PN} file."
+ echo
+ ewarn "Note: some patches depend on other. So if you disabled some patch"
+ ewarn "and other started to fail to apply, you'll have to disable patches"
+ ewarn "that fail too."
+ echo
+
+ if use iconsets; then
+ echo
+ ewarn "Some artwork is from open source projects, but some is provided 'as-is'"
+ ewarn "and has not clear licensing."
+ ewarn "Possibly this build is not redistributable in some countries."
+ fi
+ fi
+}
+
+src_unpack() {
+ git-2_src_unpack
+ unset EGIT_HAS_SUBMODULES EGIT_NONBARE
+
+ # fetch translations
+ mkdir "${WORKDIR}/psi-l10n"
+ unset EGIT_MASTER EGIT_BRANCH EGIT_COMMIT
+ EGIT_REPO_URI="${LANGS_REPO_URI}" \
+ EGIT_SOURCEDIR="${WORKDIR}/psi-l10n" git-2_src_unpack
+
+ if use extras; then
+ EGIT_DIR="${EGIT_STORE_DIR}/psi-plus/main" \
+ EGIT_SOURCEDIR="${WORKDIR}/psi-plus" \
+ EGIT_REPO_URI="${PSI_PLUS_URI}" git-2_src_unpack
+ if use iconsets; then
+ EGIT_DIR="${EGIT_STORE_DIR}/psi-plus/resources" \
+ EGIT_SOURCEDIR="${WORKDIR}/resources" \
+ EGIT_REPO_URI="${PSI_PLUS_RESOURCES_URI}" git-2_src_unpack
+ fi
+ fi
+}
+
+src_prepare() {
+ if use extras; then
+ cp -a "${WORKDIR}/psi-plus/iconsets" "${S}" || die "failed to copy iconsets"
+ use iconsets && { cp -a "${WORKDIR}/resources/iconsets" "${S}" || \
+ die "failed to copy additional iconsets"; }
+ EPATCH_EXCLUDE="${MY_EPATCH_EXCLUDE} " \
+ EPATCH_SOURCE="${WORKDIR}/psi-plus/patches/" EPATCH_SUFFIX="diff" EPATCH_FORCE="yes" epatch
+
+ use powersave && epatch "${WORKDIR}/psi-plus/patches/dev/psi-reduce-power-consumption.patch"
+
+ sed -e "s/.xxx/.$(cd "${WORKDIR}/psi-plus"; echo $((`git describe --tags | \
+ cut -d - -f 2`+5000)))/" -i src/applicationinfo.cpp || die "sed failed"
+
+ qconf || die "Failed to create ./configure."
+ fi
+}
+
+src_configure() {
+ # unable to use econf because of non-standard configure script
+ # disable growl as it is a MacOS X extension only
+ local myconf="
+ --prefix="${EPREFIX}"/usr
+ --qtdir="${EPREFIX}"/usr
+ --disable-growl
+ --no-separate-debug-info
+ "
+ use dbus || myconf+=" --disable-qdbus"
+ use debug && myconf+=" --debug"
+ if use spell; then
+ use enchant && myconf+=" --disable-aspell" || myconf+=" --disable-enchant"
+ else
+ myconf+=" --disable-aspell --disable-enchant"
+ fi
+ use whiteboarding && myconf+=" --enable-whiteboarding"
+ use xscreensaver || myconf+=" --disable-xss"
+ if use extras; then
+ use plugins && myconf+=" --enable-plugins"
+ use webkit && myconf+=" --enable-webkit"
+ fi
+
+ einfo "./configure ${myconf}"
+ ./configure ${myconf} || die
+
+ eqmake4
+}
+
+src_compile() {
+ emake
+
+ if use doc; then
+ cd doc
+ mkdir -p api # 259632
+ make api_public || die "make api_public failed"
+ fi
+}
+
+src_install() {
+ emake INSTALL_ROOT="${D}" install
+
+ # this way the docs will be installed in the standard gentoo dir
+ rm -f "${ED}"/usr/share/${MY_PN}/{COPYING,README}
+ newdoc iconsets/roster/README README.roster
+ newdoc iconsets/system/README README.system
+ newdoc certs/README README.certs
+ dodoc README
+
+ if use extras && use plugins; then
+ insinto /usr/share/${MY_PN}/plugins
+ doins src/plugins/plugins.pri
+ doins src/plugins/psiplugin.pri
+ doins -r src/plugins/include
+ sed -i -e "s:target.path.*:target.path = /usr/$(get_libdir)/${MY_PN}/plugins:" \
+ "${ED}"/usr/share/${MY_PN}/plugins/psiplugin.pri \
+ || die "sed failed"
+ fi
+
+ use doc && dohtml -r doc/api
+
+ # install translations
+ cd "${WORKDIR}/psi-l10n/translations"
+ insinto /usr/share/${MY_PN}
+ for x in ${LANGS}; do
+ if use linguas_${x}; then
+ lrelease "${PN}_${x}.ts" || die "lrelease ${x} failed"
+ doins "${PN}_${x}.qm"
+ fi
+ done
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ readme.gentoo_pkg_postinst
+ gnome2_icon_cache_update
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+}