Bug 237913 - devel/apache-ant - upgrade, build from source
Summary: devel/apache-ant - upgrade, build from source
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-java mailing list
URL:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2019-05-15 16:40 UTC by Mikhail Teterin
Modified: 2019-05-16 20:12 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (java)


Attachments
Build ant-1.10.6 from source (6.04 KB, patch)
2019-05-15 16:40 UTC, Mikhail Teterin
no flags Details | Diff
Build ant-1.10.6 from source (6.28 KB, patch)
2019-05-16 20:12 UTC, Mikhail Teterin
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mikhail Teterin freebsd_committer 2019-05-15 16:40:58 UTC
Created attachment 204393 [details]
Build ant-1.10.6 from source

The port currently installs pre-built JARs and documentation, which is a tad depressing -- FreeBSD ports ought to build open-sourced software from source, using binaries only when sources aren't available or in other exceptional circumstances...

The proposed patch corrects this problem -- unfortunately common for the Java-related ports -- and also upgrades the version from 1.10.5 to the currently-latest 1.10.6.

It also enables the test-target.

What's still to do:
 * Some of tests fail, which needs scrupulous investigation;
 * Building of Javadocs throws errors because the optional 3rd-party JARs aren't present -- [bug 63438](https://bz.apache.org/bugzilla/show_bug.cgi?id=63438) filed with the upstram. These errors are currently ignored.
 * The port's options should list all of the optional dependencies -- enabling and disabling the extra features explicitly

These to-do items can be addressed incrementally -- I think, the port can be upgraded as proposed already.
Comment 1 Michael Osipov 2019-05-16 09:32:04 UTC
Hey there, I'd like to make a few comments (specific and in general):

Being an ASF member and happy FreeBSD user, but not an Ant committer have have these cases once in a while. I just can tell how we handle thia at least with Maven, but am sure that other projects do similarly:

ASF only releases source code, in some cases like Java, we do provide binary releases. Both are trustworthly because all of them signed (GPG) when you download from dist.apache.org. In general we reject custom-built binary distributions becaue they aren't verified by us and contain sometimes tremendous modifications, .e.g., Debian and friends are worstcase here, I just loath their approach. We refuse to evaluate bugs with those customs distros. Of course, it requires some adaptations for a specific platform, but it has to be reasonable and generally not break the flow of the application.

As for Javadoc issues: you have have the ports system download mutltiple files, so you could download them from Maven Central and add them for the build OR simply disable the build of Javadoc because I do not see any benefit generating it here if you use Ant from command line only. They are needed by people wrigin custom targets/commands for Ant and they will use an IDE where source JARs are pulled from Central too.
Comment 2 Mikhail Teterin freebsd_committer 2019-05-16 10:53:14 UTC
(In reply to Michael Osipov from comment #1)
You seem to agree, that building from source is preferable.

As for Javadoc, whether to build it is controlled by the user-settable option. The DOCS-option is standard, and can be set globally -- for all ports -- or individually When it is set, however, it must work....

The current version of the port respects it already -- just implements it differently, by downloading the prebuilt documentation, instead of regenerating it. Which sends us back to it being preferable to build things from source.
Comment 3 Michael Osipov 2019-05-16 11:15:41 UTC
(In reply to Mikhail Teterin from comment #2)

Being able to reproduce open source softare is a must. If I can't build it my own ony my platforms, I won't use it. It's that simple. It does not necessary mean that I do not trust others to do this for me.

Af for the DOCS, I really would recommend get the JARs as intended by the build. Try to deviate as little as possible from the official binary packages.
Comment 4 Mikhail Teterin freebsd_committer 2019-05-16 20:12:26 UTC
Created attachment 204405 [details]
Build ant-1.10.6 from source

The earlier version was not running javadocs, but still installing other ant manuals (in HTML). This update disables those as well by not even extracting them.