Closed kwin closed 1 year ago
The reason is that two different versions of jffi are referenced and the older one ends up in the classpath. One as transitive one of ascidoctorj -> jruby -> jruby core (version 1.3.1) And the other one as transitive of jbake-core-> orientdb -> jna-posix -> jna-jffi (version 1.3.9)
The first one does not have support for Mac OS Aarch64 yet. One needs to manage the dependencies to use the newer one.
this is the full classpath of the Maven plugin:
collectTime=167597625, DefaultDependencyCollector.transformTime=4876500}
[DEBUG] org.jbake:jbake-maven-plugin:jar:2.7.0-rc.6
[DEBUG] org.slf4j:slf4j-api:jar:1.7.32:runtime
[DEBUG] org.slf4j:jul-to-slf4j:jar:1.7.32:runtime
[DEBUG] org.slf4j:jcl-over-slf4j:jar:1.7.32:runtime
[DEBUG] ch.qos.logback:logback-classic:jar:1.2.10:runtime
[DEBUG] ch.qos.logback:logback-core:jar:1.2.10:runtime
[DEBUG] org.jbake:jbake-core:jar:2.7.0-rc.6:runtime
[DEBUG] commons-io:commons-io:jar:2.11.0:runtime
[DEBUG] org.apache.commons:commons-configuration2:jar:2.7:runtime
[DEBUG] org.apache.commons:commons-text:jar:1.8:runtime
[DEBUG] commons-logging:commons-logging:jar:1.2:runtime
[DEBUG] commons-beanutils:commons-beanutils:jar:1.9.4:runtime
[DEBUG] org.apache.commons:commons-lang3:jar:3.12.0:runtime
[DEBUG] com.googlecode.json-simple:json-simple:jar:1.1.1:runtime
[DEBUG] com.orientechnologies:orientdb-core:jar:3.1.20:runtime
[DEBUG] com.github.jnr:jnr-posix:jar:3.1.15:runtime
[DEBUG] com.github.jnr:jnr-ffi:jar:2.2.11:runtime
[DEBUG] org.ow2.asm:asm:jar:9.2:runtime
[DEBUG] org.ow2.asm:asm-commons:jar:9.2:runtime
[DEBUG] org.ow2.asm:asm-analysis:jar:9.2:runtime
[DEBUG] org.ow2.asm:asm-tree:jar:9.2:runtime
[DEBUG] org.ow2.asm:asm-util:jar:9.2:runtime
[DEBUG] com.github.jnr:jnr-a64asm:jar:1.0.0:runtime
[DEBUG] com.github.jnr:jnr-x86asm:jar:1.0.2:runtime
[DEBUG] com.github.jnr:jnr-constants:jar:0.10.3:runtime
[DEBUG] org.lz4:lz4-java:jar:1.4.0:runtime
[DEBUG] com.ibm.icu:icu4j:jar:65.1:runtime
[DEBUG] com.carrotsearch:hppc:jar:0.8.2:runtime
[DEBUG] commons-lang:commons-lang:jar:2.6:runtime
[DEBUG] javax.activation:javax.activation-api:jar:1.2.0:runtime
[DEBUG] org.jsoup:jsoup:jar:1.14.3:runtime
[DEBUG] com.sparkjava:spark-core:jar:2.9.3:runtime
[DEBUG] org.eclipse.jetty:jetty-server:jar:9.4.31.v20200723:runtime
[DEBUG] javax.servlet:javax.servlet-api:jar:3.1.0:runtime
[DEBUG] org.eclipse.jetty:jetty-http:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-util:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-io:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-webapp:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-xml:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-servlet:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-security:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty.websocket:websocket-server:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty.websocket:websocket-common:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty.websocket:websocket-client:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty:jetty-client:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty.websocket:websocket-servlet:jar:9.4.31.v20200723:runtime
[DEBUG] org.eclipse.jetty.websocket:websocket-api:jar:9.4.31.v20200723:runtime
[DEBUG] org.asciidoctor:asciidoctorj:jar:2.5.2:runtime
[DEBUG] org.asciidoctor:asciidoctorj-api:jar:2.5.2:runtime
[DEBUG] org.jruby:jruby:jar:9.2.17.0:runtime
[DEBUG] org.jruby:jruby-core:jar:9.2.17.0:runtime
[DEBUG] com.github.jnr:jnr-netdb:jar:1.2.0:runtime
[DEBUG] com.github.jnr:jnr-enxio:jar:0.32.3:runtime
[DEBUG] com.github.jnr:jnr-unixsocket:jar:0.38.5:runtime
[DEBUG] com.github.jnr:jffi:jar:1.3.1:runtime
[DEBUG] com.github.jnr:jffi:jar:native:1.3.1:runtime
[DEBUG] org.jruby.joni:joni:jar:2.1.31:runtime
[DEBUG] org.jruby.jcodings:jcodings:jar:1.0.46:runtime
[DEBUG] org.jruby:dirgra:jar:0.3:runtime
[DEBUG] com.headius:invokebinder:jar:1.11:runtime
[DEBUG] com.headius:options:jar:1.4:runtime
[DEBUG] com.jcraft:jzlib:jar:1.1.3:runtime
[DEBUG] com.martiansoftware:nailgun-server:jar:0.9.1:runtime
[DEBUG] joda-time:joda-time:jar:2.10.5:runtime
[DEBUG] com.headius:backport9:jar:1.8:runtime
[DEBUG] javax.annotation:javax.annotation-api:jar:1.3.1:runtime
[DEBUG] org.jruby:jruby-stdlib:jar:9.2.17.0:runtime
[DEBUG] com.beust:jcommander:jar:1.72:runtime
[DEBUG] org.codehaus.groovy:groovy:jar:3.0.9:runtime
[DEBUG] org.codehaus.groovy:groovy-templates:jar:3.0.9:runtime
[DEBUG] org.codehaus.groovy:groovy-xml:jar:3.0.9:runtime
[DEBUG] org.codehaus.groovy:groovy-dateutil:jar:3.0.9:runtime
[DEBUG] org.freemarker:freemarker:jar:2.3.31:runtime
[DEBUG] org.thymeleaf:thymeleaf:jar:3.0.14.RELEASE:runtime
[DEBUG] ognl:ognl:jar:3.1.26:runtime
[DEBUG] org.javassist:javassist:jar:3.20.0-GA:runtime
[DEBUG] org.attoparser:attoparser:jar:2.0.5.RELEASE:runtime
[DEBUG] org.unbescape:unbescape:jar:1.1.6.RELEASE:runtime
[DEBUG] de.neuland-bfi:jade4j:jar:1.3.2:runtime
[DEBUG] org.apache.commons:commons-jexl:jar:2.1.1:runtime
[DEBUG] commons-collections:commons-collections:jar:3.2.2:runtime
[DEBUG] com.googlecode.concurrentlinkedhashmap:concurrentlinkedhashmap-lru:jar:1.4.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-ast:jar:0.62.2:runtime
[DEBUG] org.jetbrains:annotations:jar:15.0:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-builder:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-collection:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-data:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-dependency:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-format:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-html:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-misc:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-sequence:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-visitor:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-profile-pegdown:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-abbreviation:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-util-options:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-anchorlink:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-aside:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-jira-converter:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-autolink:jar:0.62.2:runtime
[DEBUG] org.nibor.autolink:autolink:jar:0.6.0:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-definition:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-emoji:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-escaped-character:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-footnotes:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-gfm-strikethrough:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-gfm-tasklist:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-ins:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-jekyll-front-matter:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-yaml-front-matter:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-superscript:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-tables:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-toc:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-typographic:jar:0.62.2:runtime
[DEBUG] com.vladsch.flexmark:flexmark-ext-wikilink:jar:0.62.2:runtime
[DEBUG] io.pebbletemplates:pebble:jar:3.1.5:runtime
[DEBUG] org.yaml:snakeyaml:jar:1.30:runtime
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1:runtime
Using the following exclusions make the build succeed (obviously without supporting Ascidoctor markup):
<plugin>
<groupId>org.jbake</groupId>
<artifactId>jbake-maven-plugin</artifactId>
<version>2.7.0-rc.6</version>
<executions>
<execution>
<id>default-generate</id>
<phase>compile</phase>
<goals>
<goal>generate</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctorj</artifactId>
<version>2.5.2</version>
<exclusions>
<exclusion>
<groupId>*</groupId>
<artifactId>*</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
</plugin>
Updating to ascidoctor-j 2.5.6 fixes that issue as well, as it uses a newer JRuby:
<plugin>
<groupId>org.jbake</groupId>
<artifactId>jbake-maven-plugin</artifactId>
<version>2.7.0-rc.6</version>
<executions>
<execution>
<id>default-generate</id>
<phase>compile</phase>
<goals>
<goal>generate</goal>
</goals>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.asciidoctor</groupId>
<artifactId>asciidoctorj</artifactId>
<version>2.5.6</version>
</dependency>
</dependencies>
</plugin>
When running the maven plugin on Mac OS (12.6 with Apple Silicon M1 Pro) I encounter the following error