# Copyright 1999-2002 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # /space/gentoo/cvsroot/gentoo-x86/x11-misc/conectiva-crystal/conectiva-crystal-3.1_beta.ebuild,v 1.1 2002/05/18 10:06:55 verwilst Exp S="${WORKDIR}/Crystal" DESCRIPTION="Conectiva Crystal - Icon theme" SRC_URI="http://www.ibiblio.org/gentoo/distfiles/crystal-3.1_beta3.7.tar.gz" HOMEPAGE="http://www.conectiva.com.br" KEYWORDS="x86" SLOT="0" LICENSE="as-is" src_compile() { return 1; } src_install(){ successful="false"; # Success is defined as at least one installation of the icon theme. cd ${S} if [ "${KDE2DIR}" ] || [ "${KDE3DIR}" ]; then # At least one of the deprecated $KDExDIR variables is non-zero. Let's use it/them. if [ "${KDE2DIR}" ]; then # $KDE2DIR is non-zero. Use it. echo "Using KDE2DIR='${KDE2DIR}'." if [ -d "${KDE2DIR}" ] ; then # Directory $KDE2DIR exists. echo "Installing to ${KDE2DIR}. Be patient."; mkdir -p ${D}/${KDE2DIR}/share/icons/; cp -rf ${S} ${D}/${KDE2DIR}/share/icons/Crystal; successful="true"; else echo "Directory ${KDE2DIR} not found."; fi fi if [ "${KDE3DIR}" ]; then # $KDE3DIR is non-zero. Use it. echo "Using KDE3DIR='${KDE3DIR}'." if [ -d "${KDE3DIR}" ] ; then # Directory $KDE3DIR exists. echo "Installing to ${KDE3DIR}. Be patient."; mkdir -p ${D}/${KDE3DIR}/share/icons/; cp -rf ${S} ${D}/${KDE3DIR}/share/icons/Crystal; successful="true"; else echo "Directory ${KDE3DIR} not found."; fi fi elif [ "${KDEDIRS}" ]; then # The deprecated $KDExDIR variables are zero but $KDEDIRS is non-zero. Let's use the latter. echo "Using KDEDIRS='${KDEDIRS}'."; IFS=":"; # Word separator set to double point (Default: IFS=" \t\n") for kdebasedir in ${KDEDIRS}; do if [ -d "${kdebasedir}" ] ; then # Directory $kdebasedir exists. echo "Installing to ${kdebasedir}. Be patient."; mkdir -p ${D}/${kdebasedir}/share/icons/; cp -rf ${S} ${D}/${kdebasedir}/share/icons/Crystal; successful="true"; else echo "Directory ${kdebasedir} not found."; fi done else # Bad luck. $KDE2DIR and $KDE3DIR and $KDEDIRS are zero. Probably due to a bogus KDE setup. die "No KDE2DIR or KDE3DIR or KDEDIRS variable found. Please check your KDE setup and remerge. Aborting."; fi if [ "${successful}" == "false" ]; then die "No valid directories found. Please check your KDE2DIR/KDE3DIR/KDEDIRS variables and remerge. Aborting."; fi }