Remove use of exec-maven-plugin

This commit is contained in:
Mikolaj Izdebski 2020-04-23 13:20:41 +02:00
parent e36a51727b
commit f7eb4eb571

View File

@ -18,7 +18,6 @@ Patch0: 0001-Port-to-JFlex-1.7.0.patch
BuildRequires: maven-local
BuildRequires: mvn(org.apache.maven.plugins:maven-assembly-plugin)
BuildRequires: mvn(org.codehaus.mojo:exec-maven-plugin)
BuildRequires: mvn(org.sonatype.oss:oss-parent:pom:)
BuildRequires: byaccj
@ -47,19 +46,24 @@ API docs for %{name}.
%pom_remove_plugin :maven-invoker-plugin
%pom_remove_plugin :maven-jflex-plugin
%pom_remove_plugin :maven-enforcer-plugin
%pom_remove_plugin :exec-maven-plugin
%mvn_file : %{name}
%mvn_alias : qdox:qdox
%pom_xpath_set pom:workingDirectory '${basedir}/src/main/java/com/thoughtworks/qdox/parser/impl'
%build
# Generate scanners (upstream does this with maven-jflex-plugin)
jflex -d src/main/java/com/thoughtworks/qdox/parser/impl src/grammar/lexer.flex
jflex -d src/main/java/com/thoughtworks/qdox/parser/impl src/grammar/commentlexer.flex
# Generate parsers (upstream does this with exec-maven-plugin)
(cd ./src/main/java/com/thoughtworks/qdox/parser/impl
byaccj -v -Jnorun -Jnoconstruct -Jclass=DefaultJavaCommentParser -Jpackage=com.thoughtworks.qdox.parser.impl ../../../../../../../grammar/commentparser.y
byaccj -v -Jnorun -Jnoconstruct -Jclass=Parser -Jimplements=CommentHandler -Jsemantic=Value -Jpackage=com.thoughtworks.qdox.parser.impl -Jstack=500 ../../../../../../../grammar/parser.y
)
# Build artifact
%mvn_build -f -- -Dqdox.byaccj.executable=byaccj
%mvn_build -f
# Inject OSGi manifests
jar ufm target/%{name}-%{upstream_version}.jar %{SOURCE1}