diff options
author | E. Liddell <ejlddll@warpmail.net> | 2020-01-02 14:31:56 -0500 |
---|---|---|
committer | TDE Gitea <gitea@mirror.git.trinitydesktop.org> | 2020-01-06 23:43:39 +0000 |
commit | 3ffa67c73f0d6aee8c9cd5bd78b6ec3961bbb399 (patch) | |
tree | 0159672715973a301a99b5e769915f18bb22599b | |
parent | a660a380304baec5382823b143e0710be22bbb06 (diff) | |
download | tde-packaging-gentoo-3ffa67c73f0d6aee8c9cd5bd78b6ec3961bbb399.tar.gz tde-packaging-gentoo-3ffa67c73f0d6aee8c9cd5bd78b6ec3961bbb399.zip |
Update of trinity-* eclasses, tqt, tqtinterface, dbus-1-tqt, tdelibs to EAPI7 and git-v3; wholesale slaughter of obsolete eclass code; ebuilds for 14.0.6; aRts flag nonfunctional
Signed-off-by: E. Liddell <ejlddll@warpmail.net>
-rw-r--r-- | dev-libs/dbus-1-tqt/dbus-1-tqt-14.0.6.ebuild | 23 | ||||
-rw-r--r-- | dev-libs/dbus-1-tqt/dbus-1-tqt-9999.ebuild | 2 | ||||
-rw-r--r-- | dev-tqt/tqt/tqt-14.0.6.ebuild | 258 | ||||
-rw-r--r-- | dev-tqt/tqt/tqt-9999.ebuild | 74 | ||||
-rw-r--r-- | dev-tqt/tqtinterface/tqtinterface-14.0.6.ebuild | 34 | ||||
-rw-r--r-- | dev-tqt/tqtinterface/tqtinterface-9999.ebuild | 15 | ||||
-rw-r--r-- | eclass/git-2.eclass | 608 | ||||
-rw-r--r-- | eclass/trinity-base.eclass | 196 | ||||
-rw-r--r-- | eclass/trinity-functions.eclass | 52 | ||||
-rw-r--r-- | eclass/trinity-meta.eclass | 33 | ||||
-rw-r--r-- | trinity-base/tdelibs/tdelibs-14.0.6.ebuild | 141 | ||||
-rw-r--r-- | trinity-base/tdelibs/tdelibs-9999.ebuild | 53 |
12 files changed, 606 insertions, 883 deletions
diff --git a/dev-libs/dbus-1-tqt/dbus-1-tqt-14.0.6.ebuild b/dev-libs/dbus-1-tqt/dbus-1-tqt-14.0.6.ebuild new file mode 100644 index 00000000..1d7eb0fb --- /dev/null +++ b/dev-libs/dbus-1-tqt/dbus-1-tqt-14.0.6.ebuild @@ -0,0 +1,23 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ +EAPI="7" +TRINITY_MODULE_TYPE="dependencies" +TRINITY_MODULE_NAME="dbus-1-tqt" + +inherit trinity-base + +DESCRIPTION="D-BUS TQt bindings" +HOMEPAGE="http://trinitydesktop.org/" +LICENSE="GPL-2 LGPL-2" +KEYWORDS= +SLOT="0" +IUSE="" + +DEPEND="sys-apps/dbus + dev-tqt/tqtinterface" +RDEPEND="$DEPEND" + +src_configure() { + cmake-utils_src_configure +} diff --git a/dev-libs/dbus-1-tqt/dbus-1-tqt-9999.ebuild b/dev-libs/dbus-1-tqt/dbus-1-tqt-9999.ebuild index cb3944aa..1d7eb0fb 100644 --- a/dev-libs/dbus-1-tqt/dbus-1-tqt-9999.ebuild +++ b/dev-libs/dbus-1-tqt/dbus-1-tqt-9999.ebuild @@ -1,7 +1,7 @@ # Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="5" +EAPI="7" TRINITY_MODULE_TYPE="dependencies" TRINITY_MODULE_NAME="dbus-1-tqt" diff --git a/dev-tqt/tqt/tqt-14.0.6.ebuild b/dev-tqt/tqt/tqt-14.0.6.ebuild new file mode 100644 index 00000000..f928b253 --- /dev/null +++ b/dev-tqt/tqt/tqt-14.0.6.ebuild @@ -0,0 +1,258 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ +EAPI=7 + +inherit eutils flag-o-matic toolchain-funcs + +SRCTYPE="free" +DESCRIPTION="Trinity's Qt toolkit fork." +HOMEPAGE="http://trinitydesktop.org/" + +SRC_URI="http://www.mirrorservice.org/sites/trinitydesktop.org/trinity/releases/R${PV}/main/dependencies/tqt3-trinity-${PV}.tar.xz" +LICENSE="|| ( GPL-2 GPL-3 )" + +SLOT="3.5" +KEYWORDS="~amd64" +IUSE="cups debug doc examples firebird ipv6 mysql nas nis opengl postgres sqlite xinerama" +# no odbc, immtqt or immtqt-bc support anymore. +# TODO: optional support for xrender and xrandr + +RDEPEND=" + virtual/jpeg:= + >=media-libs/freetype-2 + >=media-libs/libmng-1.0.9 + media-libs/libpng:= + sys-libs/zlib + x11-libs/libXft + x11-libs/libXcursor + x11-libs/libXi + x11-libs/libXrandr + x11-libs/libSM + cups? ( net-print/cups ) + firebird? ( dev-db/firebird ) + mysql? ( virtual/mysql ) + nas? ( >=media-libs/nas-1.5 ) + opengl? ( virtual/opengl virtual/glu ) + postgres? ( dev-db/postgresql:= ) + xinerama? ( x11-libs/libXinerama ) + !dev-qt/qt:3 + !dev-qt/qt-meta:3" +DEPEND="${RDEPEND} + x11-base/xorg-proto" + +TQTBASE="/usr/tqt3" + +S="${WORKDIR}/tqt3-trinity-${PV}" + +pkg_setup() { + export QTDIR="${S}" + + CXX=$(tc-getCXX) + if [[ ${CXX/g++/} != ${CXX} ]]; then + PLATCXX="g++" + elif [[ ${CXX/icpc/} != ${CXX} ]]; then + PLATCXX="icc" + else + die "Unknown compiler ${CXX}." + fi + + case ${CHOST} in + *-freebsd*|*-dragonfly*) + PLATNAME="freebsd" ;; + *-openbsd*) + PLATNAME="openbsd" ;; + *-netbsd*) + PLATNAME="netbsd" ;; + *-darwin*) + PLATNAME="darwin" ;; + *-linux-*|*-linux) + PLATNAME="linux" ;; + *) + die "Unknown CHOST, no platform choosed." + esac + + if [[ "$CHOST" == *64* && "$PLATCXX" == "g++" ]]; then + export PLATFORM="${PLATNAME}-${PLATCXX}-64" + else + export PLATFORM="${PLATNAME}-${PLATCXX}" + fi +} + +src_prepare() { + # Apply user-provided patches + eapply_user + + # Do not link with -rpath. See bug #75181. + find "${S}"/mkspecs -name qmake.conf | xargs \ + sed -i -e 's:QMAKE_RPATH.*:QMAKE_RPATH =:' + + # set c/xxflags and ldflags + strip-flags + + sed -i -e "s:QMAKE_CFLAGS_RELEASE.*=.*:QMAKE_CFLAGS_RELEASE=${CFLAGS}:" \ + -e "s:QMAKE_CXXFLAGS_RELEASE.*=.*:QMAKE_CXXFLAGS_RELEASE=${CXXFLAGS}:" \ + -e "s:QMAKE_LFLAGS_RELEASE.*=.*:QMAKE_LFLAGS_RELEASE=${LDFLAGS}:" \ + -e "s:\<QMAKE_CC\>.*=.*:QMAKE_CC=$(tc-getCC):" \ + -e "s:\<QMAKE_CXX\>.*=.*:QMAKE_CXX=$(tc-getCXX):" \ + -e "s:\<QMAKE_LINK\>.*=.*:QMAKE_LINK=$(tc-getCXX):" \ + -e "s:\<QMAKE_LINK_SHLIB\>.*=.*:QMAKE_LINK_SHLIB=$(tc-getCXX):" \ + -e "s:\<QMAKE_STRIP\>.*=.*:QMAKE_STRIP=:" \ + "${S}/mkspecs/${PLATFORM}/qmake.conf" || die + + if [ $(get_libdir) != "lib" ] ; then + sed -i -e "s:/lib$:/$(get_libdir):" \ + "${S}/mkspecs/${PLATFORM}/qmake.conf" || die + fi + + sed -i -e "s:CXXFLAGS.*=:CXXFLAGS=${CXXFLAGS} :" \ + -e "s:LFLAGS.*=:LFLAGS=${LDFLAGS} :" \ + "${S}/qmake/Makefile.unix" || die + + # remove docs from install if we don't need it + use doc || sed -i -e '/INSTALLS.*=.*htmldocs/d' \ + "${S}/src/qt_install.pri" +} + +src_configure() { + export SYSCONF="${D}${TQTBASE}"/etc/settings + + # Let's just allow writing to these directories during Qt emerge + # as it makes TQt much happier. + addwrite "${TQTBASE}/etc/settings" + addwrite "${HOME}/.qt" + addwrite "${HOME}/.tqt" + + # common opts + myconf=" -sm -thread -stl -no-verbose -largefile -tablet -no-exceptions" + myconf+=" $(echo -{qt-imgfmt-,system-lib}{jpeg,mng,png})" + myconf+=" -platform ${PLATFORM} -xplatform ${PLATFORM}" + myconf+=" -xft -xrender -prefix ${TQTBASE}" + myconf+=" -libdir ${TQTBASE}/$(get_libdir) -fast -no-sql-odbc" + + [ "$(get_libdir)" != "lib" ] && myconf+="${myconf} -L/usr/$(get_libdir)" + + use nas && myconf+=" -system-nas-sound" + use nis && myconf+=" -nis" || myconf+=" -no-nis" + use mysql && myconf+=" -plugin-sql-mysql -I/usr/include/mysql -L/usr/$(get_libdir)/mysql" || myconf+=" -no-sql-mysql" + use postgres && myconf+=" -plugin-sql-psql -I/usr/include/postgresql/server -I/usr/include/postgresql/pgsql -I/usr/include/postgresql/pgsql/server" || myconf+=" -no-sql-psql" + use firebird && myconf+=" -plugin-sql-ibase -I/opt/firebird/include" || myconf+=" -no-sql-ibase" + use sqlite && myconf+=" -plugin-sql-sqlite" || myconf+=" -no-sql-sqlite" + use cups && myconf+=" -cups" || myconf+=" -no-cups" + use opengl && myconf+=" -enable-module=opengl" || myconf+=" -disable-opengl" + use debug && myconf+=" -debug" || myconf+=" -release -no-g++-exceptions" + use xinerama && myconf+=" -xinerama" || myconf+=" -no-xinerama" + + myconf+=" -system-zlib -qt-gif" + + use ipv6 && myconf+=" -ipv6" || myconf+=" -no-ipv6" + + myconf+=" -dlopen-opengl" + + export YACC='byacc -d' + tc-export CC CXX + export LINK="$(tc-getCXX)" + + einfo ./configure ${myconf} + ./configure ${myconf} || die +} + +src_compile() { + emake src-qmake src-moc sub-src + + export DYLD_LIBRARY_PATH="${S}/lib:/usr/X11R6/lib:${DYLD_LIBRARY_PATH}" + export LD_LIBRARY_PATH="${S}/lib:${LD_LIBRARY_PATH}" + + emake sub-tools + + if use examples; then + emake sub-tutorial sub-examples + fi + + # Make the msg2qm utility (not made by default) +# cd "${S}"/tools/msg2tqm +# ../../bin/tqmake || die +# emake + + # Make the qembed utility (not made by default) +# cd "${S}"/tools/qembed +# ../../bin/tqmake || die +# emake + +} + +src_install() { + emake INSTALL_ROOT="${D}" install + # Next executables are missing to be installed: + # /usr/qt/3/bin/findtr + # /usr/qt/3/bin/conv2ui + # /usr/qt/3/bin/qt20fix + # /usr/qt/3/bin/qtrename140 + # I'm not sure if they are really needed + + # fix pkgconfig location + dodir /usr/$(get_libdir) + mv "${D}${TQTBASE}/$(get_libdir)/pkgconfig" "${D}/usr/$(get_libdir)/" + + # cleanup a bad symlink created by crappy install scrypt + rm -r "${D}${TQTBASE}/mkspec/${PLATFORM}/${PLATFORM}" + + # List all the multilib libdirs + local libdirs + for alibdir in $(get_all_libdirs); do + libdirs="${libdirs}:${TQTBASE}/${alibdir}" + done + + # environment variables + cat <<EOF > "${T}"/44tqt3 +PATH=${TQTBASE}/bin +ROOTPATH=${TQTBASE}/bin +LDPATH=${libdirs:1} +MANPATH=${TQTBASE}/doc/man +EOF + + cat <<EOF > "${T}"/44-tqt3-revdep +SEARCH_DIRS="${TQTBASE}" +EOF + + insinto /etc/revdep-rebuild + doins "${T}"/44-tqt3-revdep + doenvd "${T}"/44tqt3 + + if [ "${SYMLINK_LIB}" = "yes" ]; then + dosym $(get_abi_LIBDIR ${DEFAULT_ABI}) ${TQTBASE}/lib + fi + + keepdir ${TQTBASE}/etc/settings + + if use doc; then + insinto ${TQTBASE} + doins -r "${S}"/doc + fi + + if use examples; then + find "${S}"/examples "${S}"/tutorial -name Makefile | \ + xargs sed -i -e "s:${S}:${TQTBASE}:g" + + cp -r "${S}"/examples "${D}"${TQTBASE}/ + cp -r "${S}"/tutorial "${D}"${TQTBASE}/ + fi + + # misc build reqs + + sed -e "s:${S}:${TQTBASE}:g" \ + "${S}"/.qmake.cache > "${D}"${TQTBASE}/.qmake.cache + + dodoc FAQ README README-QT.TXT changes* +} + +pkg_postinst() { + echo + elog "After a rebuild of TQt, it can happen that TQt plugins (such as TQt/TDE styles," + elog "or widgets for the TQt designer) are no longer recognized. If this situation" + elog "occurs you should recompile the packages providing these plugins," + elog "and you should also make sure that TQt and its plugins were compiled with the" + elog "same version of GCC. Packages that may need to be rebuilt are, for instance," + elog "tde-base/tdelibs, tde-base/tdeartwork and tde-base/tdeartwork-styles." + echo +} diff --git a/dev-tqt/tqt/tqt-9999.ebuild b/dev-tqt/tqt/tqt-9999.ebuild index 81739589..eec87c0d 100644 --- a/dev-tqt/tqt/tqt-9999.ebuild +++ b/dev-tqt/tqt/tqt-9999.ebuild @@ -1,25 +1,19 @@ # Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI=5 +EAPI=7 -RESTRICT=network-sandbox -inherit eutils git-2 toolchain-funcs +inherit eutils git-r3 flag-o-matic toolchain-funcs SRCTYPE="free" -DESCRIPTION="The Trinitie's TQt toolkit fork." +DESCRIPTION="Trinity's Qt toolkit fork." HOMEPAGE="http://trinitydesktop.org/" -# IMMTQT_P="tqt-x11-immodule-unified-tqt3.3.8-20070321-gentoo" - -#SRC_URI="ftp://ftp.trolltech.com/tqt/source/tqt-x11-${SRCTYPE}-${PV}.tar.gz -# immtqt? ( mirror://gentoo/${IMMTQT_P}.diff.bz2 ) -# immtqt-bc? ( mirror://gentoo/${IMMTQT_P}.diff.bz2 )" +#SRC_URI="http://www.mirrorservice.org/sites/trinitydesktop.org/trinity/releases/R${PV}/main/dependencies/tqt3-trinity-${PV}.tar.xz" EGIT_REPO_URI="https://mirror.git.trinitydesktop.org/gitea/TDE/tqt3" -EGIT_PROJECT="trinity/tqt3" -LICENSE="|| ( QPL-1.0 GPL-2 GPL-3 )" +LICENSE="|| ( GPL-2 GPL-3 )" -SLOT="3" +SLOT="3.5" KEYWORDS= IUSE="cups debug doc examples firebird ipv6 mysql nas nis opengl postgres sqlite xinerama" # no odbc, immtqt and immtqt-bc support anymore. @@ -48,28 +42,10 @@ RDEPEND=" DEPEND="${RDEPEND} x11-base/xorg-proto" -#PDEPEND="odbc? ( ~dev-db/tqt-unixODBC-$PV )" - -#S="${WORKDIR}/tqt-x11-${SRCTYPE}-${PV}" - TQTBASE="/usr/tqt3" pkg_setup() { -# if use immtqt && use immtqt-bc ; then -# ewarn -# ewarn "immtqt and immtqt-bc are exclusive. You cannot set both." -# ewarn "Please specify either immtqt or immtqt-bc." -# ewarn -# die -# elif use immtqt ; then -# ewarn -# ewarn "You are going to compile binary imcompatible immodule for Qt. This means" -## ewarn "you have to recompile everything depending on Qt after you install it." -# ewarn "Be aware." -# ewarn -# fi - - export TQTDIR="${S}" + export QTDIR="${S}" CXX=$(tc-getCXX) if [[ ${CXX/g++/} != ${CXX} ]]; then @@ -104,17 +80,11 @@ pkg_setup() { src_prepare() { # Apply user-provided patches - epatch_user + eapply_user # Do not link with -rpath. See bug #75181. find "${S}"/mkspecs -name qmake.conf | xargs \ sed -i -e 's:QMAKE_RPATH.*:QMAKE_RPATH =:' -# if use immtqt || use immtqt-bc ; then -# epatch ../${IMMTQT_P}.diff -# sh make-symlinks.sh || die "make symlinks failed" -# -# epatch "${FILESDIR}"/tqt-3.3.8-immtqt+gcc-4.3.patch -# fi # set c/xxflags and ldflags strip-flags @@ -161,7 +131,6 @@ src_configure() { [ "$(get_libdir)" != "lib" ] && myconf+="${myconf} -L/usr/$(get_libdir)" - # unixODBC support is now a PDEPEND on dev-db/tqt-unixODBC; see bug 14178. use nas && myconf+=" -system-nas-sound" use nis && myconf+=" -nis" || myconf+=" -no-nis" use mysql && myconf+=" -plugin-sql-mysql -I/usr/include/mysql -L/usr/$(get_libdir)/mysql" || myconf+=" -no-sql-mysql" @@ -176,8 +145,6 @@ src_configure() { myconf+=" -system-zlib -qt-gif" use ipv6 && myconf+=" -ipv6" || myconf+=" -no-ipv6" -# use immtqt-bc && myconf+=" -inputmethod" -# use immtqt && myconf+=" -inputmethod -inputmethod-ext" myconf+=" -dlopen-opengl" @@ -202,14 +169,14 @@ src_compile() { fi # Make the msg2qm utility (not made by default) - cd "${S}"/tools/msg2tqm - ../../bin/tqmake || die - emake +# cd "${S}"/tools/msg2tqm +# ../../bin/tqmake || die +# emake # Make the qembed utility (not made by default) - cd "${S}"/tools/qembed - ../../bin/tqmake || die - emake +# cd "${S}"/tools/qembed +# ../../bin/tqmake || die +# emake } @@ -255,12 +222,6 @@ EOF dosym $(get_abi_LIBDIR ${DEFAULT_ABI}) ${TQTBASE}/lib fi -# insinto ${TQTBASE}/tools/designer -# doins -r tools/designer/templates -# -# insinto ${TQTBASE} -# doins -r translations -# keepdir ${TQTBASE}/etc/settings if use doc; then @@ -276,17 +237,12 @@ EOF cp -r "${S}"/tutorial "${D}"${TQTBASE}/ fi -# # misc build reqs -# insinto ${TQTBASE}/mkspecs -# doins -r "${S}"/mkspecs/${PLATFORM} + # misc build reqs sed -e "s:${S}:${TQTBASE}:g" \ "${S}"/.qmake.cache > "${D}"${TQTBASE}/.qmake.cache dodoc FAQ README README-QT.TXT changes* -# if use immtqt || use immtqt-bc ; then -# dodoc "${S}"/README.immodule -# fi } pkg_postinst() { diff --git a/dev-tqt/tqtinterface/tqtinterface-14.0.6.ebuild b/dev-tqt/tqtinterface/tqtinterface-14.0.6.ebuild new file mode 100644 index 00000000..22cd2684 --- /dev/null +++ b/dev-tqt/tqtinterface/tqtinterface-14.0.6.ebuild @@ -0,0 +1,34 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ +EAPI="7" +TRINITY_MODULE_TYPE="dependencies" +TRINITY_MODULE_NAME="${PN}" + +inherit trinity-base + +DESCRIPTION="Interface and abstraction library for TQt and Trinity" +HOMEPAGE="http://trinitydesktop.org/" + +LICENSE="GPL-2" +KEYWORDS="~amd64" +SLOT="0" + +#Note: for the sake of easier maintenance, building against QT3 +# (no T) is no longer a thing. +DEPEND="~dev-tqt/tqt-${PV} + !!x11-libs/tqtinterface" +RDEPEND="${DEPEND}" + +pkg_setup() { + export QTDIR="/usr/tqt3" +} + +src_configure() { + mycmakeargs=( + -DUSE_QT3=ON + -DQT_PREFIX_DIR="$QTDIR" + ) + + cmake-utils_src_configure +} diff --git a/dev-tqt/tqtinterface/tqtinterface-9999.ebuild b/dev-tqt/tqtinterface/tqtinterface-9999.ebuild index e3f00612..6448acb0 100644 --- a/dev-tqt/tqtinterface/tqtinterface-9999.ebuild +++ b/dev-tqt/tqtinterface/tqtinterface-9999.ebuild @@ -1,7 +1,7 @@ # Copyright 1999-2016 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="5" +EAPI="7" TRINITY_MODULE_TYPE="dependencies" TRINITY_MODULE_NAME="${PN}" @@ -12,21 +12,22 @@ HOMEPAGE="http://trinitydesktop.org/" LICENSE="GPL-2" KEYWORDS= -IUSE="+tqt" -REQUIRED_USE="^^ ( tqt )" SLOT="0" -DEPEND="tqt? ( >=dev-tqt/tqt-9999 )" +#Note: for the sake of easier maintenance, building against QT3 +# (no T) is no longer a thing. +DEPEND="~dev-tqt/tqt-${PV} + !!x11-libs/tqtinterface" RDEPEND="${DEPEND}" pkg_setup() { - use tqt && export TQTDIR="/usr/tqt3" + export QTDIR="/usr/tqt3" } src_configure() { mycmakeargs=( - -DUSE_QT3=ON - -DQT_PREFIX_DIR="$TQTDIR" + -DUSE_QT3=ON + -DQT_PREFIX_DIR="$QTDIR" ) cmake-utils_src_configure diff --git a/eclass/git-2.eclass b/eclass/git-2.eclass deleted file mode 100644 index 3dedf642..00000000 --- a/eclass/git-2.eclass +++ /dev/null @@ -1,608 +0,0 @@ -# Copyright 1999-2014 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -# @ECLASS: git-2.eclass -# @MAINTAINER: -# Michał Górny <mgorny@gentoo.org> -# Donnie Berkholz <dberkholz@gentoo.org> -# @BLURB: Eclass for fetching and unpacking git repositories. -# @DESCRIPTION: -# Eclass for easing maitenance of live ebuilds using git as remote repository. -# Eclass support working with git submodules and branching. -# -# This eclass is DEPRECATED. Please use git-r3 instead. - -if [[ ${EAPI} == 6 ]]; then - die "${ECLASS}.eclass is banned in EAPI ${EAPI}" -fi - -# This eclass support all EAPIs -EXPORT_FUNCTIONS src_unpack - -DEPEND="dev-vcs/git" - -# @ECLASS-VARIABLE: EGIT_SOURCEDIR -# @DESCRIPTION: -# This variable specifies destination where the cloned -# data are copied to. -# -# EGIT_SOURCEDIR="${S}" - -# @ECLASS-VARIABLE: EGIT_STORE_DIR -# @DESCRIPTION: -# Storage directory for git sources. -# -# EGIT_STORE_DIR="${DISTDIR}/egit-src" - -# @ECLASS-VARIABLE: EGIT_HAS_SUBMODULES -# @DEFAULT_UNSET -# @DESCRIPTION: -# If non-empty this variable enables support for git submodules in our -# checkout. Also this makes the checkout to be non-bare for now. - -# @ECLASS-VARIABLE: EGIT_OPTIONS -# @DEFAULT_UNSET -# @DESCRIPTION: -# Variable specifying additional options for fetch command. - -# @ECLASS-VARIABLE: EGIT_MASTER -# @DESCRIPTION: -# Variable for specifying master branch. -# Usefull when upstream don't have master branch or name it differently. -# -# EGIT_MASTER="master" - -# @ECLASS-VARIABLE: EGIT_PROJECT -# @DESCRIPTION: -# Variable specifying name for the folder where we check out the git -# repository. Value of this variable should be unique in the -# EGIT_STORE_DIR as otherwise you would override another repository. -# -# EGIT_PROJECT="${EGIT_REPO_URI##*/}" - -# @ECLASS-VARIABLE: EGIT_DIR -# @DESCRIPTION: -# Directory where we want to store the git data. -# This variable should not be overriden. -# -# EGIT_DIR="${EGIT_STORE_DIR}/${EGIT_PROJECT}" - -# @ECLASS-VARIABLE: EGIT_REPO_URI -# @REQUIRED -# @DEFAULT_UNSET -# @DESCRIPTION: -# URI for the repository -# e.g. http://foo, git://bar -# -# It can be overriden via env using packagename_LIVE_REPO -# variable. -# -# Support multiple values: -# EGIT_REPO_URI="git://a/b.git http://c/d.git" - -# @ECLASS-VARIABLE: EVCS_OFFLINE -# @DEFAULT_UNSET -# @DESCRIPTION: -# If non-empty this variable prevents performance of any online -# operations. - -# @ECLASS-VARIABLE: EGIT_BRANCH -# @DESCRIPTION: -# Variable containing branch name we want to check out. -# It can be overriden via env using packagename_LIVE_BRANCH -# variable. -# -# EGIT_BRANCH="${EGIT_MASTER}" - -# @ECLASS-VARIABLE: EGIT_COMMIT -# @DESCRIPTION: -# Variable containing commit hash/tag we want to check out. -# It can be overriden via env using packagename_LIVE_COMMIT -# variable. -# -# EGIT_COMMIT="${EGIT_BRANCH}" - -# @ECLASS-VARIABLE: EGIT_REPACK -# @DEFAULT_UNSET -# @DESCRIPTION: -# If non-empty this variable specifies that repository will be repacked to -# save space. However this can take a REALLY LONG time with VERY big -# repositories. - -# @ECLASS-VARIABLE: EGIT_PRUNE -# @DEFAULT_UNSET -# @DESCRIPTION: -# If non-empty this variable enables pruning all loose objects on each fetch. -# This is useful if upstream rewinds and rebases branches often. - -# @ECLASS-VARIABLE: EGIT_NONBARE -# @DEFAULT_UNSET -# @DESCRIPTION: -# If non-empty this variable specifies that all checkouts will be done using -# non bare repositories. This is useful if you can't operate with bare -# checkouts for some reason. - -# @ECLASS-VARIABLE: EGIT_NOUNPACK -# @DEFAULT_UNSET -# @DESCRIPTION: -# If non-empty this variable bans unpacking of ${A} content into the srcdir. -# Default behaviour is to unpack ${A} content. - -# @FUNCTION: git-2_init_variables -# @INTERNAL -# @DESCRIPTION: -# Internal function initializing all git variables. -# We define it in function scope so user can define -# all the variables before and after inherit. -git-2_init_variables() { - debug-print-function ${FUNCNAME} "$@" - - local esc_pn liverepo livebranch livecommit - esc_pn=${PN//[-+]/_} - - : ${EGIT_SOURCEDIR="${S}"} - - : ${EGIT_STORE_DIR:="${PORTAGE_ACTUAL_DISTDIR-${DISTDIR}}/egit-src"} - - : ${EGIT_HAS_SUBMODULES:=} - - : ${EGIT_OPTIONS:=} - - : ${EGIT_MASTER:=master} - - liverepo=${esc_pn}_LIVE_REPO - EGIT_REPO_URI=${!liverepo:-${EGIT_REPO_URI}} - [[ ${EGIT_REPO_URI} ]] || die "EGIT_REPO_URI must have some value" - - : ${EVCS_OFFLINE:=} - - livebranch=${esc_pn}_LIVE_BRANCH - [[ ${!livebranch} ]] && ewarn "QA: using \"${esc_pn}_LIVE_BRANCH\" variable, you won't get any support" - EGIT_BRANCH=${!livebranch:-${EGIT_BRANCH:-${EGIT_MASTER}}} - - livecommit=${esc_pn}_LIVE_COMMIT - [[ ${!livecommit} ]] && ewarn "QA: using \"${esc_pn}_LIVE_COMMIT\" variable, you won't get any support" - EGIT_COMMIT=${!livecommit:-${EGIT_COMMIT:-${EGIT_BRANCH}}} - - : ${EGIT_REPACK:=} - - : ${EGIT_PRUNE:=} -} - -# @FUNCTION: git-2_submodules -# @INTERNAL -# @DESCRIPTION: -# Internal function wrapping the submodule initialisation and update. -git-2_submodules() { - debug-print-function ${FUNCNAME} "$@" - if [[ ${EGIT_HAS_SUBMODULES} ]]; then - if [[ ${EVCS_OFFLINE} ]]; then - # for submodules operations we need to be online - debug-print "${FUNCNAME}: not updating submodules in offline mode" - return 1 - fi - - debug-print "${FUNCNAME}: working in \"${1}\"" - pushd "${EGIT_DIR}" > /dev/null || die - - debug-print "${FUNCNAME}: git submodule init" - git submodule init || die - debug-print "${FUNCNAME}: git submodule sync" - git submodule sync || die - debug-print "${FUNCNAME}: git submodule update" - git submodule update || die - - popd > /dev/null || die - fi -} - -# @FUNCTION: git-2_branch -# @INTERNAL -# @DESCRIPTION: -# Internal function that changes branch for the repo based on EGIT_COMMIT and -# EGIT_BRANCH variables. -git-2_branch() { - debug-print-function ${FUNCNAME} "$@" - - local branchname src - - debug-print "${FUNCNAME}: working in \"${EGIT_SOURCEDIR}\"" - pushd "${EGIT_SOURCEDIR}" > /dev/null || die - - local branchname=branch-${EGIT_BRANCH} src=origin/${EGIT_BRANCH} - if [[ ${EGIT_COMMIT} != ${EGIT_BRANCH} ]]; then - branchname=tree-${EGIT_COMMIT} - src=${EGIT_COMMIT} - fi - debug-print "${FUNCNAME}: git checkout -b ${branchname} ${src}" - git checkout -b ${branchname} ${src} \ - || die "${FUNCNAME}: changing the branch failed" - - popd > /dev/null || die -} - -# @FUNCTION: git-2_gc -# @INTERNAL -# @DESCRIPTION: -# Internal function running garbage collector on checked out tree. -git-2_gc() { - debug-print-function ${FUNCNAME} "$@" - - local args - - if [[ ${EGIT_REPACK} || ${EGIT_PRUNE} ]]; then - pushd "${EGIT_DIR}" > /dev/null || die - ebegin "Garbage collecting the repository" - [[ ${EGIT_PRUNE} ]] && args='--prune' - debug-print "${FUNCNAME}: git gc ${args}" - git gc ${args} - eend $? - popd > /dev/null || die - fi -} - -# @FUNCTION: git-2_prepare_storedir -# @INTERNAL -# @DESCRIPTION: -# Internal function preparing directory where we are going to store SCM -# repository. -git-2_prepare_storedir() { - debug-print-function ${FUNCNAME} "$@" - - local clone_dir - - # initial clone, we have to create master git storage directory and play - # nicely with sandbox - if [[ ! -d ${EGIT_STORE_DIR} ]]; then - debug-print "${FUNCNAME}: Creating git main storage directory" - addwrite / - mkdir -m 775 -p "${EGIT_STORE_DIR}" \ - || die "${FUNCNAME}: can't mkdir \"${EGIT_STORE_DIR}\"" - fi - - # allow writing into EGIT_STORE_DIR - addwrite "${EGIT_STORE_DIR}" - - # calculate git.eclass store dir for data - # We will try to clone the old repository, - # and we will remove it if we don't need it anymore. - EGIT_OLD_CLONE= - if [[ ${EGIT_STORE_DIR} == */egit-src ]]; then - local old_store_dir=${EGIT_STORE_DIR/%egit-src/git-src} - local old_location=${old_store_dir}/${EGIT_PROJECT:-${PN}} - - if [[ -d ${old_location} ]]; then - EGIT_OLD_CLONE=${old_location} - # required to remove the old clone - addwrite "${old_store_dir}" - fi - fi - - # calculate the proper store dir for data - # If user didn't specify the EGIT_DIR, we check if he did specify - # the EGIT_PROJECT or get the folder name from EGIT_REPO_URI. - EGIT_REPO_URI=${EGIT_REPO_URI%/} - if [[ ! ${EGIT_DIR} ]]; then - if [[ ${EGIT_PROJECT} ]]; then - clone_dir=${EGIT_PROJECT} - else - local strippeduri=${EGIT_REPO_URI%/.git} - clone_dir=${strippeduri##*/} - fi - EGIT_DIR=${EGIT_STORE_DIR}/${clone_dir} - - if [[ ${EGIT_OLD_CLONE} && ! -d ${EGIT_DIR} ]]; then - elog "${FUNCNAME}: ${CATEGORY}/${PF} will be cloned from old location." - elog "It will be necessary to rebuild the package to fetch updates." - EGIT_REPO_URI="${EGIT_OLD_CLONE} ${EGIT_REPO_URI}" - fi - fi - export EGIT_DIR=${EGIT_DIR} - debug-print "${FUNCNAME}: Storing the repo into \"${EGIT_DIR}\"." -} - -# @FUNCTION: git-2_move_source -# @INTERNAL -# @DESCRIPTION: -# Internal function moving sources from the EGIT_DIR to EGIT_SOURCEDIR dir. -git-2_move_source() { - debug-print-function ${FUNCNAME} "$@" - - debug-print "${FUNCNAME}: ${MOVE_COMMAND} \"${EGIT_DIR}\" \"${EGIT_SOURCEDIR}\"" - pushd "${EGIT_DIR}" > /dev/null || die - mkdir -p "${EGIT_SOURCEDIR}" \ - || die "${FUNCNAME}: failed to create ${EGIT_SOURCEDIR}" - ${MOVE_COMMAND} "${EGIT_SOURCEDIR}" \ - || die "${FUNCNAME}: sync to \"${EGIT_SOURCEDIR}\" failed" - popd > /dev/null || die -} - -# @FUNCTION: git-2_initial_clone -# @INTERNAL -# @DESCRIPTION: -# Internal function running initial clone on specified repo_uri. -git-2_initial_clone() { - debug-print-function ${FUNCNAME} "$@" - - local repo_uri - - EGIT_REPO_URI_SELECTED="" - for repo_uri in ${EGIT_REPO_URI}; do - debug-print "${FUNCNAME}: git clone ${EGIT_LOCAL_OPTIONS} \"${repo_uri}\" \"${EGIT_DIR}\"" - if git clone ${EGIT_LOCAL_OPTIONS} "${repo_uri}" "${EGIT_DIR}"; then - # global variable containing the repo_name we will be using - debug-print "${FUNCNAME}: EGIT_REPO_URI_SELECTED=\"${repo_uri}\"" - EGIT_REPO_URI_SELECTED="${repo_uri}" - break - fi - done - - [[ ${EGIT_REPO_URI_SELECTED} ]] \ - || die "${FUNCNAME}: can't fetch from ${EGIT_REPO_URI}" -} - -# @FUNCTION: git-2_update_repo -# @INTERNAL -# @DESCRIPTION: -# Internal function running update command on specified repo_uri. -git-2_update_repo() { - debug-print-function ${FUNCNAME} "$@" - - local repo_uri - - if [[ ${EGIT_LOCAL_NONBARE} ]]; then - # checkout master branch and drop all other local branches - git checkout ${EGIT_MASTER} || die "${FUNCNAME}: can't checkout master branch ${EGIT_MASTER}" - for x in $(git branch | grep -v "* ${EGIT_MASTER}" | tr '\n' ' '); do - debug-print "${FUNCNAME}: git branch -D ${x}" - git branch -D ${x} > /dev/null - done - fi - - EGIT_REPO_URI_SELECTED="" - for repo_uri in ${EGIT_REPO_URI}; do - # git urls might change, so reset it - git config remote.origin.url "${repo_uri}" - - debug-print "${EGIT_UPDATE_CMD}" - if ${EGIT_UPDATE_CMD} > /dev/null; then - # global variable containing the repo_name we will be using - debug-print "${FUNCNAME}: EGIT_REPO_URI_SELECTED=\"${repo_uri}\"" - EGIT_REPO_URI_SELECTED="${repo_uri}" - break - fi - done - - [[ ${EGIT_REPO_URI_SELECTED} ]] \ - || die "${FUNCNAME}: can't update from ${EGIT_REPO_URI}" -} - -# @FUNCTION: git-2_fetch -# @INTERNAL -# @DESCRIPTION: -# Internal function fetching repository from EGIT_REPO_URI and storing it in -# specified EGIT_STORE_DIR. -git-2_fetch() { - debug-print-function ${FUNCNAME} "$@" - - local oldsha cursha repo_type - - [[ ${EGIT_LOCAL_NONBARE} ]] && repo_type="non-bare repository" || repo_type="bare repository" - - if [[ ! -d ${EGIT_DIR} ]]; then - git-2_initial_clone - pushd "${EGIT_DIR}" > /dev/null || die - cursha=$(git rev-parse ${UPSTREAM_BRANCH}) - echo "GIT NEW clone -->" - echo " repository: ${EGIT_REPO_URI_SELECTED}" - echo " at the commit: ${cursha}" - - popd > /dev/null || die - elif [[ ${EVCS_OFFLINE} ]]; then - pushd "${EGIT_DIR}" > /dev/null || die - cursha=$(git rev-parse ${UPSTREAM_BRANCH}) - echo "GIT offline update -->" - echo " repository: $(git config remote.origin.url)" - echo " at the commit: ${cursha}" - popd > /dev/null || die - else - pushd "${EGIT_DIR}" > /dev/null || die - oldsha=$(git rev-parse ${UPSTREAM_BRANCH}) - git-2_update_repo - cursha=$(git rev-parse ${UPSTREAM_BRANCH}) - - # fetch updates - echo "GIT update -->" - echo " repository: ${EGIT_REPO_URI_SELECTED}" - # write out message based on the revisions - if [[ "${oldsha}" != "${cursha}" ]]; then - echo " updating from commit: ${oldsha}" - echo " to commit: ${cursha}" - else - echo " at the commit: ${cursha}" - fi - - # print nice statistic of what was changed - git --no-pager diff --stat ${oldsha}..${UPSTREAM_BRANCH} - popd > /dev/null || die - fi - # export the version the repository is at - export EGIT_VERSION="${cursha}" - # log the repo state - [[ ${EGIT_COMMIT} != ${EGIT_BRANCH} ]] \ - && echo " commit: ${EGIT_COMMIT}" - echo " branch: ${EGIT_BRANCH}" - echo " storage directory: \"${EGIT_DIR}\"" - echo " checkout type: ${repo_type}" - - # Cleanup after git.eclass - if [[ ${EGIT_OLD_CLONE} ]]; then - einfo "${FUNCNAME}: removing old clone in ${EGIT_OLD_CLONE}." - rm -rf "${EGIT_OLD_CLONE}" - fi -} - -# @FUNCTION: git_bootstrap -# @INTERNAL -# @DESCRIPTION: -# Internal function that runs bootstrap command on unpacked source. -git-2_bootstrap() { - debug-print-function ${FUNCNAME} "$@" - - # @ECLASS-VARIABLE: EGIT_BOOTSTRAP - # @DESCRIPTION: - # Command to be executed after checkout and clone of the specified - # repository. - # enviroment the package will fail if there is no update, thus in - # combination with --keep-going it would lead in not-updating - # pakcages that are up-to-date. - if [[ ${EGIT_BOOTSTRAP} ]]; then - pushd "${EGIT_SOURCEDIR}" > /dev/null || die - einfo "Starting bootstrap" - - if [[ -f ${EGIT_BOOTSTRAP} ]]; then - # we have file in the repo which we should execute - debug-print "${FUNCNAME}: bootstraping with file \"${EGIT_BOOTSTRAP}\"" - - if [[ -x ${EGIT_BOOTSTRAP} ]]; then - eval "./${EGIT_BOOTSTRAP}" \ - || die "${FUNCNAME}: bootstrap script failed" - else - eerror "\"${EGIT_BOOTSTRAP}\" is not executable." - eerror "Report upstream, or bug ebuild maintainer to remove bootstrap command." - die "\"${EGIT_BOOTSTRAP}\" is not executable" - fi - else - # we execute some system command - debug-print "${FUNCNAME}: bootstraping with commands \"${EGIT_BOOTSTRAP}\"" - - eval "${EGIT_BOOTSTRAP}" \ - || die "${FUNCNAME}: bootstrap commands failed" - fi - - einfo "Bootstrap finished" - popd > /dev/null || die - fi -} - -# @FUNCTION: git-2_migrate_repository -# @INTERNAL -# @DESCRIPTION: -# Internal function migrating between bare and normal checkout repository. -# This is based on usage of EGIT_SUBMODULES, at least until they -# start to work with bare checkouts sanely. -# This function also set some global variables that differ between -# bare and non-bare checkout. -git-2_migrate_repository() { - debug-print-function ${FUNCNAME} "$@" - - local bare returnstate - - # first find out if we have submodules - # or user explicitly wants us to use non-bare clones - if ! [[ ${EGIT_HAS_SUBMODULES} || ${EGIT_NONBARE} ]]; then - bare=1 - fi - - # test if we already have some repo and if so find out if we have - # to migrate the data - if [[ -d ${EGIT_DIR} ]]; then - if [[ ${bare} && -d ${EGIT_DIR}/.git ]]; then - debug-print "${FUNCNAME}: converting \"${EGIT_DIR}\" to bare copy" - - ebegin "Converting \"${EGIT_DIR}\" from non-bare to bare copy" - mv "${EGIT_DIR}/.git" "${EGIT_DIR}.bare" - export GIT_DIR="${EGIT_DIR}.bare" - git config core.bare true > /dev/null - returnstate=$? - unset GIT_DIR - rm -rf "${EGIT_DIR}" - mv "${EGIT_DIR}.bare" "${EGIT_DIR}" - eend ${returnstate} - elif [[ ! ${bare} && ! -d ${EGIT_DIR}/.git ]]; then - debug-print "${FUNCNAME}: converting \"${EGIT_DIR}\" to non-bare copy" - - ebegin "Converting \"${EGIT_DIR}\" from bare to non-bare copy" - git clone -l "${EGIT_DIR}" "${EGIT_DIR}.nonbare" > /dev/null - returnstate=$? - rm -rf "${EGIT_DIR}" - mv "${EGIT_DIR}.nonbare" "${EGIT_DIR}" - eend ${returnstate} - fi - fi - if [[ ${returnstate} -ne 0 ]]; then - debug-print "${FUNCNAME}: converting \"${EGIT_DIR}\" failed, removing to start from scratch" - - # migration failed, remove the EGIT_DIR to play it safe - einfo "Migration failed, removing \"${EGIT_DIR}\" to start from scratch." - rm -rf "${EGIT_DIR}" - fi - - # set various options to work with both targets - if [[ ${bare} ]]; then - debug-print "${FUNCNAME}: working in bare repository for \"${EGIT_DIR}\"" - EGIT_LOCAL_OPTIONS+="${EGIT_OPTIONS} --bare" - MOVE_COMMAND="git clone -l -s -n ${EGIT_DIR// /\\ }" - EGIT_UPDATE_CMD="git fetch -t -f -u origin ${EGIT_BRANCH}:${EGIT_BRANCH}" - UPSTREAM_BRANCH="${EGIT_BRANCH}" - EGIT_LOCAL_NONBARE= - else - debug-print "${FUNCNAME}: working in bare repository for non-bare \"${EGIT_DIR}\"" - MOVE_COMMAND="cp -pPR ." - EGIT_LOCAL_OPTIONS="${EGIT_OPTIONS}" - EGIT_UPDATE_CMD="git pull -f ${EGIT_OPTIONS}" - UPSTREAM_BRANCH="origin/${EGIT_BRANCH}" - EGIT_LOCAL_NONBARE="true" - fi -} - -# @FUNCTION: git-2_cleanup -# @INTERNAL -# @DESCRIPTION: -# Internal function cleaning up all the global variables -# that are not required after the unpack has been done. -git-2_cleanup() { - debug-print-function ${FUNCNAME} "$@" - - # Here we can unset only variables that are GLOBAL - # defined by the eclass, BUT NOT subject to change - # by user (like EGIT_PROJECT). - # If ebuild writer polutes his environment it is - # his problem only. - unset EGIT_DIR - unset MOVE_COMMAND - unset EGIT_LOCAL_OPTIONS - unset EGIT_UPDATE_CMD - unset UPSTREAM_BRANCH - unset EGIT_LOCAL_NONBARE -} - -# @FUNCTION: git-2_src_unpack -# @DESCRIPTION: -# Default git src_unpack function. -git-2_src_unpack() { - debug-print-function ${FUNCNAME} "$@" - - git-2_init_variables - git-2_prepare_storedir - git-2_migrate_repository - git-2_fetch "$@" - git-2_gc - git-2_submodules - git-2_move_source - git-2_branch - git-2_bootstrap - git-2_cleanup - echo ">>> Unpacked to ${EGIT_SOURCEDIR}" - - # Users can specify some SRC_URI and we should - # unpack the files too. - if [[ ! ${EGIT_NOUNPACK} ]]; then - if has ${EAPI:-0} 0 1; then - [[ ${A} ]] && unpack ${A} - else - default_src_unpack - fi - fi -} diff --git a/eclass/trinity-base.eclass b/eclass/trinity-base.eclass index ff116ba9..b4e4b2a4 100644 --- a/eclass/trinity-base.eclass +++ b/eclass/trinity-base.eclass @@ -4,28 +4,25 @@ # # Original Author: fat-zer -# Purpose: support planty of ebuilds for trinity project (a kde3 fork). +# Purpose: support ebuilds for the trinity project (a kde3 fork). # RESTRICT=network-sandbox -inherit trinity-functions cmake-utils base +inherit trinity-functions cmake-utils -# FIXME we don't need to write to both -addwrite "/usr/qt/3/etc/settings" -addpredict "/usr/qt/3/etc/settings" addwrite "/usr/tqt3/etc/settings" addpredict "/usr/tqt3/etc/settings" -# ban EAPI 0, 1 and 2 +# ban EAPI 0-6 case $EAPI in - 0|1|2|3|4) die "EAPI=${EAPI} is not supported" ;; - 5) ;; + 0|1|2|3|4|5|6) die "EAPI=${EAPI} is not supported" ;; + 7) ;; *) die "Unknown EAPI=${EAPI}" esac # @ECLASS-VARIABLE: BUILD_TYPE # @DESCRIPTION: -# Determins he build type: live or release +# Determines the build type: live or release if [[ ${PV} = *9999* ]]; then BUILD_TYPE="live" else @@ -41,8 +38,7 @@ echo "${TRINITY_MODULE_NAME:=${PN}}" >/dev/null # @ECLASS-VARIABLE: TRINITY_SCM # @DESCRIPTION: -# Determins from what version control system code is chiking out for live -# ebuilds. +# Determines which version control system code is checking out live ebuilds from. # @ECLASS-VARIABLE: TMP_DOCDIR # @DESCRIPTION: @@ -50,8 +46,8 @@ echo "${TRINITY_MODULE_NAME:=${PN}}" >/dev/null # # @ECLASS-VARIABLE: TRINTY_BASE_NO_INSTALL_DOC # @DESCRIPTION: -# if setted to anything except "no" this variable prevents -# trinity-base_src_install() to install documentation +# if set to anything except "no" this variable prevents +# trinity-base_src_install() from installing documentation # # @ECLASS-VARIABLE: TRINTY_LANGS @@ -59,8 +55,7 @@ echo "${TRINITY_MODULE_NAME:=${PN}}" >/dev/null # This is a whitespace-separated list of translations this ebuild supports. # These translations are automatically added to IUSE. Therefore ebuilds must set # this variable before inheriting any eclasses. To enable only selected -# translations, ebuilds must call enable_selected_linguas(). kde4-{base,meta}.eclass does -# this for you. +# translations, ebuilds must call enable_selected_linguas(). # @ECLASS-VARIABLE: TRINTY_DOC_LANGS # @DESCRIPTION: @@ -75,7 +70,7 @@ echo "${TRINITY_MODULE_NAME:=${PN}}" >/dev/null # Set to enable handbook in application. Possible values are 'always', 'optional' # (handbook USE flag) and 'never'. # This variable must be set before inheriting any eclasses. Defaults to 'never'. -# As well It ensures buildtime and runtime dependencies. +# Also ensures buildtime and runtime dependencies are met. TRINITY_HANDBOOK="${TRINITY_HANDBOOK:-never}" # @ECLASS-VARIABLE: TRINITY_EXTRAGEAR_PACKAGING @@ -87,8 +82,8 @@ TRINITY_HANDBOOK="${TRINITY_HANDBOOK:-never}" # @ECLASS-VARIABLE: TRINITY_GIT_MIRROR # @DESCRIPTION: -# User (or ebuild) can decide another git mirror if it's needed; -# Defaults to http://scm.trinitydesktop.org/scm/git +# User (or ebuild) can select another git mirror if it's needed; +# Defaults to https://mirror.git.trinitydesktop.org/gitea/TDE/ # @ECLASS-VARIABLE: TRINITY_GIT_BRANCH # @DESCRIPTION: @@ -96,7 +91,7 @@ TRINITY_HANDBOOK="${TRINITY_HANDBOOK:-never}" # @ECLASS-VARIABLE: TRINITY_COMMON_DOCS # @DESCRIPTION: -# Common doc names that was found in trinity project's dirs. +# Common doc names that were found in trinity project's dirs. TRINITY_COMMON_DOCS="AUTHORS BUGS CHANGELOG CHANGES COMMENTS COMPLIANCE COMPILING CONFIG_FORMAT CONFIGURING COPYING COPYRIGHT CREDITS DEBUG DESIGN FAQ HACKING HISTORY HOWTO IDEAS INSTALL LICENSE MAINTAINERS NAMING NEWS @@ -110,8 +105,7 @@ TRINITY_COMMON_DOCS="AUTHORS BUGS CHANGELOG CHANGES COMMENTS COMPLIANCE COMPILIN # @ECLASS-VARIABLE: TRINITY_BASE_SRC_URI # @DESCRIPTION: # The top SRC_URI for all trinity packages -TRINITY_BASE_SRC_URI="http://www.mirrorservice.org/sites/trinitydesktop.org/trinity/releases/" -# TRINITY_BASE_SRC_URI="http://trinity.blackmag.net/releases" # the old one +TRINITY_BASE_SRC_URI="http://www.mirrorservice.org/sites/trinitydesktop.org/trinity/releases" #reset TRINITY_SCM and inherit proper eclass if [[ ${BUILD_TYPE} = live ]]; then @@ -119,40 +113,27 @@ if [[ ${BUILD_TYPE} = live ]]; then [[ -z "$TRINITY_SCM" ]] && TRINITY_SCM=git case ${TRINITY_SCM} in - git) inherit git-2 ;; + git) inherit git-r3 ;; *) die "Unsupported TRINITY_SCM=${TRINITY_SCM}" ;; esac - #set some varyables - case ${TRINITY_SCM} in - git) - EGIT_REPO_URI="${TRINITY_GIT_MIRROR:=https://mirror.git.trinitydesktop.org/gitea/TDE}/${TRINITY_MODULE_NAME}" - EGIT_BRANCH="${TRINITY_GIT_BRANCH:=master}" - EGIT_PROJECT="trinity/${TRINITY_MODULE_NAME}" - EGIT_HAS_SUBMODULES="yes" - ;; - esac - S="${WORKDIR}/${TRINITY_MODULE_NAME}" + #set some variables + EGIT_REPO_URI="${TRINITY_GIT_MIRROR:=https://mirror.git.trinitydesktop.org/gitea/TDE/${TRINITY_MODULE_NAME}}" + EGIT_BRANCH="${TRINITY_GIT_BRANCH:=master}" + +# S="${WORKDIR}/${TRINITY_MODULE_NAME}" elif [[ "${BUILD_TYPE}" == release ]]; then mod_name="${TRINITY_MODULE_NAME}" mod_ver="${TRINITY_MODULE_VER:=${PV}}" - - case ${mod_ver} in - 3.5.13.1) - full_mod_name="${mod_name}-${mod_ver}" - TRINITY_TARBALL="${full_mod_name}.tar.gz" ;; - 3.5.13.2) - full_mod_name="${mod_name}-trinity-${mod_ver}" - TRINITY_TARBALL="${full_mod_name}.tar.xz" ;; - *) - full_mod_name="${mod_name}-${mod_ver}" - TRINITY_TARBALL="${full_mod_name}.tar.xz" - esac + + #Note: Only releases in the 14.0 series are presently supported. + full_mod_name="${mod_name}-trinity-${mod_ver}" + TRINITY_TARBALL="${full_mod_name}.tar.xz" if [[ -n "${TRINITY_MODULE_TYPE}" ]] ; then - SRC_URI="${TRINITY_BASE_SRC_URI}/${mod_ver}/${TRINITY_MODULE_TYPE}/$TRINITY_TARBALL" + SRC_URI="${TRINITY_BASE_SRC_URI}/R${mod_ver}/main/${TRINITY_MODULE_TYPE}/$TRINITY_TARBALL" else - SRC_URI="${TRINITY_BASE_SRC_URI}/${mod_ver}/$TRINITY_TARBALL" + SRC_URI="${TRINITY_BASE_SRC_URI}/R${mod_ver}/main/$TRINITY_TARBALL" fi S="${WORKDIR}/${full_mod_name}" @@ -197,16 +178,10 @@ fi # @FUNCTION: trinity-base_src_unpack # @DESCRIPTION: -# A default src unpack function to be call git-2_src_unpack either +# A default src unpack function to be call git-v3_src_unpack either trinity-base_src_unpack() { if [[ ${BUILD_TYPE} = live ]]; then - case "${TRINITY_SCM}" in - - git) - git-2_src_unpack - ;; - *) die "TRINITY_SCM: ${TRINITY_SCM} is not supported by ${FUNCNAME}" ;; - esac + git-v3_src_unpack else base_src_unpack fi @@ -219,27 +194,17 @@ trinity-base_src_unpack() { trinity-base_src_prepare() { debug-print-function ${FUNCNAME} "$@" -# # Only enable selected languages, used for KDE extragear apps. -# if [[ -n ${KDE_LINGUAS} ]]; then -# enable_selected_linguas -# fi local dir lang - # SCM bootstrap - if [[ ${BUILD_TYPE} = live ]]; then - case ${TRINITY_SCM} in - svn) subversion_src_prepare ;; - git) ;; - *) die "TRINITY_SCM: ${TRINITY_SCM} is not supported by ${FUNCNAME}" - esac - fi + # SCM bootstrap--removed on the grounds that if you got this far, + # you have to be using git # Apply patches - base_src_prepare + eapply_user - # Handle documentation and translations for extragear packages + # Handle documentation and translations for extragear packages if [[ -n "$TRINITY_EXTRAGEAR_PACKAGING" ]]; then - # remove not selected languages + # remove languages that have not been selected if [[ -n $TRINITY_LANGS ]]; then einfo "Removing unselected translations from ${TEG_PO_DIR}" for dir in $(find ${TEG_PO_DIR} -mindepth 1 -maxdepth 1 -type d ); do @@ -273,12 +238,14 @@ trinity-base_src_prepare() { done fi fi + + cmake-utils_src_prepare } # @FUNCTION: trinity-base_src_configure # @DESCRIPTION: -# Call standart cmake-utils_src_onfigure and add some common arguments. +# Call standard cmake-utils_src_onfigure and add some common arguments. trinity-base_src_configure() { debug-print-function ${FUNCNAME} "$@" local eg_cmakeargs @@ -302,10 +269,12 @@ trinity-base_src_configure() { mycmakeargs=( -DCMAKE_INSTALL_PREFIX="${EPREFIX}${TDEDIR}" -DCMAKE_INSTALL_RPATH="${EPREFIX}${TDEDIR}" - $([[ "${TRINITY_NEED_ARTS}" == "optional" ]] && cmake-utils_use_with arts ARTS) "${eg_cmakeargs[@]}" "${mycmakeargs[@]}" ) + +# $([[ "${TRINITY_NEED_ARTS}" == "optional" ]] && (cmake-utils_use_with arts ARTS)) + cmake-utils_src_configure } @@ -363,15 +332,6 @@ trinity-base_create_tmp_docfiles() { done done -# if [[ "${TRINITY_INSTALL_ROOT_DOCS}" == "yes" && " ${srcdirs} " == "* ./ *" ]]; then -# for doc in ${TRINITY_COMMON_DOCS}; do -# for docfile in $(ls ./"*${doc}*"); do -# targetdoc="${docfile//\//.}" -# targetdoc="${targetdoc#..}" -# cp "${docfile}" "$TMP_DOCDIR/${targetdoc}" -# done -# done -# fi } # @FUNCTION: trinity-base_install_docfiles @@ -393,48 +353,48 @@ trinity-base_install_docfiles() { } # @FUNCTION: trinity-base_fix_desktop_files -# @DESCRIPTION: +# @DESCRIPTION: OBSOLETE?????? # Perform desktop files modifications according to current version. You can pass # either desktop files or direcories to the parametrs. In case you'd pass a # directory the function will recursively search for all desktop files and # modify them. If no argument specified the function assume to work on the ${D}; -trinity-base_fix_desktop_files() { - - # Test if we have to perform any file fixing for current version - case "3.5" in - *${TRINITY_VER}*);; - *) return 0 ;; - esac +#trinity-base_fix_desktop_files() { - local file_list dir_list f - - if [ "$#" != 0 ]; then - # Get directories and files from arguments - for f in $@; do - if [ -f "$f" ]; then - file_list+=" $f" - elif [ -d "$f" ]; then - dir_list+=" $f" - else - eerror "${FUNCNAME}: bad argument type: $(stat -c %F "$f")" - fi - done - else - dir_list="${D}" - fi - - # Recursivly search for desktop files in directories - for f in $dir_list; do - file_list+="$(find ${f} -type f -name '*.desktop')" - done - - # Performe the updates - case "${TRINITY_VER}" in - 3.5) - for f in $file_list; do - sed -i '/^OnlyShowIn=/s/KDE/TDE/g' "$f" - done;; - esac -} +# # Test if we have to perform any file fixing for current version +# case "3.5" in +# *${TRINITY_VER}*);; +# *) return 0 ;; +# esac +# +# local file_list dir_list f +# +# if [ "$#" != 0 ]; then +# # Get directories and files from arguments +# for f in $@; do +# if [ -f "$f" ]; then +# file_list+=" $f" +# elif [ -d "$f" ]; then +# dir_list+=" $f" +# else +# eerror "${FUNCNAME}: bad argument type: $(stat -c %F "$f")" +# fi +# done +# else +# dir_list="${D}" +# fi +# +# # Recursivly search for desktop files in directories +# for f in $dir_list; do +# file_list+="$(find ${f} -type f -name '*.desktop')" +# done +# +# # Performe the updates +# case "${TRINITY_VER}" in +# 3.5) +# for f in $file_list; do +# sed -i '/^OnlyShowIn=/s/KDE/TDE/g' "$f" +# done;; +# esac +#} EXPORT_FUNCTIONS src_configure src_compile src_install src_prepare diff --git a/eclass/trinity-functions.eclass b/eclass/trinity-functions.eclass index 6e15321d..ae904157 100644 --- a/eclass/trinity-functions.eclass +++ b/eclass/trinity-functions.eclass @@ -7,9 +7,9 @@ # Purpose: basic trinity functions and variables # -inherit versionator multilib +inherit multilib -TRINITY_LIVEVER="14.0.0" +TRINITY_LIVEVER="14.1.0" # @FUNCTION: set-trinityver # @USAGE: < version > @@ -21,16 +21,10 @@ set-trinityver() { # set install location: # - 3rd party apps go into /usr, and have SLOT="0". - # - kde-base category ebuilds go into /usr/kde/$MAJORVER.$MINORVER, + # - kde-base category ebuilds go into /usr/trinity/$ETRINITY_VER, # and have SLOT="$MAJORVER.$MINORVER". - # - This function exports $PREFIX (location to install to) and $KDEDIR + # - This function exports $PREFIX (location to install to) and $TDEDIR # (location of kdelibs to link against) for all ebuilds. - # - # -- Overrides - deprecated but working for now: -- - # - If $KDEPREFIX is defined (in the profile or env), it overrides everything - # and both base and 3rd party kde stuff goes in there. - # - If $KDELIBSDIR is defined, the kdelibs installed in that location will be - # used, even by kde-base packages. # get version elements if [[ -n "$1" ]]; then @@ -40,28 +34,20 @@ set-trinityver() { fi case "$ETRINITY_VER" in - 3.* ) - export TRINITY_VER="$(get_version_component_range 1-2 "${ETRINITY_VER}")" ;; 9999 ) - export TRINITY_VER="$(get_major_version "$TRINITY_LIVEVER" )" ;; + export TRINITY_VER="$(ver_cut 1 "$TRINITY_LIVEVER" )" ;; * ) - export TRINITY_VER="$(get_major_version "$ETRINITY_VER" )" ;; + export TRINITY_VER="$(ver_cut 1 "$ETRINITY_VER" )" ;; esac export TDEDIR="/usr/trinity/${TRINITY_VER}" export TDEDIRS="/usr/trinity/${TRINITY_VER}" - # 3.5.x still uses KDE* variables - if [ "${TRINITY_VER}" = "3.5" ]; then - export KDEDIR="$TDEDIR" - export KDEDIRS="$TDEDIRS" - fi - - # this sould solve problems like "cannot find libraries" espessialy when - # compiling kdelibs - # NOTE: That can breaks compilation of tdelibs: - # binaries which runs during compilation are tring to load shared - # libraries from the TDE's directory wich may be broken. + # this sould solve problems like "cannot find libraries", especially when + # compiling tdelibs + # NOTE: binaries which run during compilation and try to load shared + # libraries from the TDE directory (which may be broken) may still + # break compilation of tdelibs(?) # TODO: fix that issue for tdelibs adjust-trinity-paths } @@ -101,7 +87,7 @@ adjust-trinity-paths() { export PATH export LD_LIBRARY_PATH - # Unset home paths so aplications wouldn't try to write to root's dir while build + # Unset home paths so applications wouldn't try to write to root's dir while building unset TDEHOME unset TDEROOTHOME } @@ -141,12 +127,7 @@ need-trinity() { set-trinityver $1 adjust-trinity-paths - case "$1" in - 3.5*) - my_depend=">=trinity-base/kdelibs-${ETRINITY_VER}:3.5";; - *) - my_depend=">=trinity-base/tdelibs-${ETRINITY_VER}:${TRINITY_VER}";; - esac + my_depend=">=trinity-base/tdelibs-${ETRINITY_VER}:${TRINITY_VER}" DEPEND="$DEPEND $my_depend" RDEPEND="$RDEPEND $my_depend" @@ -154,14 +135,14 @@ need-trinity() { # @ECLASS-VARIABLE: TRINITY_NEED_ARTS # @DESCRIPTION: -# This variable is setted by need-arts function. Possible arguments values 'yes', 'no' and 'optional' +# This variable is set by the need-arts function. Possible arguments values 'yes', 'no' and 'optional' # Default is 'no' TRINITY_NEED_ARTS="no" # @FUNCTION: need-arts # @USAGE: need-arts <yes|optional> # @DESCRIPTION: -# This function adds DEPEND's for aRTs-support Possible arguments are 'yes' and 'optinal' +# This function adds DEPENDs for aRTs support. Possible arguments are 'yes' and 'optinal' # 'yes' means arts is required, optional' results in USE flag arts. # NOTE: this function modifies IUSE DEPEND and RDEPEND variables, so if you call it before setting # those variables don't forget to include the priviously setted value into them. @@ -175,8 +156,7 @@ need-arts() { TRINITY_NEED_ARTS=$1; case "${TRINITY_VER}" in - "") die "You must call set-trinityver unctions to set TRINITY_VER before calling $FUNCNAME.";; - 3.5*) tdelibs="trinity-base/kdelibs";; + "") die "You must call set-trinityver functions to set TRINITY_VER before calling $FUNCNAME.";; *) tdelibs="trinity-base/tdelibs";; esac diff --git a/eclass/trinity-meta.eclass b/eclass/trinity-meta.eclass index b6ddb073..87f3b773 100644 --- a/eclass/trinity-meta.eclass +++ b/eclass/trinity-meta.eclass @@ -16,17 +16,13 @@ HOMEPAGE="http://www.trinitydesktop.org/" set-trinityver [[ -z "$SLOT" ]] && SLOT="$TRINITY_VER" -if [[ "$TRINITY_VER" == "3.5" ]]; then # common dependencies - DEPEND="trinity-base/kdelibs:${SLOT}" -else - DEPEND="trinity-base/tdelibs:${SLOT}" -fi +DEPEND="trinity-base/tdelibs:${SLOT}" # @FUNCTION: trinity-meta_set_trinity_submodule # @DESCRIPTION: -# sets the TRINITY_SUBMODULE variable to vth value aptained from ${PN} -# if it doesn't set yet +# sets the TRINITY_SUBMODULE variable to nth value obtained from ${PN} +# if it isn't set yet trinity-meta_set_trinity_submodule() { debug-print-function $FUNCNAME "$@" @@ -49,18 +45,12 @@ trinity-meta_pkg_setup() { # @FUNCTION: trinity-meta_src_unpack # @DESCRIPTION: # Default source extract function. It tries to unpack only -# nessecary files. +# necessary files. trinity-meta_src_unpack() { debug-print-function ${FUNCNAME} "$@" if [[ ${BUILD_TYPE} = live ]]; then case "${TRINITY_SCM}" in - svn) - mkdir -p "$S" - ESVN_RESTRICT="export" subversion_src_unpack - subversion_wc_info - subversion_bootstrap - ;; git) git-2_src_unpack ;; @@ -82,8 +72,7 @@ trinity-meta_src_extract() { if [[ "${BUILD_TYPE}" = live ]]; then einfo "Exporting parts of working copy to ${S}" case "$TRINITY_SCM" in - svn) trinity-meta_rsync_copy ;; - git) # we nothing can do to prevent git from unpacking code + git) # nothing we can do to prevent git from unpacking code ;; *) die "TRINITY_SCM: ${TRINITY_SCM} is not supported by ${FUNCNAME}" esac @@ -127,7 +116,6 @@ trinity-meta_rsync_copy() { local rsync_options subdir targetdir wc_path escm case "${TRINITY_SCM}" in - svn) wc_path="${ESVN_WC_PATH}";; git) wc_path="${EGIT_STORE_DIR}/${EGIT_PROJECT}";; *) die "TRINITY_SCM: ${TRINITY_SCM} is not supported by ${FUNCNAME}" ;; esac @@ -167,10 +155,8 @@ trinity-meta_create_extractlists() { # add package-specific files and directories case "${TRINITY_MODULE_NAME}" in - kdebase) TSM_EXTRACT_LIST+=" kcontrol/ kdmlib/" ;; tdebase) TSM_EXTRACT_LIST+=" kcontrol/" ;; - *) ;; # nothing special for over modules -# *) die "TRINITY_MODULE_NAME ${TRINITY_MODULE_NAME} is not supported by function ${FUNCNAME}" ;; + *) ;; # nothing special for other modules esac TSM_EXTRACT_LIST+=" ${TSM_EXTRACT} ${TSM_EXTRACT_ALSO} cmake/ CMakeLists.txt" @@ -205,13 +191,6 @@ trinity-meta_src_prepare() { done; fi -# fix bad cmake code fo 3.5.13.1 - if [ $PV == "3.5.13.1" ]; then - [ -f "cmake/modules/FindTDE.cmake" ] && \ - sed -ie 's!HINTS\s\+${\w*BIN\w*}!HINTS "${TDE_PREFIX}/bin" ${BIN_INSTALL_DIR}!' \ - cmake/modules/FindTDE.cmake - fi - trinity-base_src_prepare } diff --git a/trinity-base/tdelibs/tdelibs-14.0.6.ebuild b/trinity-base/tdelibs/tdelibs-14.0.6.ebuild new file mode 100644 index 00000000..9b93b211 --- /dev/null +++ b/trinity-base/tdelibs/tdelibs-14.0.6.ebuild @@ -0,0 +1,141 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ +EAPI="7" +TRINITY_MODULE_NAME="$PN" + +inherit trinity-base multilib + +set-trinityver + +need-arts optional + +DESCRIPTION="Trinity libraries needed by all TDE programs." +HOMEPAGE="http://www.trinitydesktop.org/" +LICENSE="GPL-2 LGPL-2" +SLOT="${TRINITY_VER}" +KEYWORDS="~amd64" +IUSE+=" alsa avahi cups consolekit fam jpeg2k lua lzma networkmanager openexr + spell sudo tiff utempter upower udisks old_udisks xcomposite +xrandr" + +MY_DEPEND="=dev-tqt/tqtinterface-${PV} + >=dev-libs/libxslt-1.1.16 + >=dev-libs/libxml2-2.6.6 + >=dev-libs/libpcre-6.6 + net-dns/libidn + app-text/ghostscript-gpl + >=dev-libs/openssl-0.9.7d:= + media-libs/fontconfig + media-libs/freetype:2 + media-libs/libart_lgpl + sys-apps/dbus + dev-libs/dbus-1-tqt + x11-libs/libXcursor + x11-libs/libXrender + alsa? ( media-libs/alsa-lib ) + avahi? ( net-dns/avahi ) + cups? ( >=net-print/cups-1.1.19 ) + fam? ( virtual/fam ) + jpeg2k? ( media-libs/jasper ) + lua? ( dev-lang/lua:* ) + openexr? ( >=media-libs/openexr-1.2.2-r2 ) + spell? ( >=app-dicts/aspell-en-6.0.0 >=app-text/aspell-0.60.5 ) + sudo? ( app-admin/sudo ) + tiff? ( media-libs/tiff:= ) + utempter? ( sys-libs/libutempter ) + networkmanager? ( net-misc/networkmanager ) + lzma? ( app-arch/xz-utils ) + xrandr? ( >=x11-libs/libXrandr-1.2 ) + xcomposite? ( x11-libs/libXcomposite )" +# NOTE: upstream lacks avahi support, so the use flag is currenly masked +# TODO: add elfres support via libr (not in portage now) +DEPEND+=" ${MY_DEPEND}" +RDEPEND+=" ${MY_DEPEND} + consolekit? ( sys-auth/consolekit ) + upower? ( sys-power/upower ) + udisks? ( sys-fs/udisks:2 ) + old_udisks? ( sys-fs/udisks:0 )" + +src_configure() { + mycmakeargs=( + -DMALLOC_FULL=ON + -DWITH_LIBIDN=ON + -DWITH_SSL=ON + -DWITH_LIBART=ON + -DWITH_PCRE=ON + -DWITH_XCURSOR=ON + -DWITH_HSPELL=OFF + -DKDE4_DEFAULT_HOME=.kde4 + -DWITH_ARTS=OFF + -DWITH_ALSA="$(usex alsa)" + -DWITH_AVAHI="$(usex avahi)" + -DWITH_CUPS="$(usex cups)" + -DWITH_INOTIFY="$(usex kernel_linux)" + -DWITH_JASPER="$(usex jpeg2k)" + -DWITH_LUA="$(usex lua)" + -DWITH_LZMA="$(usex lzma)" + -DWITH_OPENEXR="$(usex openexr)" + -DWITH_ASPELL="$(usex spell)" + -DWITH_GAMIN="$(usex fam)" + -DWITH_TIFF="$(usex tiff)" + -DWITH_UTEMPTER="$(usex utempter)" + -DWITH_UPOWER="$(usex upower)" + -DWITH_UDISKS="$(usex old_udisks)" + -DWITH_UDISKS2="$(usex udisks)" + -DWITH_CONSOLEKIT="$(usex consolekit)" + -DWITH_NETWORK_MANAGER_BACKEND="$(usex networkmanager)" + -DWITH_XCOMPOSITE="$(usex xcomposite)" + -DWITH_XRANDR="$(usex xrandr)" + -DWITH_SUDO_TDESU_BACKEND="$(usex sudo)" + ) + + trinity-base_src_configure +} + +src_install() { + trinity-base_src_install + + dodir /etc/env.d + # KDE implies that the install path is listed first in TDEDIRS and the user + # directory (implicitly added) to be the last entry. Doing otherwise breaks + # certain functionality. Do not break this (once again *sigh*), but read the code. + # KDE saves the installed path implicitly and so this is not needed, /usr + # is set in ${TDEDIR}/share/config/kdeglobals and so TDEDIRS is not needed. + + # List all the multilib libdirs + local libdirs pkgconfigdirs + for libdir in $(get_all_libdirs); do + libdirs="${TDEDIR}/${libdir}:${libdirs}" + done + + cat <<EOF >"${D}/etc/env.d/45trinitypaths-${SLOT}" # number goes down with version upgrade +PATH=${TDEDIR}/bin +ROOTPATH=${TDEDIR}/sbin:${TDEDIR}/bin +LDPATH=${libdirs#:} +MANPATH=${TDEDIR}/share/man +CONFIG_PROTECT="${TDEDIR}/share/config ${TDEDIR}/env ${TDEDIR}/shutdown /usr/share/config" +XDG_DATA_DIRS="${TDEDIR}/share" +PKG_CONFIG_PATH="${TDEDIR}/$(get_libdir)/pkgconfig" +EOF + + # Make sure the target for the revdep-rebuild stuff exists. Fixes bug 184441. + dodir /etc/revdep-rebuild + +cat <<EOF >"${D}/etc/revdep-rebuild/50-trinity-${SLOT}" +SEARCH_DIRS="${TDEDIR}/bin ${TDEDIR}/lib*" +EOF + + trinity-base_create_tmp_docfiles + trinity-base_install_docfiles +} + +pkg_postinst () { + if use sudo; then + einfo "Remember that the sudo use flag sets only the default superuser command." + einfo "It can be overriden on a user-level by adding:" + einfo " [super-user-command]" + einfo " super-user-command=su" + einfo "to the kdeglobal config file which is should be usually" + einfo "located in the ~/.trinity/share/config/ directory." + fi +} diff --git a/trinity-base/tdelibs/tdelibs-9999.ebuild b/trinity-base/tdelibs/tdelibs-9999.ebuild index 1883c907..baf32b50 100644 --- a/trinity-base/tdelibs/tdelibs-9999.ebuild +++ b/trinity-base/tdelibs/tdelibs-9999.ebuild @@ -1,7 +1,7 @@ # Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI="5" +EAPI="7" TRINITY_MODULE_NAME="$PN" inherit trinity-base multilib @@ -18,7 +18,7 @@ KEYWORDS= IUSE+=" alsa avahi cups consolekit fam jpeg2k lua lzma networkmanager openexr spell sudo tiff utempter upower udisks old_udisks xcomposite +xrandr" -MY_DEPEND=">=dev-tqt/tqtinterface-${TRINITY_VER} +MY_DEPEND="=dev-tqt/tqtinterface-${PV} >=dev-libs/libxslt-1.1.16 >=dev-libs/libxml2-2.6.6 >=dev-libs/libpcre-6.6 @@ -66,26 +66,28 @@ src_configure() { -DWITH_XCURSOR=ON -DWITH_HSPELL=OFF -DKDE4_DEFAULT_HOME=.kde4 - $(cmake-utils_use_with alsa ALSA) - $(cmake-utils_use_with avahi AVAHI) - $(cmake-utils_use_with cups CUPS) - $(cmake-utils_use_with kernel_linux INOTIFY) - $(cmake-utils_use_with jpeg2k JASPER) - $(cmake-utils_use_with lua LUA) - $(cmake-utils_use_with lzma LZMA) - $(cmake-utils_use_with openexr OPENEXR) - $(cmake-utils_use_with spell ASPELL) - $(cmake-utils_use_with fam GAMIN) - $(cmake-utils_use_with tiff TIFF) - $(cmake-utils_use_with utempter UTEMPTER) - $(cmake-utils_use_with upower UPOWER) - $(cmake-utils_use_with old_udisks UDISKS) - $(cmake-utils_use_with udisks UDISKS2) - $(cmake-utils_use_with consolekit CONSOLEKIT) - $(cmake-utils_use_with networkmanager WITH_NETWORK_MANAGER_BACKEND) - $(cmake-utils_use_with xcomposite XCOMPOSITE) - $(cmake-utils_use_with xrandr XRANDR) - $(cmake-utils_use_with sudo SUDO_KDESU_BACKEND) + -DWITH_TDEHWLIB=OFF + -DWITH_ARTS=OFF + -DWITH_ALSA="$(usex alsa)" + -DWITH_AVAHI="$(usex avahi)" + -DWITH_CUPS="$(usex cups)" + -DWITH_INOTIFY="$(usex kernel_linux)" + -DWITH_JASPER="$(usex jpeg2k)" + -DWITH_LUA="$(usex lua)" + -DWITH_LZMA="$(usex lzma)" + -DWITH_OPENEXR="$(usex openexr)" + -DWITH_ASPELL="$(usex spell)" + -DWITH_GAMIN="$(usex fam)" + -DWITH_TIFF="$(usex tiff)" + -DWITH_UTEMPTER="$(usex utempter)" + -DWITH_UPOWER="$(usex upower)" + -DWITH_UDISKS="$(usex old_udisks)" + -DWITH_UDISKS2="$(usex udisks)" + -DWITH_CONSOLEKIT="$(usex consolekit)" + -DWITH_NETWORK_MANAGER_BACKEND="$(usex networkmanager)" + -DWITH_XCOMPOSITE="$(usex xcomposite)" + -DWITH_XRANDR="$(usex xrandr)" + -DWITH_SUDO_TDESU_BACKEND="$(usex sudo)" ) trinity-base_src_configure @@ -113,9 +115,6 @@ ROOTPATH=${TDEDIR}/sbin:${TDEDIR}/bin LDPATH=${libdirs#:} MANPATH=${TDEDIR}/share/man CONFIG_PROTECT="${TDEDIR}/share/config ${TDEDIR}/env ${TDEDIR}/shutdown /usr/share/config" -#TDE_IS_PRELINKED=1 -# Excessive flushing to disk as in releases before KDE 3.5.10. Usually you don't want that. -#TDE_EXTRA_FSYNC=1 XDG_DATA_DIRS="${TDEDIR}/share" PKG_CONFIG_PATH="${TDEDIR}/$(get_libdir)/pkgconfig" EOF @@ -133,11 +132,11 @@ EOF pkg_postinst () { if use sudo; then - einfo "Remember sudo use flag sets only the defauld value" + einfo "Remember that the sudo use flag sets only the default superuser command." einfo "It can be overriden on a user-level by adding:" einfo " [super-user-command]" einfo " super-user-command=su" - einfo "To the kdeglobal config file which is should be usually" + einfo "to the kdeglobal config file which is should be usually" einfo "located in the ~/.trinity/share/config/ directory." fi } |