Awesome
Edigen Maven Plugin
This is a Maven 3 plugin which automatically generates an instruction decoder and disassembler of emuStudio CPU plugin from a specification using Edigen.
Running Edigen manually via the command line is no longer necessary.
Usage
Add the plugin to your pom.xml
:
<build>
<plugins>
<plugin>
<groupId>net.emustudio</groupId>
<artifactId>edigen-maven-plugin</artifactId>
<version>1.4</version>
<configuration>
<decoderName>decoder.package.ClassName</decoderName>
<disassemblerName>disassembler.package.ClassName</disassemblerName>
</configuration>
<executions>
<execution>
<goals>
<goal>generate</goal>
</goals>
</execution>
</executions>
</plugin>
...
</plugins>
</build>
Replace decoder.package.ClassName
with the decoder class and disassembler.package.ClassName
with the disassembler class to be generated for your emuStudio processor plugin.
Then save your CPU specification file as src/main/edigen/cpu.eds
and build the project.
Reference
This plugin offers one goal, edigen:generate
, which participates in the generate-sources
lifecycle phase.
Required parameters
decoderName
- the generated instruction decoder package + class namedisassemblerName
- the generated disassembler package + class name
Optional parameters
specification
- the specification file location; default:src/main/edigen/cpu.eds
decoderTemplate
- the template to use for the decoder generationdecoderOutputDir
- the generated decoder output directory; default:target/generated-sources/edigen/
+ path obtained from the decoder package namedisassemblerTemplate
- the template to use for the disassembler generationdisassemblerOutputDir
- the generated disassembler output directory; default:target/generated-sources/edigen/
+ path obtained from the disassembler package namedebug
- setting totrue
enables Edigen's debug mode