summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Huber <johu@gentoo.org>2016-12-23 21:41:30 +0100
committerJohannes Huber <johu@gentoo.org>2016-12-24 10:15:19 +0100
commita6257f7c9dc4385f03d25852117c84f1b89cf7bc (patch)
treea719ee9e956642e25d89c73408546c984471a06c /kde-frameworks
parentnet-dns/libidn2: Depend on sys-apps/help2man (bug #602970). (diff)
downloadgentoo-a6257f7c9dc4385f03d25852117c84f1b89cf7bc.tar.gz
gentoo-a6257f7c9dc4385f03d25852117c84f1b89cf7bc.tar.bz2
gentoo-a6257f7c9dc4385f03d25852117c84f1b89cf7bc.zip
kde-base/kdelibs -> kde-frameworks/kdelibs
Diffstat (limited to 'kde-frameworks')
-rw-r--r--kde-frameworks/kdelibs/Manifest2
-rw-r--r--kde-frameworks/kdelibs/files/dist/01_gentoo_set_xdg_menu_prefix-1.patch18
-rw-r--r--kde-frameworks/kdelibs/files/dist/02_gentoo_append_xdg_config_dirs-1.patch30
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.10.0-udisks.patch51
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.14.20-FindQt4.patch39
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.14.20-strigi-optional.patch24
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.14.22-webkit.patch85
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.14.5-fatalwarnings.patch16
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.14.5-mimetypes.patch27
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.3.80-kdeui_util_kkeyserver_mac.patch46
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.4.90-xslt.patch12
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.6.3-no_suid_kdeinit.patch19
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.8.1-norpath.patch18
-rw-r--r--kde-frameworks/kdelibs/files/kdelibs-4.9.3-werror.patch20
-rw-r--r--kde-frameworks/kdelibs/kdelibs-4.14.24.ebuild301
-rw-r--r--kde-frameworks/kdelibs/kdelibs-4.14.27.ebuild300
-rw-r--r--kde-frameworks/kdelibs/metadata.xml11
17 files changed, 1019 insertions, 0 deletions
diff --git a/kde-frameworks/kdelibs/Manifest b/kde-frameworks/kdelibs/Manifest
new file mode 100644
index 000000000000..d69eb2eb4fd7
--- /dev/null
+++ b/kde-frameworks/kdelibs/Manifest
@@ -0,0 +1,2 @@
+DIST kdelibs-4.14.24.tar.xz 11635840 SHA256 45e663e8739f131115eda69e5af95e895cce8161228d075d74a9a8cd390346ef SHA512 187737e30d05f324977cfc14aa375b49e15c322abb2b8f482382f9e6061bf7d18b97b957a7fcc1fb9184fa68cd3e1753d9633e14f32d799e3e5a78f283ff0894 WHIRLPOOL 2a4a67f792a2d88f2a4cfd49cafe2c611e79ba974a55d6d77e9688acf89be56817adfa6489017162afc42d7c30949df277b8974a2aaf59b2357a3b279a83b0a2
+DIST kdelibs-4.14.27.tar.xz 11641732 SHA256 b79fe7f8798fe6a3aade6eced396b40b5fbb638200604056a18b377ee76ecfb2 SHA512 52a76c6e5cb8366bf353a1eee8286f4165fcdf962ac0da5545a96e066bb513a9eedbbacd7ee6981d9034e08a84f795c68d26fa2f02774938ac1a4971a8a18427 WHIRLPOOL 4cfa7a6f9c7dd74c9e90e90c9950babd1cb966655b77093fbe6fc2a7172998c720c9b9fe29ac9f22e18f1577475668fa96c9b6142051a19ca20cb57324cc0692
diff --git a/kde-frameworks/kdelibs/files/dist/01_gentoo_set_xdg_menu_prefix-1.patch b/kde-frameworks/kdelibs/files/dist/01_gentoo_set_xdg_menu_prefix-1.patch
new file mode 100644
index 000000000000..c12c2aba9aeb
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/dist/01_gentoo_set_xdg_menu_prefix-1.patch
@@ -0,0 +1,18 @@
+Set XDG_MENU_PREFIX to kde-4- if not set. This fixes "empty-applications-menu" when running
+KDE4 applications outside of KDE4 environment.
+
+Index: kded/vfolder_menu.cpp
+===================================================================
+--- a/kded/vfolder_menu.cpp (revision 1014368)
++++ b/kded/vfolder_menu.cpp (working copy)
+@@ -770,7 +770,9 @@
+ QString result;
+
+ QString xdgMenuPrefix = QString::fromLocal8Bit(qgetenv("XDG_MENU_PREFIX"));
+- if (!xdgMenuPrefix.isEmpty())
++ if (xdgMenuPrefix.isEmpty())
++ xdgMenuPrefix = "kde-4-";
++
+ {
+ QFileInfo fileInfo(fileName);
+
diff --git a/kde-frameworks/kdelibs/files/dist/02_gentoo_append_xdg_config_dirs-1.patch b/kde-frameworks/kdelibs/files/dist/02_gentoo_append_xdg_config_dirs-1.patch
new file mode 100644
index 000000000000..074847ae9953
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/dist/02_gentoo_append_xdg_config_dirs-1.patch
@@ -0,0 +1,30 @@
+Set up XDG_CONFIG_DIRS lookup in order:
+1. custom XDG_CONFIG_DIRS from env
+2. kdeprefix xdg config dirs
+3. /etc/xdg
+
+Index: kdecore/kernel/kstandarddirs.cpp
+===================================================================
+--- a/kdecore/kernel/kstandarddirs.cpp (revision 1014759)
++++ b/kdecore/kernel/kstandarddirs.cpp (working copy)
+@@ -1664,16 +1664,13 @@
+ {
+ tokenize(xdgdirList, xdgdirs, QString(QChar(KPATH_SEPARATOR)));
+ }
+- else
+- {
+- xdgdirList.clear();
+- xdgdirList.append(QString::fromLatin1("/etc/xdg"));
++
+ #ifdef Q_WS_WIN
+- xdgdirList.append(installPath("kdedir") + QString::fromLatin1("etc/xdg"));
++ xdgdirList.append(installPath("kdedir") + QString::fromLatin1("etc/xdg"));
+ #else
+- xdgdirList.append(QFile::decodeName(KDESYSCONFDIR "/xdg"));
++ xdgdirList.append(QFile::decodeName(KDESYSCONFDIR "/xdg"));
+ #endif
+- }
++ xdgdirList.append(QString::fromLatin1("/etc/xdg"));
+
+ QString localXdgDir = readEnvPath("XDG_CONFIG_HOME");
+ if (!localXdgDir.isEmpty())
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.10.0-udisks.patch b/kde-frameworks/kdelibs/files/kdelibs-4.10.0-udisks.patch
new file mode 100644
index 000000000000..63e9b308838b
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.10.0-udisks.patch
@@ -0,0 +1,51 @@
+udisks1 is deprecated and going away, so removing this clause
+will permit us to build without udisks at all.
+
+--- a/solid/solid/CMakeLists.txt
++++ b/solid/solid/CMakeLists.txt
+@@ -283,20 +283,6 @@
+ backends/udisks2/udisksgenericinterface.cpp
+ backends/udisks2/dbus/manager.cpp
+ )
+- else ( WITH_SOLID_UDISKS2 )
+- message(STATUS "Building Solid UDisks backend." )
+- set(solid_LIB_SRCS ${solid_LIB_SRCS}
+- backends/udisks/udisksmanager.cpp
+- backends/udisks/udisksdevice.cpp
+- backends/udisks/udisksblock.cpp
+- backends/udisks/udisksstoragevolume.cpp
+- backends/udisks/udisksdeviceinterface.cpp
+- backends/udisks/udisksopticaldisc.cpp
+- backends/udisks/udisksopticaldrive.cpp
+- backends/udisks/udisksstoragedrive.cpp
+- backends/udisks/udisksstorageaccess.cpp
+- backends/udisks/udisksgenericinterface.cpp
+- )
+ endif ( WITH_SOLID_UDISKS2 )
+ endif (CMAKE_SYSTEM_NAME MATCHES Linux)
+
+--- a/solid/solid/managerbase.cpp
++++ b/solid/solid/managerbase.cpp
+@@ -33,8 +33,6 @@
+ #include "backends/hal/halmanager.h"
+ #if defined (WITH_SOLID_UDISKS2)
+ #include "backends/udisks2/udisksmanager.h"
+-#else
+-#include "backends/udisks/udisksmanager.h"
+ #endif
+ #include "backends/upower/upowermanager.h"
+
+@@ -88,11 +86,9 @@
+ m_backends << new Solid::Backends::UDev::UDevManager(0);
+ # endif
+ # if defined(WITH_SOLID_UDISKS2)
+- m_backends << new Solid::Backends::UDisks2::Manager(0)
+-# else
+- m_backends << new Solid::Backends::UDisks::UDisksManager(0)
++ m_backends << new Solid::Backends::UDisks2::Manager(0);
+ # endif
+- << new Solid::Backends::UPower::UPowerManager(0)
++ m_backends << new Solid::Backends::UPower::UPowerManager(0)
+ << new Solid::Backends::Fstab::FstabManager(0);
+ }
+ # endif
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.14.20-FindQt4.patch b/kde-frameworks/kdelibs/files/kdelibs-4.14.20-FindQt4.patch
new file mode 100644
index 000000000000..2325fb11c693
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.14.20-FindQt4.patch
@@ -0,0 +1,39 @@
+Ensure that the correct version of Qt is always used.
+
+With the introduction qt-4.8.6, Qt binaries were moved from /usr/bin to
+/usr/$(get_libdir)/qt4/bin, leaving behind in their place symlinks to qtchooser.
+
+There is no guarantee to which version of Qt these symlinks might point, so it
+is necessary to find the correct version explicitly.
+
+Once qmake is found, it is queried for the correct location of all other items.
+
+Gentoo-bug: 562746
+Gentoo-bug: 583506
+
+--- a/cmake/modules/FindQt4.cmake
++++ b/cmake/modules/FindQt4.cmake
+@@ -446,6 +446,15 @@ GET_FILENAME_COMPONENT(qt_install_version "[HKEY_CURRENT_USER\\Software\\trollte
+ # check for qmake
+ # Debian uses qmake-qt4
+ # macports' Qt uses qmake-mac
++if(CMAKE_BUILD_TYPE STREQUAL Gentoo)
++ find_program(QT_QMAKE_EXECUTABLE NAMES qmake
++ PATHS
++ $ENV{EPREFIX}/usr/${CMAKE_INSTALL_LIBDIR}/qt4/bin
++ $ENV{EPREFIX}/usr/bin
++ NO_DEFAULT_PATH
++ DOC "The qmake executable for the Qt installation to use"
++ )
++else()
+ FIND_PROGRAM(QT_QMAKE_EXECUTABLE NAMES qmake qmake4 qmake-qt4 qmake-mac PATHS
+ "[HKEY_CURRENT_USER\\Software\\Trolltech\\Qt3Versions\\4.0.0;InstallDir]/bin"
+ "[HKEY_CURRENT_USER\\Software\\Trolltech\\Versions\\4.0.0;InstallDir]/bin"
+@@ -453,6 +462,7 @@ FIND_PROGRAM(QT_QMAKE_EXECUTABLE NAMES qmake qmake4 qmake-qt4 qmake-mac PATHS
+ $ENV{QTDIR}/bin
+ DOC "The qmake executable for the Qt installation to use"
+ )
++endif()
+
+ IF (QT_QMAKE_EXECUTABLE)
+
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.14.20-strigi-optional.patch b/kde-frameworks/kdelibs/files/kdelibs-4.14.20-strigi-optional.patch
new file mode 100644
index 000000000000..c9e96551cfbf
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.14.20-strigi-optional.patch
@@ -0,0 +1,24 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index e7b2bea..87147b5 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -82,17 +82,10 @@ set_package_properties(ZLIB PROPERTIES DESCRIPTION "Support for gzip compressed
+ )
+
+ find_package(Strigi 0.6.3)
+-if (WIN32)
+- set (STRIGI_TYPE "OPTIONAL")
+- set (STRIGI_EXTRA_TEXT "")
+-else (WIN32)
+- set (STRIGI_TYPE "REQUIRED")
+- set (STRIGI_EXTRA_TEXT "Required by some critical kioslaves")
+-endif (WIN32)
+ set_package_properties(Strigi PROPERTIES DESCRIPTION "Desktop indexing and search support"
+ URL "http://strigi.sourceforge.net"
+- TYPE ${STRIGI_TYPE}
+- PURPOSE ${STRIGI_EXTRA_TEXT}
++ TYPE OPTIONAL
++ PURPOSE "Required by some kioslaves for metadata support"
+ )
+
+ find_package(LibAttica 0.4.2)
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.14.22-webkit.patch b/kde-frameworks/kdelibs/files/kdelibs-4.14.22-webkit.patch
new file mode 100644
index 000000000000..dcbb565cedc6
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.14.22-webkit.patch
@@ -0,0 +1,85 @@
+--- a/CMakeLists.txt 2016-07-06 12:18:35.000000000 +0200
++++ b/CMakeLists.txt 2016-07-21 21:40:26.080328514 +0200
+@@ -45,6 +45,9 @@
+ ############### Give the user the option to build the deprecated WMI solid backend instead of the new win backend ###############
+ option(WITH_SOLID_WMI "Enables the deprecated WMI backend on Windows")
+
++############### Give the user the option to build without qtwebkit dependency ###############
++option(WITH_KDEWEBKIT "Enables the deprecated kdewebkit and kdewebkit-widgets" "ON")
++
+ ############### Load the CTest options ###############
+ # CTestCustom.cmake has to be in the CTEST_BINARY_DIR.
+ # in the KDE build system, this is the same as CMAKE_BINARY_DIR.
+@@ -363,7 +366,9 @@
+ add_subdirectory( plasma )
+ endif(NOT WINCE)
+ add_subdirectory( kunitconversion )
++if(WITH_KDEWEBKIT)
+ add_subdirectory( kdewebkit )
++endif(WITH_KDEWEBKIT)
+ add_subdirectory( includes )
+
+ add_subdirectory( experimental )
+--- a/kdewidgets/CMakeLists.txt 2016-07-06 12:18:35.000000000 +0200
++++ b/kdewidgets/CMakeLists.txt 2016-07-21 21:39:54.031052674 +0200
+@@ -90,6 +90,7 @@
+
+
+ # kdewebkit widgets
++ if(WITH_KDEWEBKIT)
+ include_directories(
+ ${CMAKE_SOURCE_DIR}/kdewebkit
+ )
+@@ -121,7 +122,7 @@
+ endif(NOT WIN32)
+
+ install(TARGETS kdewebkitwidgets DESTINATION ${PLUGIN_INSTALL_DIR}/plugins/designer )
+-
++ endif(WITH_KDEWEBKIT)
+
+ if (QT_QT3SUPPORT_FOUND)
+
+--- a/plasma/CMakeLists.txt 2016-07-22 01:26:52.992198945 +0200
++++ b/plasma/CMakeLists.txt 2016-07-22 01:28:10.487904045 +0200
+@@ -10,6 +10,10 @@
+ set(PLASMA_NO_GLOBAL_SHORTCUTS TRUE)
+ endif(KDE_PLATFORM_FEATURE_BINARY_COMPATIBLE_FEATURE_REDUCTION)
+
++if(NOT WITH_KDEWEBKIT)
++ set(PLASMA_NO_KDEWEBKIT TRUE)
++endif(NOT WITH_KDEWEBKIT)
++
+ set(PLASMA_NO_PACKAGEKIT TRUE)
+
+ include_directories(${CMAKE_CURRENT_SOURCE_DIR}
+@@ -121,7 +125,6 @@
+ framesvg.cpp
+ plasma.cpp
+ popupapplet.cpp
+- private/animablegraphicswebview.cpp
+ private/applethandle.cpp
+ private/associatedapplicationmanager.cpp
+ private/componentinstaller.cpp
+@@ -211,7 +214,6 @@
+ widgets/textbrowser.cpp
+ widgets/treeview.cpp
+ widgets/textedit.cpp
+- widgets/webview.cpp
+
+ #Temporary QtJolie branch
+ private/qtjolie-branch/qtjolie/abstractadaptor.cpp
+@@ -245,6 +247,14 @@
+ )
+ endif(NOT KDE_NO_DEPRECATED)
+
++if(NOT PLASMA_NO_KDEWEBKIT)
++ set(plasma_LIB_SRCS
++ ${plasma_LIB_SRCS}
++ private/animablegraphicswebview.cpp
++ widgets/webview.cpp
++ )
++endif(NOT PLASMA_NO_KDEWEBKIT)
++
+ kde4_add_kcfg_files(plasma_LIB_SRCS data/kconfigxt/libplasma-theme-global.kcfgc)
+
+ kde4_add_ui_files(plasma_LIB_SRCS
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.14.5-fatalwarnings.patch b/kde-frameworks/kdelibs/files/kdelibs-4.14.5-fatalwarnings.patch
new file mode 100644
index 000000000000..3f571d63a03d
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.14.5-fatalwarnings.patch
@@ -0,0 +1,16 @@
+Avoid build failure due to harmless warnings on some platforms (eg. ARM) being
+forced fatal.
+
+--- a/cmake/modules/FindKDE4Internal.cmake
++++ b/cmake/modules/FindKDE4Internal.cmake
+@@ -1100,8 +1100,8 @@
+ if (CMAKE_SYSTEM_NAME MATCHES Linux OR CMAKE_SYSTEM_NAME STREQUAL GNU)
+ if (CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+ set ( _KDE4_PLATFORM_DEFINITIONS -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_GNU_SOURCE)
+- set ( CMAKE_SHARED_LINKER_FLAGS "-Wl,--fatal-warnings -Wl,--no-undefined -lc ${CMAKE_SHARED_LINKER_FLAGS}")
+- set ( CMAKE_MODULE_LINKER_FLAGS "-Wl,--fatal-warnings -Wl,--no-undefined -lc ${CMAKE_MODULE_LINKER_FLAGS}")
++ set ( CMAKE_SHARED_LINKER_FLAGS "-Wl,--no-undefined -lc ${CMAKE_SHARED_LINKER_FLAGS}")
++ set ( CMAKE_MODULE_LINKER_FLAGS "-Wl,--no-undefined -lc ${CMAKE_MODULE_LINKER_FLAGS}")
+
+ set ( CMAKE_SHARED_LINKER_FLAGS "-Wl,--enable-new-dtags ${CMAKE_SHARED_LINKER_FLAGS}")
+ set ( CMAKE_MODULE_LINKER_FLAGS "-Wl,--enable-new-dtags ${CMAKE_MODULE_LINKER_FLAGS}")
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.14.5-mimetypes.patch b/kde-frameworks/kdelibs/files/kdelibs-4.14.5-mimetypes.patch
new file mode 100644
index 000000000000..38cac84f6201
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.14.5-mimetypes.patch
@@ -0,0 +1,27 @@
+Remove fake MIME types that cause warnings.
+
+The offending MIME types are commented out rather than
+physically removed because doing so would cause the patch
+to be too large.
+
+--- a/mimetypes/kde.xml
++++ b/mimetypes/kde.xml
+@@ -1784,7 +1784,8 @@
+ <glob pattern="*.abc"/>
+ </mime-type>
+
+- <!-- all/ fake mime types -->
++ <!--
++ all/ fake mime types
+ <mime-type type="all/all">
+ <comment>all files and folders</comment>
+ <comment xml:lang="ar">كل الملفات و المجلدات</comment>
+@@ -1901,7 +1902,7 @@
+ <comment xml:lang="zh_CN">全部文件</comment>
+ <comment xml:lang="zh_TW">所有檔案</comment>
+ </mime-type>
+-
++ -->
+ <mime-type type="application/vnd.kde.fontspackage">
+ <sub-class-of type="application/zip"/>
+ <comment>fonts package</comment>
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.3.80-kdeui_util_kkeyserver_mac.patch b/kde-frameworks/kdelibs/files/kdelibs-4.3.80-kdeui_util_kkeyserver_mac.patch
new file mode 100644
index 000000000000..006ca00a4586
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.3.80-kdeui_util_kkeyserver_mac.patch
@@ -0,0 +1,46 @@
+diff -purN kdelibs-4.3.80.orig/kdeui/util/kkeyserver_mac.cpp kdelibs-4.3.80/kdeui/util/kkeyserver_mac.cpp
+--- a/kdelibs-4.3.80.orig/kdeui/util/kkeyserver_mac.cpp 2009-12-14 17:05:26.284881642 -0500
++++ b/kdelibs-4.3.80/kdeui/util/kkeyserver_mac.cpp 2009-12-14 17:11:23.393094384 -0500
+@@ -68,7 +68,7 @@ namespace KKeyServer {
+ #ifdef QT_MAC_USE_COCOA
+ static TISInputSourceRef lastLayout = 0;
+ #else
+- static KeyboardLayoutRef lastLayout = NULL;
++ static TISInputSourceRef lastLayout = NULL;
+ #endif
+
+ void updateScancodes() {
+@@ -125,16 +125,27 @@ namespace KKeyServer {
+ #endif
+ lastLayout = layout;
+ scancodes.clear();
+- void *kchr;
+- if (KLGetKeyboardLayoutProperty(layout, kKLKCHRData, const_cast<const void**>(&kchr)) != noErr) {
++ UCKeyboardLayout *uchr = (UCKeyboardLayout *)TISGetInputSourceProperty(layout, kTISPropertyUnicodeKeyLayoutData);
++ if (uchr == NULL) {
+ kWarning() << "Couldn't load active keyboard layout";
+ } else {
+ for (int i = 0; i < 128; i++) {
+ UInt32 tmpState = 0;
+- UInt32 chr = KeyTranslate(kchr, i, &tmpState);
+- if (chr && chr != kFunctionKeyCharCode) {
+- scancodes.insert(chr, i);
+- }
++ UInt32 deadKeyState = 0;
++ UInt32 flags = 0;
++ UniCharCount maxStringLength = 255;
++ UniCharCount actualStringLength = 0;
++ UniChar unicodeString[maxStringLength];
++
++ UCKeyTranslate(uchr, i, kUCKeyActionDown,
++ flags, LMGetKbdType(),
++ 1, &deadKeyState, maxStringLength, &actualStringLength, unicodeString);
++ fprintf(stderr, "Got key: %s\n", unicodeString);
++ fflush(stderr);
++ //UInt32 chr = KeyTranslate(kchr, i, &tmpState);
++ //if (chr && chr != kFunctionKeyCharCode) {
++ // scancodes.insert(chr, i);
++ //}
+ }
+ }
+ }
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.4.90-xslt.patch b/kde-frameworks/kdelibs/files/kdelibs-4.4.90-xslt.patch
new file mode 100644
index 000000000000..0d25ada337b0
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.4.90-xslt.patch
@@ -0,0 +1,12 @@
+diff -r -u kdelibs-4.4.90.orig/kdoctools/customization/htdig_index.xsl kdelibs-4.4.90/kdoctools/customization/htdig_index.xsl
+--- kdelibs-4.4.90.orig/kdoctools/customization/htdig_index.xsl 2008-05-21 13:07:13.000000000 +0200
++++ kdelibs-4.4.90/kdoctools/customization/htdig_index.xsl 2010-07-08 23:32:28.184204481 +0200
+@@ -35,7 +35,7 @@
+ </entry>
+ </xsl:template>
+
+-<xsl:template match="sect*/title|emphasis">
++<xsl:template match="*[starts-with(local-name(), 'sect')]/title|emphasis">
+ <entry header="2">
+ <xsl:apply-templates/>
+ </entry>
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.6.3-no_suid_kdeinit.patch b/kde-frameworks/kdelibs/files/kdelibs-4.6.3-no_suid_kdeinit.patch
new file mode 100644
index 000000000000..4b34f62c2be4
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.6.3-no_suid_kdeinit.patch
@@ -0,0 +1,19 @@
+diff -urN kdelibs-4.6.3.old/kinit/CMakeLists.txt kdelibs-4.6.3/kinit/CMakeLists.txt
+--- kdelibs-4.6.3.old/kinit/CMakeLists.txt 2011-05-02 00:19:10.000000000 +0200
++++ kdelibs-4.6.3/kinit/CMakeLists.txt 2011-05-02 00:20:32.000000000 +0200
+@@ -170,15 +170,6 @@
+ install(TARGETS start_kdeinit_wrapper DESTINATION ${LIBEXEC_INSTALL_DIR})
+ endif (NOT WIN32)
+
+-if (CMAKE_SYSTEM_NAME MATCHES Linux)
+- MESSAGE(STATUS "Using setuid root kdeinit wrapper in order to protect it from bad Linux OOM-killer")
+- set(KDEINIT_OOM_PROTECT 1)
+- install(CODE "
+- set(START_KDEINIT_PATH \"\$ENV{DESTDIR}${LIBEXEC_INSTALL_DIR}/start_kdeinit\")
+- EXECUTE_PROCESS(COMMAND sh -c \"chown 0 '\${START_KDEINIT_PATH}' && chmod u+s '\${START_KDEINIT_PATH}'\")
+- ")
+-endif (CMAKE_SYSTEM_NAME MATCHES Linux)
+-
+ ########### install files ###############
+
+ install( FILES ${CMAKE_CURRENT_BINARY_DIR}/org.kde.KLauncher.xml DESTINATION ${DBUS_INTERFACES_INSTALL_DIR} )
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.8.1-norpath.patch b/kde-frameworks/kdelibs/files/kdelibs-4.8.1-norpath.patch
new file mode 100644
index 000000000000..83d5576ac023
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.8.1-norpath.patch
@@ -0,0 +1,18 @@
+diff -ruN kdelibs-4.8.1.orig/cmake/modules/FindKDE4Internal.cmake kdelibs-4.8.1/cmake/modules/FindKDE4Internal.cmake
+--- kdelibs-4.8.1.orig/cmake/modules/FindKDE4Internal.cmake 2012-02-29 22:55:52.000000000 +0100
++++ kdelibs-4.8.1/cmake/modules/FindKDE4Internal.cmake 2012-03-24 17:18:59.452942648 +0100
+@@ -1045,7 +1045,13 @@
+
+ set(CMAKE_SKIP_BUILD_RPATH FALSE)
+ set(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE)
+- set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
++
++ # the RPATH to be used when installing
++ SET(CMAKE_INSTALL_RPATH "")
++
++ # don't add the automatically determined parts of the RPATH
++ # which point to directories outside the build tree to the install RPATH
++ SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE)
+ endif (APPLE)
+ endif (UNIX)
+
diff --git a/kde-frameworks/kdelibs/files/kdelibs-4.9.3-werror.patch b/kde-frameworks/kdelibs/files/kdelibs-4.9.3-werror.patch
new file mode 100644
index 000000000000..b094d12f7227
--- /dev/null
+++ b/kde-frameworks/kdelibs/files/kdelibs-4.9.3-werror.patch
@@ -0,0 +1,20 @@
+--- a/cmake/modules/FindKDE4Internal.cmake
++++ b/cmake/modules/FindKDE4Internal.cmake
+@@ -1204,7 +1204,7 @@
+ set(CMAKE_C_FLAGS_DEBUGFULL "-g3 -fno-inline")
+ set(CMAKE_C_FLAGS_PROFILE "-g3 -fno-inline -ftest-coverage -fprofile-arcs")
+
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-long-long -std=iso9899:1990 -Wundef -Wcast-align -Werror-implicit-function-declaration -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
++ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-long-long -std=iso9899:1990 -Wundef -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
+ # As of Qt 4.6.x we need to override the new exception macros if we want compile with -fno-exceptions
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -Wundef -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -Wformat-security -fno-exceptions -DQT_NO_EXCEPTIONS -fno-check-new -fno-common")
+
+@@ -1295,7 +1295,7 @@
+ endif(NOT _compile_result)
+
+ if (GCC_IS_NEWER_THAN_4_2)
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=return-type -fvisibility-inlines-hidden")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility-inlines-hidden")
+ endif (GCC_IS_NEWER_THAN_4_2)
+ else (__KDE_HAVE_GCC_VISIBILITY AND GCC_IS_NEWER_THAN_4_1 AND NOT _GCC_COMPILED_WITH_BAD_ALLOCATOR AND NOT WIN32)
+ set (__KDE_HAVE_GCC_VISIBILITY 0)
diff --git a/kde-frameworks/kdelibs/kdelibs-4.14.24.ebuild b/kde-frameworks/kdelibs/kdelibs-4.14.24.ebuild
new file mode 100644
index 000000000000..9db907a1549a
--- /dev/null
+++ b/kde-frameworks/kdelibs/kdelibs-4.14.24.ebuild
@@ -0,0 +1,301 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+CMAKE_MIN_VERSION="3.3.1-r1"
+CPPUNIT_REQUIRED="optional"
+DECLARATIVE_REQUIRED="always"
+KDE_HANDBOOK="optional"
+OPENGL_REQUIRED="optional"
+WEBKIT_REQUIRED="optional"
+inherit kde4-base fdo-mime multilib toolchain-funcs flag-o-matic
+
+APPS_VERSION="16.08.1" # Don't forget to bump this
+
+DESCRIPTION="KDE libraries needed by all KDE programs"
+[[ ${KDE_BUILD_TYPE} != live ]] && \
+SRC_URI="mirror://kde/stable/applications/${APPS_VERSION}/src/${P}.tar.xz"
+
+KEYWORDS="amd64 ~arm ~ppc ~ppc64 x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux"
+LICENSE="LGPL-2.1"
+IUSE="cpu_flags_x86_3dnow acl altivec +bzip2 +crypt debug doc fam jpeg2k
+kerberos libressl lzma cpu_flags_x86_mmx nls openexr +policykit spell
+cpu_flags_x86_sse cpu_flags_x86_sse2 ssl +udev +udisks +upower zeroconf"
+
+REQUIRED_USE="
+ udisks? ( udev )
+ upower? ( udev )
+"
+
+# needs the kate regression testsuite from svn
+RESTRICT="test"
+
+COMMONDEPEND="
+ app-text/docbook-xml-dtd:4.2
+ app-text/docbook-xsl-stylesheets
+ >=dev-libs/libattica-0.4.2
+ dev-libs/libdbusmenu-qt[qt4]
+ dev-libs/libpcre[unicode]
+ dev-libs/libxml2
+ dev-libs/libxslt
+ media-libs/fontconfig
+ media-libs/freetype:2
+ media-libs/giflib:=
+ media-libs/libpng:0=
+ media-libs/phonon[qt4]
+ sys-libs/zlib
+ virtual/jpeg:0
+ x11-misc/shared-mime-info
+ acl? ( virtual/acl )
+ !aqua? (
+ x11-libs/libICE
+ x11-libs/libSM
+ x11-libs/libX11
+ x11-libs/libXau
+ x11-libs/libXcursor
+ x11-libs/libXdmcp
+ x11-libs/libXext
+ x11-libs/libXfixes
+ x11-libs/libXft
+ x11-libs/libXpm
+ x11-libs/libXrender
+ x11-libs/libXScrnSaver
+ x11-libs/libXtst
+ !kernel_SunOS? (
+ || (
+ sys-libs/libutempter
+ >=sys-freebsd/freebsd-lib-9.0
+ )
+ )
+ )
+ bzip2? ( app-arch/bzip2 )
+ crypt? ( app-crypt/qca:2[qt4] )
+ fam? ( virtual/fam )
+ jpeg2k? ( media-libs/jasper:= )
+ kerberos? ( virtual/krb5 )
+ openexr? (
+ media-libs/openexr:=
+ media-libs/ilmbase:=
+ )
+ policykit? ( sys-auth/polkit-qt[qt4] )
+ spell? ( app-text/enchant )
+ ssl? (
+ libressl? ( dev-libs/libressl:0= )
+ !libressl? ( dev-libs/openssl:0= )
+ )
+ udev? ( virtual/udev )
+ zeroconf? ( net-dns/avahi[mdnsresponder-compat] )
+"
+DEPEND="${COMMONDEPEND}
+ doc? ( app-doc/doxygen )
+ nls? ( virtual/libintl )
+"
+RDEPEND="${COMMONDEPEND}
+ !dev-qt/qtphonon
+ >=app-crypt/gnupg-2.0.11
+ app-misc/ca-certificates
+ kde-frameworks/kdelibs-env:4
+ sys-apps/dbus[X]
+ !aqua? (
+ udisks? ( sys-fs/udisks:2 )
+ x11-apps/iceauth
+ x11-apps/rgb
+ x11-misc/xdg-utils
+ upower? ( || ( >=sys-power/upower-0.9.23 sys-power/upower-pm-utils ) )
+ )
+ udev? ( app-misc/media-player-info )
+"
+PDEPEND="
+ $(add_kdeapps_dep katepart '' 4.14.3)
+ || (
+ $(add_kdeapps_dep kfmclient '' 4.14.3)
+ x11-misc/xdg-utils
+ )
+ handbook? ( kde-apps/khelpcenter:* )
+ policykit? ( || (
+ >=sys-auth/polkit-kde-agent-0.99
+ kde-plasma/polkit-kde-agent
+ ) )
+"
+
+PATCHES=(
+ "${FILESDIR}/dist/01_gentoo_set_xdg_menu_prefix-1.patch"
+ "${FILESDIR}/dist/02_gentoo_append_xdg_config_dirs-1.patch"
+ "${FILESDIR}/${PN}-4.14.5-fatalwarnings.patch"
+ "${FILESDIR}/${PN}-4.14.5-mimetypes.patch"
+ "${FILESDIR}/${PN}-4.4.90-xslt.patch"
+ "${FILESDIR}/${PN}-4.6.3-no_suid_kdeinit.patch"
+ "${FILESDIR}/${PN}-4.8.1-norpath.patch"
+ "${FILESDIR}/${PN}-4.9.3-werror.patch"
+ "${FILESDIR}/${PN}-4.10.0-udisks.patch"
+ "${FILESDIR}/${PN}-4.14.20-FindQt4.patch"
+ "${FILESDIR}/${PN}-4.14.20-strigi-optional.patch"
+ "${FILESDIR}/${PN}-4.14.22-webkit.patch"
+)
+
+pkg_pretend() {
+ if [[ ${MERGE_TYPE} != binary ]] && tc-is-gcc; then
+ [[ $(gcc-major-version) -lt 4 ]] || \
+ ( [[ $(gcc-major-version) -eq 4 && $(gcc-minor-version) -le 3 ]] ) \
+ && die "Sorry, but gcc-4.3 and earlier won't work for KDE SC 4.6 (see bug #354837)."
+ fi
+}
+
+src_prepare() {
+ kde4-base_src_prepare
+
+ # Rename applications.menu (needs 01_gentoo_set_xdg_menu_prefix-1.patch to work)
+ sed -e 's|FILES[[:space:]]applications.menu|FILES applications.menu RENAME kde-4-applications.menu|g' \
+ -i kded/CMakeLists.txt || die "Sed on CMakeLists.txt for applications.menu failed."
+
+ if use aqua; then
+ sed -i -e \
+ "s:BUNDLE_INSTALL_DIR \"/Applications:BUNDLE_INSTALL_DIR \"${EPREFIX}/${APP_BUNDLE_DIR}:g" \
+ cmake/modules/FindKDE4Internal.cmake || die "failed to sed FindKDE4Internal.cmake"
+
+ #if [[ ${CHOST} == *-darwin8 ]]; then
+ sed -i -e \
+ "s:set(_add_executable_param MACOSX_BUNDLE):remove(_add_executable_param MACOSX_BUNDLE):g" \
+ cmake/modules/KDE4Macros.cmake || die "failed to sed KDE4Macros.cmake"
+ #fi
+
+ # solid/solid/backends/iokit doesn't properly link, so disable it.
+ sed -e "s|\(APPLE\)|(FALSE)|g" -i solid/solid/CMakeLists.txt \
+ || die "disabling solid/solid/backends/iokit failed"
+ sed -e "s|m_backend = .*Backends::IOKit.*;|m_backend = 0;|g" -i solid/solid/managerbase.cpp \
+ || die "disabling solid/solid/backends/iokit failed"
+
+ # There's no fdatasync on OSX and the check fails to detect that.
+ sed -e "/HAVE_FDATASYNC/ d" -i config.h.cmake \
+ || die "disabling fdatasync failed"
+
+ # Fix nameser include to nameser8_compat
+ sed -e "s|nameser8_compat.h|nameser_compat.h|g" -i kio/misc/kpac/discovery.cpp \
+ || die "fixing nameser include failed"
+ append-flags -DHAVE_ARPA_NAMESER8_COMPAT_H=1
+
+ # Try to fix kkeyserver_mac
+ epatch "${FILESDIR}"/${PN}-4.3.80-kdeui_util_kkeyserver_mac.patch
+ fi
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DWITH_HSPELL=OFF
+ -DWITH_ASPELL=OFF
+ -DKDE_DEFAULT_HOME=.kde4
+ -DKAUTH_BACKEND=POLKITQT-1
+ -DWITH_Soprano=OFF
+ -DWITH_SharedDesktopOntologies=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_Strigi=ON
+ -DBUILD_doc=$(usex handbook)
+ -DHAVE_X86_3DNOW=$(usex cpu_flags_x86_3dnow)
+ -DHAVE_PPC_ALTIVEC=$(usex altivec)
+ -DHAVE_X86_MMX=$(usex cpu_flags_x86_mmx)
+ -DHAVE_X86_SSE=$(usex cpu_flags_x86_sse)
+ -DHAVE_X86_SSE2=$(usex cpu_flags_x86_sse2)
+ -DWITH_ACL=$(usex acl)
+ -DWITH_BZip2=$(usex bzip2)
+ -DWITH_QCA2=$(usex crypt)
+ -DWITH_FAM=$(usex fam)
+ -DWITH_Jasper=$(usex jpeg2k)
+ -DWITH_GSSAPI=$(usex kerberos)
+ -DWITH_LibLZMA=$(usex lzma)
+ -DWITH_Libintl=$(usex nls)
+ -DWITH_OpenEXR=$(usex openexr)
+ -DWITH_OpenGL=$(usex opengl)
+ -DWITH_PolkitQt-1=$(usex policykit)
+ -DWITH_ENCHANT=$(usex spell)
+ -DWITH_OpenSSL=$(usex ssl)
+ -DWITH_UDev=$(usex udev)
+ -DWITH_SOLID_UDISKS2=$(usex udisks)
+ -DWITH_Avahi=$(usex zeroconf)
+ -DWITH_KDEWEBKIT=$(usex webkit)
+ )
+
+ use zeroconf || mycmakeargs+=( -DWITH_DNSSD=OFF )
+
+ kde4-base_src_configure
+}
+
+src_compile() {
+ kde4-base_src_compile
+
+ # The building of apidox is not managed anymore by the build system
+ if use doc; then
+ einfo "Building API documentation"
+ cd "${S}"/doc/api/
+ ./doxygen.sh "${S}" || die "APIDOX generation failed"
+ fi
+}
+
+src_install() {
+ kde4-base_src_install
+
+ # use system certificates
+ rm -f "${ED}"/usr/share/apps/kssl/ca-bundle.crt || die
+ dosym /etc/ssl/certs/ca-certificates.crt /usr/share/apps/kssl/ca-bundle.crt
+
+ if use doc; then
+ einfo "Installing API documentation. This could take a bit of time."
+ cd "${S}"/doc/api/
+ docinto /HTML/en/kdelibs-apidox
+ dohtml -r ${P}-apidocs/*
+ fi
+
+ if use aqua; then
+ einfo "fixing ${PN} plugins"
+
+ local _PV=${PV:0:3}.0
+ local _dir=${EPREFIX}/usr/$(get_libdir)/kde4/plugins/script
+
+ install_name_tool -id \
+ "${_dir}/libkrossqtsplugin.${_PV}.dylib" \
+ "${D}/${_dir}/libkrossqtsplugin.${_PV}.dylib" \
+ || die "failed fixing libkrossqtsplugin.${_PV}.dylib"
+
+ einfo "fixing ${PN} cmake detection files"
+ #sed -i -e \
+ # "s:if (HAVE_XKB):if (HAVE_XKB AND NOT APPLE):g" \
+ echo -e "set(XKB_FOUND FALSE)\nset(HAVE_XKB FALSE)" > \
+ "${ED}"/usr/share/apps/cmake/modules/FindXKB.cmake \
+ || die "failed fixing FindXKB.cmake"
+ fi
+
+ einfo Installing environment file.
+ # Since 44qt4 is sourced earlier QT_PLUGIN_PATH is defined.
+ echo "COLON_SEPARATED=QT_PLUGIN_PATH" > "${T}/77kde"
+ echo "QT_PLUGIN_PATH=${EPREFIX}/usr/$(get_libdir)/kde4/plugins" >> "${T}/77kde"
+ doenvd "${T}/77kde"
+}
+
+pkg_postinst() {
+ fdo-mime_mime_database_update
+
+ if use zeroconf; then
+ echo
+ elog "To make zeroconf support available in KDE make sure that the avahi daemon"
+ elog "is running."
+ echo
+ einfo "If you also want to use zeroconf for hostname resolution, emerge sys-auth/nss-mdns"
+ einfo "and enable multicast dns lookups by editing the 'hosts:' line in /etc/nsswitch.conf"
+ einfo "to include 'mdns', e.g.:"
+ einfo " hosts: files mdns dns"
+ echo
+ fi
+
+ kde4-base_pkg_postinst
+}
+
+pkg_prerm() {
+ # Remove ksycoca4 global database
+ rm -f "${EROOT}${PREFIX}"/share/kde4/services/ksycoca4
+}
+
+pkg_postrm() {
+ fdo-mime_mime_database_update
+
+ kde4-base_pkg_postrm
+}
diff --git a/kde-frameworks/kdelibs/kdelibs-4.14.27.ebuild b/kde-frameworks/kdelibs/kdelibs-4.14.27.ebuild
new file mode 100644
index 000000000000..4c221243ab64
--- /dev/null
+++ b/kde-frameworks/kdelibs/kdelibs-4.14.27.ebuild
@@ -0,0 +1,300 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+CMAKE_MIN_VERSION="3.3.1-r1"
+CPPUNIT_REQUIRED="optional"
+DECLARATIVE_REQUIRED="always"
+KDE_HANDBOOK="optional"
+OPENGL_REQUIRED="optional"
+WEBKIT_REQUIRED="optional"
+inherit kde4-base fdo-mime multilib toolchain-funcs flag-o-matic
+
+APPS_VERSION="16.12.0" # Don't forget to bump this
+
+DESCRIPTION="KDE libraries needed by all KDE programs"
+[[ ${KDE_BUILD_TYPE} != live ]] && \
+SRC_URI="mirror://kde/stable/applications/${APPS_VERSION}/src/${P}.tar.xz"
+
+KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux"
+LICENSE="LGPL-2.1"
+IUSE="cpu_flags_x86_3dnow acl altivec +bzip2 +crypt debug doc fam jpeg2k
+kerberos libressl lzma cpu_flags_x86_mmx nls openexr +policykit spell
+cpu_flags_x86_sse cpu_flags_x86_sse2 ssl +udev +udisks +upower zeroconf"
+
+REQUIRED_USE="
+ udisks? ( udev )
+ upower? ( udev )
+"
+
+# needs the kate regression testsuite from svn
+RESTRICT="test"
+
+COMMONDEPEND="
+ app-text/docbook-xml-dtd:4.2
+ app-text/docbook-xsl-stylesheets
+ >=dev-libs/libattica-0.4.2
+ dev-libs/libdbusmenu-qt[qt4]
+ dev-libs/libpcre[unicode]
+ dev-libs/libxml2
+ dev-libs/libxslt
+ media-libs/fontconfig
+ media-libs/freetype:2
+ media-libs/giflib:=
+ media-libs/libpng:0=
+ media-libs/phonon[qt4]
+ sys-libs/zlib
+ virtual/jpeg:0
+ x11-misc/shared-mime-info
+ acl? ( virtual/acl )
+ !aqua? (
+ x11-libs/libICE
+ x11-libs/libSM
+ x11-libs/libX11
+ x11-libs/libXau
+ x11-libs/libXcursor
+ x11-libs/libXdmcp
+ x11-libs/libXext
+ x11-libs/libXfixes
+ x11-libs/libXft
+ x11-libs/libXpm
+ x11-libs/libXrender
+ x11-libs/libXScrnSaver
+ x11-libs/libXtst
+ !kernel_SunOS? (
+ || (
+ sys-libs/libutempter
+ >=sys-freebsd/freebsd-lib-9.0
+ )
+ )
+ )
+ bzip2? ( app-arch/bzip2 )
+ crypt? ( app-crypt/qca:2[qt4] )
+ fam? ( virtual/fam )
+ jpeg2k? ( media-libs/jasper:= )
+ kerberos? ( virtual/krb5 )
+ openexr? (
+ media-libs/openexr:=
+ media-libs/ilmbase:=
+ )
+ policykit? ( sys-auth/polkit-qt[qt4] )
+ spell? ( app-text/enchant )
+ ssl? (
+ libressl? ( dev-libs/libressl:0= )
+ !libressl? ( dev-libs/openssl:0= )
+ )
+ udev? ( virtual/udev )
+ zeroconf? ( net-dns/avahi[mdnsresponder-compat] )
+"
+DEPEND="${COMMONDEPEND}
+ doc? ( app-doc/doxygen )
+ nls? ( virtual/libintl )
+"
+RDEPEND="${COMMONDEPEND}
+ !dev-qt/qtphonon
+ >=app-crypt/gnupg-2.0.11
+ app-misc/ca-certificates
+ kde-frameworks/kdelibs-env:4
+ sys-apps/dbus[X]
+ !aqua? (
+ udisks? ( sys-fs/udisks:2 )
+ x11-apps/iceauth
+ x11-apps/rgb
+ x11-misc/xdg-utils
+ upower? ( || ( >=sys-power/upower-0.9.23 sys-power/upower-pm-utils ) )
+ )
+ udev? ( app-misc/media-player-info )
+"
+PDEPEND="
+ $(add_kdeapps_dep katepart '' 4.14.3)
+ || (
+ $(add_kdeapps_dep kfmclient '' 4.14.3)
+ x11-misc/xdg-utils
+ )
+ handbook? ( kde-apps/khelpcenter:* )
+ policykit? ( || (
+ >=sys-auth/polkit-kde-agent-0.99
+ kde-plasma/polkit-kde-agent
+ ) )
+"
+
+PATCHES=(
+ "${FILESDIR}/dist/01_gentoo_set_xdg_menu_prefix-1.patch"
+ "${FILESDIR}/dist/02_gentoo_append_xdg_config_dirs-1.patch"
+ "${FILESDIR}/${PN}-4.14.5-fatalwarnings.patch"
+ "${FILESDIR}/${PN}-4.14.5-mimetypes.patch"
+ "${FILESDIR}/${PN}-4.4.90-xslt.patch"
+ "${FILESDIR}/${PN}-4.6.3-no_suid_kdeinit.patch"
+ "${FILESDIR}/${PN}-4.8.1-norpath.patch"
+ "${FILESDIR}/${PN}-4.9.3-werror.patch"
+ "${FILESDIR}/${PN}-4.10.0-udisks.patch"
+ "${FILESDIR}/${PN}-4.14.20-FindQt4.patch"
+ "${FILESDIR}/${PN}-4.14.22-webkit.patch"
+)
+
+pkg_pretend() {
+ if [[ ${MERGE_TYPE} != binary ]] && tc-is-gcc; then
+ [[ $(gcc-major-version) -lt 4 ]] || \
+ ( [[ $(gcc-major-version) -eq 4 && $(gcc-minor-version) -le 3 ]] ) \
+ && die "Sorry, but gcc-4.3 and earlier won't work for KDE SC 4.6 (see bug #354837)."
+ fi
+}
+
+src_prepare() {
+ kde4-base_src_prepare
+
+ # Rename applications.menu (needs 01_gentoo_set_xdg_menu_prefix-1.patch to work)
+ sed -e 's|FILES[[:space:]]applications.menu|FILES applications.menu RENAME kde-4-applications.menu|g' \
+ -i kded/CMakeLists.txt || die "Sed on CMakeLists.txt for applications.menu failed."
+
+ if use aqua; then
+ sed -i -e \
+ "s:BUNDLE_INSTALL_DIR \"/Applications:BUNDLE_INSTALL_DIR \"${EPREFIX}/${APP_BUNDLE_DIR}:g" \
+ cmake/modules/FindKDE4Internal.cmake || die "failed to sed FindKDE4Internal.cmake"
+
+ #if [[ ${CHOST} == *-darwin8 ]]; then
+ sed -i -e \
+ "s:set(_add_executable_param MACOSX_BUNDLE):remove(_add_executable_param MACOSX_BUNDLE):g" \
+ cmake/modules/KDE4Macros.cmake || die "failed to sed KDE4Macros.cmake"
+ #fi
+
+ # solid/solid/backends/iokit doesn't properly link, so disable it.
+ sed -e "s|\(APPLE\)|(FALSE)|g" -i solid/solid/CMakeLists.txt \
+ || die "disabling solid/solid/backends/iokit failed"
+ sed -e "s|m_backend = .*Backends::IOKit.*;|m_backend = 0;|g" -i solid/solid/managerbase.cpp \
+ || die "disabling solid/solid/backends/iokit failed"
+
+ # There's no fdatasync on OSX and the check fails to detect that.
+ sed -e "/HAVE_FDATASYNC/ d" -i config.h.cmake \
+ || die "disabling fdatasync failed"
+
+ # Fix nameser include to nameser8_compat
+ sed -e "s|nameser8_compat.h|nameser_compat.h|g" -i kio/misc/kpac/discovery.cpp \
+ || die "fixing nameser include failed"
+ append-flags -DHAVE_ARPA_NAMESER8_COMPAT_H=1
+
+ # Try to fix kkeyserver_mac
+ epatch "${FILESDIR}"/${PN}-4.3.80-kdeui_util_kkeyserver_mac.patch
+ fi
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DWITH_HSPELL=OFF
+ -DWITH_ASPELL=OFF
+ -DKDE_DEFAULT_HOME=.kde4
+ -DKAUTH_BACKEND=POLKITQT-1
+ -DWITH_Soprano=OFF
+ -DWITH_SharedDesktopOntologies=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_Strigi=ON
+ -DBUILD_doc=$(usex handbook)
+ -DHAVE_X86_3DNOW=$(usex cpu_flags_x86_3dnow)
+ -DHAVE_PPC_ALTIVEC=$(usex altivec)
+ -DHAVE_X86_MMX=$(usex cpu_flags_x86_mmx)
+ -DHAVE_X86_SSE=$(usex cpu_flags_x86_sse)
+ -DHAVE_X86_SSE2=$(usex cpu_flags_x86_sse2)
+ -DWITH_ACL=$(usex acl)
+ -DWITH_BZip2=$(usex bzip2)
+ -DWITH_QCA2=$(usex crypt)
+ -DWITH_FAM=$(usex fam)
+ -DWITH_Jasper=$(usex jpeg2k)
+ -DWITH_GSSAPI=$(usex kerberos)
+ -DWITH_LibLZMA=$(usex lzma)
+ -DWITH_Libintl=$(usex nls)
+ -DWITH_OpenEXR=$(usex openexr)
+ -DWITH_OpenGL=$(usex opengl)
+ -DWITH_PolkitQt-1=$(usex policykit)
+ -DWITH_ENCHANT=$(usex spell)
+ -DWITH_OpenSSL=$(usex ssl)
+ -DWITH_UDev=$(usex udev)
+ -DWITH_SOLID_UDISKS2=$(usex udisks)
+ -DWITH_Avahi=$(usex zeroconf)
+ -DWITH_KDEWEBKIT=$(usex webkit)
+ )
+
+ use zeroconf || mycmakeargs+=( -DWITH_DNSSD=OFF )
+
+ kde4-base_src_configure
+}
+
+src_compile() {
+ kde4-base_src_compile
+
+ # The building of apidox is not managed anymore by the build system
+ if use doc; then
+ einfo "Building API documentation"
+ cd "${S}"/doc/api/
+ ./doxygen.sh "${S}" || die "APIDOX generation failed"
+ fi
+}
+
+src_install() {
+ kde4-base_src_install
+
+ # use system certificates
+ rm -f "${ED}"/usr/share/apps/kssl/ca-bundle.crt || die
+ dosym /etc/ssl/certs/ca-certificates.crt /usr/share/apps/kssl/ca-bundle.crt
+
+ if use doc; then
+ einfo "Installing API documentation. This could take a bit of time."
+ cd "${S}"/doc/api/
+ docinto /HTML/en/kdelibs-apidox
+ dohtml -r ${P}-apidocs/*
+ fi
+
+ if use aqua; then
+ einfo "fixing ${PN} plugins"
+
+ local _PV=${PV:0:3}.0
+ local _dir=${EPREFIX}/usr/$(get_libdir)/kde4/plugins/script
+
+ install_name_tool -id \
+ "${_dir}/libkrossqtsplugin.${_PV}.dylib" \
+ "${D}/${_dir}/libkrossqtsplugin.${_PV}.dylib" \
+ || die "failed fixing libkrossqtsplugin.${_PV}.dylib"
+
+ einfo "fixing ${PN} cmake detection files"
+ #sed -i -e \
+ # "s:if (HAVE_XKB):if (HAVE_XKB AND NOT APPLE):g" \
+ echo -e "set(XKB_FOUND FALSE)\nset(HAVE_XKB FALSE)" > \
+ "${ED}"/usr/share/apps/cmake/modules/FindXKB.cmake \
+ || die "failed fixing FindXKB.cmake"
+ fi
+
+ einfo Installing environment file.
+ # Since 44qt4 is sourced earlier QT_PLUGIN_PATH is defined.
+ echo "COLON_SEPARATED=QT_PLUGIN_PATH" > "${T}/77kde"
+ echo "QT_PLUGIN_PATH=${EPREFIX}/usr/$(get_libdir)/kde4/plugins" >> "${T}/77kde"
+ doenvd "${T}/77kde"
+}
+
+pkg_postinst() {
+ fdo-mime_mime_database_update
+
+ if use zeroconf; then
+ echo
+ elog "To make zeroconf support available in KDE make sure that the avahi daemon"
+ elog "is running."
+ echo
+ einfo "If you also want to use zeroconf for hostname resolution, emerge sys-auth/nss-mdns"
+ einfo "and enable multicast dns lookups by editing the 'hosts:' line in /etc/nsswitch.conf"
+ einfo "to include 'mdns', e.g.:"
+ einfo " hosts: files mdns dns"
+ echo
+ fi
+
+ kde4-base_pkg_postinst
+}
+
+pkg_prerm() {
+ # Remove ksycoca4 global database
+ rm -f "${EROOT}${PREFIX}"/share/kde4/services/ksycoca4
+}
+
+pkg_postrm() {
+ fdo-mime_mime_database_update
+
+ kde4-base_pkg_postrm
+}
diff --git a/kde-frameworks/kdelibs/metadata.xml b/kde-frameworks/kdelibs/metadata.xml
new file mode 100644
index 000000000000..63ad9f4ad419
--- /dev/null
+++ b/kde-frameworks/kdelibs/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>kde@gentoo.org</email>
+ <name>Gentoo KDE Project</name>
+ </maintainer>
+ <use>
+ <flag name="opengl">Enable OpenGL support for Plasma (GLApplet)</flag>
+ </use>
+</pkgmetadata>