/[gentoo-x86]/eclass/eutils.eclass
Gentoo

Diff of /eclass/eutils.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.142 Revision 1.143
1# Copyright 1999-2004 Gentoo Foundation 1# Copyright 1999-2004 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/eutils.eclass,v 1.142 2005/01/23 20:47:42 eradicator Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/eutils.eclass,v 1.143 2005/01/26 16:19:12 ka0ttic Exp $
4# 4#
5# Author: Martin Schlemmer <azarah@gentoo.org> 5# Author: Martin Schlemmer <azarah@gentoo.org>
6# 6#
7# This eclass is for general purpose functions that most ebuilds 7# This eclass is for general purpose functions that most ebuilds
8# have to implement themselves. 8# have to implement themselves.
1558 einfo "After doing that, you can safely remove ${LIB}" 1558 einfo "After doing that, you can safely remove ${LIB}"
1559 einfo "Note: 'emerge gentoolkit' to get revdep-rebuild" 1559 einfo "Note: 'emerge gentoolkit' to get revdep-rebuild"
1560 fi 1560 fi
1561} 1561}
1562 1562
1563# Hack for people to figure out if a package was built with 1563# Hack for people to figure out if a package was built with
1564# certain USE flags 1564# certain USE flags
1565# 1565#
1566# Usage: built_with_use [-a|-o] <DEPEND ATOM> <List of USE flags> 1566# Usage: built_with_use [-a|-o] <DEPEND ATOM> <List of USE flags>
1567# ex: built_with_use xchat gtk2 1567# ex: built_with_use xchat gtk2
1568# 1568#
1589 shift 1589 shift
1590 done 1590 done
1591 [[ ${opt} = "-a" ]] 1591 [[ ${opt} = "-a" ]]
1592} 1592}
1593 1593
1594# Many configure scripts wrongly bail when a C++ compiler 1594# Many configure scripts wrongly bail when a C++ compiler
1595# could not be detected. #73450 1595# could not be detected. #73450
1596epunt_cxx() { 1596epunt_cxx() {
1597 local dir=$1 1597 local dir=$1
1598 [[ -z ${dir} ]] && dir=${S} 1598 [[ -z ${dir} ]] && dir=${S}
1599 ebegin "Removing useless C++ checks" 1599 ebegin "Removing useless C++ checks"
1601 for f in $(find ${dir} -name configure) ; do 1601 for f in $(find ${dir} -name configure) ; do
1602 patch -p0 "${f}" "${PORTDIR}/eclass/ELT-patches/nocxx/nocxx.patch" > /dev/null 1602 patch -p0 "${f}" "${PORTDIR}/eclass/ELT-patches/nocxx/nocxx.patch" > /dev/null
1603 done 1603 done
1604 eend 0 1604 eend 0
1605} 1605}
1606
1607# dopamd [ file ] [ new file ]
1608#
1609# Install pam auth config file in /etc/pam.d
1610#
1611# The first argument, 'file' is required. Install as 'new file', if
1612# specified.
1613
1614dopamd() {
1615 local pamd="$1" newpamd="${2:-$1}"
1616 [[ -z "$1" ]] && die "dopamd requires at least one argument."
1617
1618 use pam || return 0
1619
1620 insinto /etc/pam.d
1621 # these are the default doins options, but be explicit just in case
1622 insopts -m 0644 -o root -g root
1623 newins ${pamd} ${newpamd} || die "failed to install ${newpamd}"
1624}

Legend:
Removed from v.1.142  
changed lines
  Added in v.1.143

  ViewVC Help
Powered by ViewVC 1.1.20