summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetteri Räty <betelgeuse@gentoo.org>2007-09-27 19:47:08 +0000
committerPetteri Räty <betelgeuse@gentoo.org>2007-09-27 19:47:08 +0000
commite0b512784dfe9ca7af5509405b410345b3584e16 (patch)
tree232313ee20cfa5541d8291d4abfba5e6e87744cb
parentWorkaround digest mismatch between our mirrored tarball and upstream tarball ... (diff)
downloadgentoo-2-e0b512784dfe9ca7af5509405b410345b3584e16.tar.gz
gentoo-2-e0b512784dfe9ca7af5509405b410345b3584e16.tar.bz2
gentoo-2-e0b512784dfe9ca7af5509405b410345b3584e16.zip
Add --subdir option to java-pkg_doexamples.
-rw-r--r--eclass/java-utils-2.eclass9
1 files changed, 8 insertions, 1 deletions
diff --git a/eclass/java-utils-2.eclass b/eclass/java-utils-2.eclass
index 9b3606a950eb..25fb8e06dafe 100644
--- a/eclass/java-utils-2.eclass
+++ b/eclass/java-utils-2.eclass
@@ -6,7 +6,7 @@
#
# Licensed under the GNU General Public License, v2
#
-# $Header: /var/cvsroot/gentoo-x86/eclass/java-utils-2.eclass,v 1.92 2007/08/05 08:17:05 betelgeuse Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/java-utils-2.eclass,v 1.93 2007/09/27 19:47:08 betelgeuse Exp $
# -----------------------------------------------------------------------------
# @eclass-begin
@@ -197,6 +197,7 @@ JAVA_PKG_QA_VIOLATIONS=0
# java-pkg_doexamples demo
# java-pkg_doexamples demo/* examples/*
#
+# @param --subdir - If the examples need a certain directory structure
# @param $* - list of files to install
# ------------------------------------------------------------------------------
java-pkg_doexamples() {
@@ -207,6 +208,12 @@ java-pkg_doexamples() {
java-pkg_check-phase install
local dest=/usr/share/doc/${PF}/examples
+ if [[ ${1} == --subdir ]]; then
+ local dest=${dest}/${2}
+ dodir ${dest}
+ shift 2
+ fi
+
if [[ ${#} = 1 && -d ${1} ]]; then
( # dont want to pollute calling env
insinto "${dest}"