JDOM could not be used due to mismatch between the included JDOM beta version and what we have installed. While here, do not include DOCTYPE statements from the included documents into the parent. SAX and DOM processors drop included DOCTYPE statements and JDOM variant should do that, too. The code will be rebuilt using Ant from source instead of dropping jar file referring to the obsolete methods.
Created attachment 243448 [details] 0001-textproc-xincluder-Fix-processing-using-JDOM.patch Patch to fix JDOM issues, bumps PORTREVISION
Build fails for me. Does it work for you? [javac] /wrkdirs/usr/ports/textproc/xincluder/work/xincluder/bin/src/com/elharo/xml/xinclude/JDOMXIncluder.java:609: error: cannot find symbol [javac] XMLOutputter outputter = new XMLOutputter(); [javac] ^ [javac] symbol: class XMLOutputter [javac] location: class JDOMXIncluder [javac] /wrkdirs/usr/ports/textproc/xincluder/work/xincluder/bin/src/com/elharo/xml/xinclude/JDOMXIncluder.java:612: error: cannot find symbol [javac] Document input = builder.build(args[i]); [javac] ^ [javac] symbol: class Document [javac] location: class JDOMXIncluder [javac] /wrkdirs/usr/ports/textproc/xincluder/work/xincluder/bin/src/com/elharo/xml/xinclude/JDOMXIncluder.java:619: error: cannot find symbol [javac] Document output = resolve(input, base); [javac] ^ [javac] symbol: class Document [javac] location: class JDOMXIncluder [javac] Note: Some input files use or override a deprecated API. [javac] Note: Recompile with -Xlint:deprecation for details. [javac] Note: Some input files use unchecked or unsafe operations. [javac] Note: Recompile with -Xlint:unchecked for details. [javac] 99 errors BUILD FAILED /wrkdirs/usr/ports/textproc/xincluder/work/xincluder/build.xml:82: Compile failed; see the compiler error output for details. Total time: 0 seconds *** Error code 1
Created attachment 243518 [details] Fix processing with JDOM Good catch! I forgot to add build dependencies as well. Please see the updated patch.
(In reply to Marcin Cieślak from comment #3) Great, just another detail, the REINPLACE_CMD over the build.xml file is a noop. I will delete it before committing.
(In reply to Fernando Apesteguía from comment #4) Scratch that, I think it is a false positive from the framework.
Sorry, I have to fix it the other way... Somehow I like "makepatch" less and less...
Created attachment 243525 [details] Fix processing with JDOM Another attempt - - runtime and build dependencies listed separately now (as per portlint advice) - build.xml patched with sed only
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=860aa846f7d9b756fc020b7efa4ed086d9675c21 commit 860aa846f7d9b756fc020b7efa4ed086d9675c21 Author: Marcin Cieślak <saper@saper.info> AuthorDate: 2023-07-21 14:59:58 +0000 Commit: Fernando Apesteguía <fernape@FreeBSD.org> CommitDate: 2023-07-22 11:25:48 +0000 textproc/xincluder: Fix processing using JDOM JDOM could not be used due to mismatch with the included JDOM. PR: 272559 Reported by: saper@saper.info textproc/xincluder/Makefile | 18 +++++++++++++--- ...om_elharo_xml_xinclude_JDOMXIncluder.java (new) | 24 ++++++++++++++++++++++ 2 files changed, 39 insertions(+), 3 deletions(-)
Committed, Thanks!