6-6-6/spark-overlay

dev-java/jaxb-impl-2.2.6-r2: missing property file

efferre79 opened this issue · 3 comments

the current implementation is missing the file META-INF/services/javax.xml.bind.JAXBContext, when used with recent jvm versions (I tried with 17 but I guess also 11 or 21), this is the typical error that pops out:

javax.xml.bind.JAXBException: Implementation of JAXB-API has not been found on module path or classpath.
 - with linked exception:
[java.lang.ClassNotFoundException: com.sun.xml.internal.bind.v2.ContextFactory]
        at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:131)
        at javax.xml.bind.ContextFinder.find(ContextFinder.java:318)
        at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:478)
        at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:435)
        at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:336)

if [[ -d "${S}"/${JAVA_SRC_DIR}/META-INF ]] ; then
rm "${S}"/${JAVA_SRC_DIR}/META-INF -r || die
fi ;;

Actually META-INF gets removed during src_unpackphase. Probably we need to preserve something from it.
Here is a question:

  • should META-INF/services be generated during src_compile
  • or be copied from META-INF (I suppose it should be this one: source)

Do you have any suggestions?

Do you have any suggestions?

I think the way you implemented looks fine

Ok, let's merge it and see how it will affect other things