/[gentoo-x86]/eclass/java-utils-2.eclass
Gentoo

Diff of /eclass/java-utils-2.eclass

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

Revision 1.92 Revision 1.93
4# Copyright (c) 2004, Karl Trygve Kalleberg <karltk@gentoo.org> 4# Copyright (c) 2004, Karl Trygve Kalleberg <karltk@gentoo.org>
5# Copyright (c) 2004-2005, Gentoo Foundation 5# Copyright (c) 2004-2005, Gentoo Foundation
6# 6#
7# Licensed under the GNU General Public License, v2 7# Licensed under the GNU General Public License, v2
8# 8#
9# $Header: /var/cvsroot/gentoo-x86/eclass/java-utils-2.eclass,v 1.92 2007/08/05 08:17:05 betelgeuse Exp $ 9# $Header: /var/cvsroot/gentoo-x86/eclass/java-utils-2.eclass,v 1.93 2007/09/27 19:47:08 betelgeuse Exp $
10 10
11# ----------------------------------------------------------------------------- 11# -----------------------------------------------------------------------------
12# @eclass-begin 12# @eclass-begin
13# @eclass-shortdesc Java Utility eclass 13# @eclass-shortdesc Java Utility eclass
14# @eclass-maintainer java@gentoo.org 14# @eclass-maintainer java@gentoo.org
195# 195#
196# @example 196# @example
197# java-pkg_doexamples demo 197# java-pkg_doexamples demo
198# java-pkg_doexamples demo/* examples/* 198# java-pkg_doexamples demo/* examples/*
199# 199#
200# @param --subdir - If the examples need a certain directory structure
200# @param $* - list of files to install 201# @param $* - list of files to install
201# ------------------------------------------------------------------------------ 202# ------------------------------------------------------------------------------
202java-pkg_doexamples() { 203java-pkg_doexamples() {
203 debug-print-function ${FUNCNAME} $* 204 debug-print-function ${FUNCNAME} $*
204 205
205 [[ ${#} -lt 1 ]] && die "At least one argument needed" 206 [[ ${#} -lt 1 ]] && die "At least one argument needed"
206 207
207 java-pkg_check-phase install 208 java-pkg_check-phase install
208 209
209 local dest=/usr/share/doc/${PF}/examples 210 local dest=/usr/share/doc/${PF}/examples
211 if [[ ${1} == --subdir ]]; then
212 local dest=${dest}/${2}
213 dodir ${dest}
214 shift 2
215 fi
216
210 if [[ ${#} = 1 && -d ${1} ]]; then 217 if [[ ${#} = 1 && -d ${1} ]]; then
211 ( # dont want to pollute calling env 218 ( # dont want to pollute calling env
212 insinto "${dest}" 219 insinto "${dest}"
213 doins -r ${1}/* 220 doins -r ${1}/*
214 ) || die "Installing examples failed" 221 ) || die "Installing examples failed"

Legend:
Removed from v.1.92  
changed lines
  Added in v.1.93

  ViewVC Help
Powered by ViewVC 1.1.20