diff options
Diffstat (limited to 'eclass')
| -rw-r--r-- | eclass/kde4-base.eclass | 6 | ||||
| -rw-r--r-- | eclass/kde4-functions.eclass | 13 |
2 files changed, 17 insertions, 2 deletions
diff --git a/eclass/kde4-base.eclass b/eclass/kde4-base.eclass index 82b3e1a5951..276e7233474 100644 --- a/eclass/kde4-base.eclass +++ b/eclass/kde4-base.eclass @@ -560,10 +560,16 @@ kde4-base_src_configure() { # Here we set the install prefix mycmakeargs="${mycmakeargs} -DCMAKE_INSTALL_PREFIX=${PREFIX}" + # If prefix is /usr, sysconf needs to be /etc, not /usr/etc + [[ "${PREFIX}" == "/usr" ]] && mycmakeargs="${mycmakeargs} -DSYSCONF_INSTALL_DIR=/etc" + # Set environment QTEST_COLORED=1 QT_PLUGIN_PATH=${KDEDIR}/$(get_libdir)/kde4/plugins/ + # hardcode path to *.cmake KDE files + PKG_CONFIG_PATH="${PKG_CONFIG_PATH:+${PKG_CONFIG_PATH}:}${KDEDIR}/$(get_libdir)/pkgconfig" + cmake-utils_src_configureout } diff --git a/eclass/kde4-functions.eclass b/eclass/kde4-functions.eclass index 2407877ef21..bfbce2b74eb 100644 --- a/eclass/kde4-functions.eclass +++ b/eclass/kde4-functions.eclass @@ -462,13 +462,22 @@ done # but this default can be overridden by defining KDE_LINGUAS_DIR. enable_selected_linguas() { local lingua - comment_all_add_subdirectory "${KDE_LINGUAS_DIR:-${S}/po}" + for lingua in ${KDE_LINGUAS}; do - if use linguas_${lingua}; then + if [ -e "${S}"/po/"${lingua}".po ]; then + mv "${S}"/po/"${lingua}".po "${S}"/po/"${lingua}".po.old + fi + done + comment_all_add_subdirectory "${KDE_LINGUAS_DIR:-${S}/po}" + for lingua in ${LINGUAS}; do + if [ -d "${S}"/po/"${lingua}" ]; then sed -e "/add_subdirectory([[:space:]]*${lingua}[[:space:]]*)[[:space:]]*$/ s/^#DONOTCOMPILE //" \ -e "/ADD_SUBDIRECTORY([[:space:]]*${lingua}[[:space:]]*)[[:space:]]*$/ s/^#DONOTCOMPILE //" \ -i "${KDE_LINGUAS_DIR:-${S}/po}"/CMakeLists.txt || die "Sed to uncomment linguas_${lingua} failed." fi + if [ -e "${S}"/po/"${lingua}".po.old ]; then + mv "${S}"/po/"${lingua}".po.old "${S}"/po/"${lingua}".po + fi done } |
