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

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

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

Revision 1.10 Revision 1.11
3# Copyright (c) 2004-2005, Thomas Matthijs <axxo@gentoo.org> 3# Copyright (c) 2004-2005, Thomas Matthijs <axxo@gentoo.org>
4# Copyright (c) 2004-2005, Gentoo Foundation 4# Copyright (c) 2004-2005, Gentoo Foundation
5# 5#
6# Licensed under the GNU General Public License, v2 6# Licensed under the GNU General Public License, v2
7# 7#
8# $Header: /var/cvsroot/gentoo-x86/eclass/java-pkg-2.eclass,v 1.10 2007/01/10 09:59:21 betelgeuse Exp $ 8# $Header: /var/cvsroot/gentoo-x86/eclass/java-pkg-2.eclass,v 1.11 2007/01/12 13:48:12 betelgeuse Exp $
9 9
10inherit java-utils-2 10inherit java-utils-2
11 11
12# ----------------------------------------------------------------------------- 12# -----------------------------------------------------------------------------
13# @eclass-begin 13# @eclass-begin
54# EANT_FILTER_COMPILER - Calls java-pkg_filter-compiler with the value 54# EANT_FILTER_COMPILER - Calls java-pkg_filter-compiler with the value
55# EANT_BUILD_TARGET - the ant target/targets to execute (default: jar) 55# EANT_BUILD_TARGET - the ant target/targets to execute (default: jar)
56# EANT_DOC_TARGET - the target to build extra docs under the doc use flag 56# EANT_DOC_TARGET - the target to build extra docs under the doc use flag
57# (default: the one provided by use_doc in 57# (default: the one provided by use_doc in
58# java-utils-2.eclass) 58# java-utils-2.eclass)
59# EANT_GENTOO_CLASSPATH - class java-pkg_getjars for the value and adds to the
60# gentoo.classpath property
61# EANT_EXTRA_ARGUMENTS - extra arguments to pass to eant
59# ------------------------------------------------------------------------------ 62# ------------------------------------------------------------------------------
60java-pkg-2_src_compile() { 63java-pkg-2_src_compile() {
61 if [[ -e "${EANT_BUILD_XML:=build.xml}" ]]; then 64 if [[ -e "${EANT_BUILD_XML:=build.xml}" ]]; then
62 [[ "${EANT_FILTER_COMPILER}" ]] && \ 65 [[ "${EANT_FILTER_COMPILER}" ]] && \
63 java-pkg_filter-compiler ${EANT_FILTER_COMPILER} 66 java-pkg_filter-compiler ${EANT_FILTER_COMPILER}
64 67
65 local antflags="${EANT_BUILD_TARGET:=jar}" 68 local antflags="${EANT_BUILD_TARGET:=jar}"
69
70 local gcp="${EANT_GENTOO_CLASSPATH}"
71
72 if [[ "${gcp}" ]]; then
73 local cp="$(java-pkg_getjars ${gcp})"
74 # It seems ant does not like single quotes around ${cp}
75 antflags="${antflags} -Dgentoo.classpath=\"${cp}\""
76 fi
77
66 hasq doc ${IUSE} && antflags="${antflags} $(use_doc ${EANT_DOC_TARGET})" 78 hasq doc ${IUSE} && antflags="${antflags} $(use_doc ${EANT_DOC_TARGET})"
67 eant ${antflags} -f "${EANT_BUILD_XML}" 79 eant ${antflags} -f "${EANT_BUILD_XML}" ${EANT_EXTRA_ARGUMENTS}
68 else 80 else
69 echo "${FUNCNAME}: No build.xml found so nothing to do." 81 echo "${FUNCNAME}: No build.xml found so nothing to do."
70 fi 82 fi
71} 83}
72 84

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.11

  ViewVC Help
Powered by ViewVC 1.1.20