1 |
> Instead, echo the command we are about to run. |
2 |
> |
3 |
> Closes: https://bugs.gentoo.org/838475 |
4 |
> Closes: https://bugs.gentoo.org/838478 |
5 |
> Closes: https://bugs.gentoo.org/838481 |
6 |
> Closes: https://bugs.gentoo.org/838487 |
7 |
> Closes: https://bugs.gentoo.org/838490 |
8 |
> Closes: https://bugs.gentoo.org/838493 |
9 |
> Signed-off-by: Mike Gilbert <floppym@g.o> |
10 |
> --- |
11 |
> eclass/java-utils-2.eclass | 10 ++++++---- |
12 |
> 1 file changed, 6 insertions(+), 4 deletions(-) |
13 |
> |
14 |
> diff --git a/eclass/java-utils-2.eclass b/eclass/java-utils-2.eclass |
15 |
> index 11798908dae..2a649942550 100644 |
16 |
> --- a/eclass/java-utils-2.eclass |
17 |
> +++ b/eclass/java-utils-2.eclass |
18 |
> @@ -2099,8 +2099,9 @@ ejavac() { |
19 |
> einfo "${compiler_executable} ${javac_args} ${@}" |
20 |
> fi |
21 |
> |
22 |
> - ebegin "Compiling" |
23 |
> - ${compiler_executable} ${javac_args} "${@}" || die "ejavac |
24 |
> failed" |
25 |
> + local args=( ${compiler_executable} ${javac_args} "${@}" ) |
26 |
> + echo "${args[@]}" >&2 |
27 |
> + "${args[@]}" || die "ejavac failed" |
28 |
> } |
29 |
> |
30 |
> # @FUNCTION: ejavadoc |
31 |
> @@ -2125,8 +2126,9 @@ ejavadoc() { |
32 |
> einfo "javadoc ${javadoc_args} ${@}" |
33 |
> fi |
34 |
> |
35 |
> - ebegin "Generating JavaDoc" |
36 |
> - javadoc ${javadoc_args} "${@}" || die "ejavadoc failed" |
37 |
> + local args=( javadoc ${javadoc_args} "${@}" ) |
38 |
> + echo "${args[@]}" >&2 |
39 |
> + "${args[@]}" || die "ejavadoc failed" |
40 |
> } |
41 |
> |
42 |
> # @FUNCTION: java-pkg_filter-compiler |
43 |
|
44 |
I've got only a minor concern regarding printing the full 'javac' and |
45 |
'javadoc' command with arguments: for Java packages that use a lot of |
46 |
Java dependencies (including indirect, transitive Java dependencies) |
47 |
and/or call the 'ejavac' function with a very long list of arguments, |
48 |
this might generate way more verbose output than before. A good |
49 |
example package is dev-java/log4j-core, which does both of these |
50 |
things -- try compiling it and compare the Portage output. |
51 |
|
52 |
Though, this opinion is merely from a humble man who's been mostly |
53 |
working on Java packages exclusively. Actually, many non-Java ebuilds |
54 |
produce output with similar verbosity. One thing that is still worth |
55 |
noting is, unlike compilation of a C/C++ program, where each compiler |
56 |
invocation usually just processes a few files, a single invocation of |
57 |
javac usually involves putting _all_ Java source files' names into the |
58 |
command-line arguments. |
59 |
|
60 |
Best regards, |
61 |
Leo |