Skip to main content



      Home
Home » Modeling » M2T (model-to-text transformation) » Ant Script for Acceleo Compiler to generate EMTL files(buildstandalone.xml build error)
Ant Script for Acceleo Compiler to generate EMTL files [message #1228040] Mon, 06 January 2014 04:06 Go to next message
Eclipse UserFriend
Hi Guys,

I'm trying to use the ANT file headless build (buildstandalone.xml) for our acceleo project. At first project which does not have dependencies from other project the build fine and the emtl was generated correctly but when i build the next project with the dependency with the first project i was not able to build it successfully. I have encountered lots of errors like below but it built on the PDE with no errors.

Please any input. thanks in advance.

AntTask:
<?xml version="1.0" encoding="UTF-8"?>
<project basedir="." default="compile" name="com.xxx.yyy.zzz.genpp">

<property name="ECLIPSE_HOME" value="F:/opt/1.3/eclipse"/>
<property name="SOURCE_FOLDER" value="${basedir}/src/"/>
<property name="OUTPUT_FOLDER" value="${basedir}/src/"/>

<path id="com.xxx.yyy.zz.genpp.classpath">
<path refid="com.xxx.yyy.zz.genpp.libraryclasspath" />
</path>

<echo> ${SOURCE_FOLDER} </echo>
<echo> ${OUTPUT_FOLDER} </echo>
<!-- The classpath with only the dependencies used by the project (a dependency with the parser is required) -->
<path id="acceleoPath">
<fileset dir="lib" erroronmissingdir="false">
<include name="*.jar"/>
</fileset>
<fileset dir="${ECLIPSE_HOME}/plugins">
<include name="**/*.jar" />
</fileset>
<dirset dir="${ECLIPSE_HOME}/plugins">
<include name="**/*" />
</dirset>
<fileset dir="${ECLIPSE_HOME}/../stage.area/">
<include name="*.stage/${fsd.version}/eclipse/plugins/*.jar" />
</fileset>
</path>

<taskdef id="Acompile" name="Acompile" classname="org.eclipse.acceleo.parser.compiler.AcceleoCompiler" classpathref="acceleoPath" >
</taskdef>

<!-- Change the value of the property SOURCE_FOLDERS to match the configuration of your project. -->
<target name="compile">
<Acompile sourceFolder="${SOURCE_FOLDER}"
outputFolder="${OUTPUT_FOLDER}"
dependencies=""
binaryResource="false"
packagesToRegister="">
</Acompile>
</target>
</project>

Output
compile:
[acceleoCompiler] generateLabelProvider.mtl
[acceleoCompiler] 5:The metamodel couldn't be resolved
[acceleoCompiler] 7:Module com::accenture::mddarch::acceleo::lib::util::CommonServices not found.
[acceleoCompiler] 13:Invalid Type: ContributingEditor
[acceleoCompiler] 15:Cannot find operation (classFileName()) for the type (null)
[acceleoCompiler] 17:Incomplete reference to variable declaration in variable expression: (aContributingEditor)
[acceleoCompiler] 18:Incomplete reference to variable declaration in variable expression: (aContributingEditor)
[acceleoCompiler] 19:Cannot find operation (classFileName()) for the type (null)
[acceleoCompiler] 21:Cannot find operation (genDate()) for the type (EObject)
[acceleoCompiler] 30:Incomplete reference to variable declaration in variable expression: (aContributingEditor)
[acceleoCompiler] 40:Unrecognized variable: (titlePageProvider)
[acceleoCompiler] 46:Unrecognized variable: (titlePageProvider)
[acceleoCompiler] 77:Invalid Type: ContributingEditor
[acceleoCompiler] 78:Unrecognized variable: (titlePageProvider)

[Updated on: Mon, 06 January 2014 11:07] by Moderator

Re: Ant Script for Acceleo Compiler to generate EMTL files [message #1228545 is a reply to message #1228040] Tue, 07 January 2014 08:24 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

The best solution regarging any issue with Ant and Acceleo is not to use Ant. It is not actively supported anymore since we have moved to Tycho. There are examples of very complex build involving several generators on github.

Regards,

Stephane Begaudeau, Obeo

--
Twitter: @sbegaudeau
Google+: +stephane.begaudeau
Blog: http://stephanebegaudeau.tumblr.com | Eclipse Java Development Tools Tips and Tricks
Re: Ant Script for Acceleo Compiler to generate EMTL files [message #1231878 is a reply to message #1228545] Wed, 15 January 2014 11:20 Go to previous messageGo to next message
Eclipse UserFriend
Confirmed ! Worked for me except that I had to mention the repositories where the Maven acceleo-compile:3.2.1 was located:

...
  <pluginRepositories>
    <pluginRepository>
      <!-- need maven-findbugs-2.3.2-SNAPSHOT, see http://jira.codehaus.org/browse/MFINDBUGS-122 remove this when this version is released -->
      <id>codehaus.snapshots</id>
      <url>http://snapshots.repository.codehaus.org/</url>
    </pluginRepository>
	<pluginRepository>
      <id>Indigo Release</id>
      <url>https://raw.github.com/eclipse/acceleo/master/maven/repository/releases/indigo</url>
    </pluginRepository>
	<pluginRepository>
      <id>Juno Release</id>
      <url>https://raw.github.com/eclipse/acceleo/master/maven/repository/releases/juno</url>
    </pluginRepository>
	<pluginRepository>
      <id>Snapshots</id>
      <url>https://raw.github.com/eclipse/acceleo/master/maven/repository/snapshots</url>
    </pluginRepository>
  </pluginRepositories>
...


Even not sure that Kepler and Juno are online ... Could you confirm Stephane ?

Best regards;

[Updated on: Wed, 15 January 2014 11:25] by Moderator

Re: Ant Script for Acceleo Compiler to generate EMTL files [message #1233914 is a reply to message #1231878] Mon, 20 January 2014 15:48 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

I am currently improving the Acceleo maven plugin. It will now be published on repo.eclipse.org (the first version has been published there today). It will now be built directly along the Acceleo artifacts which will also be published on repo.eclipse.org automatically. I will migrate the examples and integrate them to our continuous integration tomorrow.

Regards,

Stephane Begaudeau, Obeo

--
Twitter: @sbegaudeau
Google+: +stephane.begaudeau
Blog: http://stephanebegaudeau.tumblr.com | Eclipse Java Development Tools Tips and Tricks
Re: Ant Script for Acceleo Compiler to generate EMTL files [message #1262260 is a reply to message #1233914] Mon, 03 March 2014 07:34 Go to previous message
Eclipse UserFriend
Stephane,

You mentioned a new release of Acceleo Maven plugin:
Stephane Begaudeau wrote on Mon, 20 January 2014 15:48

I am currently improving the Acceleo maven plugin. It will now be published on repo.eclipse.org (the first version has been published there today). It will now be built directly along the Acceleo artifacts which will also be published on repo.eclipse.org automatically. I will migrate the examples and integrate them to our continuous integration tomorrow.


It's also documented Acceleo/Maven wiki page, describing the same changes - migration to a new repo, changing the build process.
Are there other changes?

Thanks,
Tanya

[Updated on: Mon, 03 March 2014 09:51] by Moderator

Previous Topic:[Acceleo] How to activate the "Acceleo Model To Text" context menu?
Next Topic:[Acceleo] Any plans for MTL-&gt;Java codegen?
Goto Forum:
  


Current Time: Sat Jul 12 07:35:12 EDT 2025

Powered by FUDForum. Page generated in 0.03880 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top