/[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.73 Revision 1.74
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.73 2007/04/20 14:38:49 betelgeuse Exp $ 9# $Header: /var/cvsroot/gentoo-x86/eclass/java-utils-2.eclass,v 1.74 2007/04/20 15:23:28 betelgeuse Exp $
10 10
11 11
12# ----------------------------------------------------------------------------- 12# -----------------------------------------------------------------------------
13# @eclass-begin 13# @eclass-begin
14# @eclass-shortdesc Java Utility eclass 14# @eclass-shortdesc Java Utility eclass
556# @example: 556# @example:
557# java-pkg_dojavadoc docs/api 557# java-pkg_dojavadoc docs/api
558# 558#
559# ------------------------------------------------------------------------------ 559# ------------------------------------------------------------------------------
560java-pkg_dojavadoc() { 560java-pkg_dojavadoc() {
561 debug-print-function ${FUNCNAME} $*
561 local dir="$1" 562 local dir="$1"
563
564 # QA checks
562 565
563 java-pkg_check-phase install 566 java-pkg_check-phase install
564 567
565 [[ -z "${dir}" ]] && die "Must specify a directory!" 568 [[ -z "${dir}" ]] && die "Must specify a directory!"
566 [[ ! -d "${dir}" ]] && die "${dir} does not exist, or isn't a directory!" 569 [[ ! -d "${dir}" ]] && die "${dir} does not exist, or isn't a directory!"
570 if [[ ! -e "${dir}/index.html" ]]; then
571 local msg="No index.html in javadoc directory"
572 ewarn "${msg}"
573 is-java-strict && die "${msg}"
574 fi
575
576 # Renaming to match our directory layout
567 577
568 local dir_to_install="${dir}" 578 local dir_to_install="${dir}"
569 if [[ "$(basename "${dir}")" != "api" ]]; then 579 if [[ "$(basename "${dir}")" != "api" ]]; then
570 dir_to_install="${T}/api" 580 dir_to_install="${T}/api"
571 # TODO use doins 581 # TODO use doins
572 cp -r "${dir}" "${dir_to_install}" || die "cp failed" 582 cp -r "${dir}" "${dir_to_install}" || die "cp failed"
573 fi 583 fi
584
585 # Actual installation
574 586
575 java-pkg_dohtml -r ${dir_to_install} 587 java-pkg_dohtml -r ${dir_to_install}
576} 588}
577 589
578# ------------------------------------------------------------------------------ 590# ------------------------------------------------------------------------------

Legend:
Removed from v.1.73  
changed lines
  Added in v.1.74

  ViewVC Help
Powered by ViewVC 1.1.20