Re: CC + Ant + Ecore2Java

krischan83 <[email protected]>
Newsgroups gmane.comp.java.cruise-control.user
Message-ID <[email protected]>
Hi all,

so far this approach works for me, too, however the edit code (and editor
code which I actually don't need) won't be generated... the model code
generation works properly.

Do I need a special parameter for that?

I invoke the process headless via the platform (3.4.2) in a given workspace,
the application is the AntRunner (runs on a second ant file containing the
emf.Ecore2Java call).

Hope anybody has help!

thanks in advance
chris


Adrian Mörchen wrote:
> 
> Thanks, that works for me.
> 
> Jeffrey Fredrick schrieb:
>> So perhaps you could run that target by running Eclipse in headless
>> mode as per the documentation for the task:
>>
>> http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.emf/org.eclipse.emf/plugins/org.eclipse.emf.importer.ecore/readme.html?root=Modeling_Project&view=co#antTasks
>>
>> You could either do that from your Ant script or by using the
>> ExecBuilder to use Eclipse to run your Ant script.
>>
>> Jtf
>>
>>
>> On Sat, Nov 8, 2008 at 11:58 PM, Adrian Mörchen <[email protected]>
>> wrote:
>>   
>>> Okay,
>>>
>>> The error is this (within CC or just command-line):
>>>
>>>    Problem: failed to create task or type emf.Ecore2Java
>>>   Cause: The name is undefined.
>>>   Action: Check the spelling.
>>>   Action: Check that any custom tasks/types have been declared.
>>>   Action: Check that any <presetdef>/<macrodef> declarations have
>>>   taken place.
>>>
>>>           at
>>>
>>> org.apache.tools.ant.UnknownElement.getNotFoundException(UnknownElement.java:481)
>>>           at
>>>  
>>> org.apache.tools.ant.UnknownElement.makeObject(UnknownElement.java:413)
>>>           at
>>>
>>> org.apache.tools.ant.UnknownElement.maybeConfigure(UnknownElement.java:160)
>>>           at org.apache.tools.ant.Task.perform(Task.java:347)
>>>           at org.apache.tools.ant.Target.execute(Target.java:357)
>>>           at org.apache.tools.ant.Target.performTasks(Target.java:385)
>>>           at
>>>   org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329)
>>>           at
>>>
>>> org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
>>>           at
>>>   org.apache.tools.ant.Project.executeTargets(Project.java:1181)
>>>           at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:416)
>>>           ... 17 more
>>>
>>>
>>> From searching around I found out, that this is a problem with mising
>>> libraries. Within Eclipse the solution is to run the ant task
>>> explicitly in the same JRE Eclipse is running in.
>>>
>>>
>>> Jeffrey Fredrick schrieb:
>>>     
>>>> What kind of error message are you getting?
>>>>
>>>> Does it work if you run Ant from the command-line?  What if you use
>>>> the same arguments that CC is using when it runs Ant?
>>>>
>>>> Jtf
>>>>
>>>>
>>>> On Fri, Nov 7, 2008 at 6:27 AM, Adrian Mörchen <[email protected]>
>>>> wrote:
>>>>
>>>>       
>>>>> Hi,
>>>>>
>>>>> I want Ant also to generate model code from my ecore models. For that
>>>>> I
>>>>> use
>>>>> the emf.Ecore2Java task like this:
>>>>>
>>>>> <target name="codegen">
>>>>>      <emf.Ecore2Java model="${basedir}/models/${model.name}.ecore"
>>>>>          genModel="${basedir}/models/${model.name}.genmodel"
>>>>> modelProject="${basedir}"
>>>>>          modelProjectFragmentPath="src_generated/">
>>>>>      </emf.Ecore2Java>
>>>>> </target>
>>>>>
>>>>> It works from within Eclipse, but not using it with CC.
>>>>> All libs should be available.
>>>>>
>>>>> In Eclipse is a problem, that all has to be run in the same JRE. I
>>>>> don't
>>>>> know, if this is a problem with the ant schedule in CC too.
>>>>>
>>>>> Is here anybody having any experiences with this?
>>>>>
>>>>> Thanks
>>>>>
>>>>> Adrian
>>>>>
>>>>>
>>>>>         
>>
>>
>>   
> 
> 
> begin:vcard
> fn;quoted-printable:Adrian M=C3=B6rchen
> n;quoted-printable:M=C3=B6rchen;Adrian
> email;internet:[email protected]
> tel;home:035141725969
> x-mozilla-html:FALSE
> version:2.1
> end:vcard
> 
> 
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the
> world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Cruisecontrol-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/cruisecontrol-user
> 
> 

-- 
View this message in context: http://www.nabble.com/CC-%2B-Ant-%2B-Ecore2Java-tp20382697p24154597.html
Sent from the CruiseControl - User mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Are you an open source citizen? Join us for the Open Source Bridge conference!
Portland, OR, June 17-19. Two days of sessions, one day of unconference: $250.
Need another reason to go? 24-hour hacker lounge. Register today!
http://ad.doubleclick.net/clk;215844324;13503038;v?http://opensourcebridge.org
_______________________________________________
Cruisecontrol-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/cruisecontrol-user
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.