Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 361387 - EMF emf.Ecore2Java task does not make editor project java nature
Summary: EMF emf.Ecore2Java task does not make editor project java nature
Status: RESOLVED WORKSFORME
Alias: None
Product: EMF
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Ed Merks CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-19 08:49 EDT by Ralph Gerbig CLA
Modified: 2011-10-27 04:29 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Gerbig CLA 2011-10-19 08:49:58 EDT
Build Identifier: M20110909-1335

I use the emf.Ecore2Java task to generate my source code. The editor plugin gets completely generated but is not a java project. Here the .project file:

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
	<name>xxx.xxx.xxx</name>
	<comment></comment>
	<projects>
	</projects>
	<buildSpec>
	</buildSpec>
	<natures>
	</natures>
</projectDescription>

plugin.xml etc. look fine. It seems that something goes wrong with generating the .project file

Reproducible: Always
Comment 1 Ed Merks CLA 2011-10-19 08:57:56 EDT
Might it be the case that file existed before you ran the generator?

I'm unlikely to find time in the foreseeable future to look at Ant problems...
Comment 2 Ralph Gerbig CLA 2011-10-21 04:42:43 EDT
Maybe there can be these people could help with the ant stuff:

http://www.eclipse.org/gmt/epsilon/doc/articles/eugenia-ant/
Comment 3 Ed Merks CLA 2011-10-22 07:56:02 EDT
Can you confirm that this isn't just a problem with creating a project in a location that's already populated with files like the .project file.  That's the only time I've seen such a problem...
Comment 4 Ralph Gerbig CLA 2011-10-24 03:53:02 EDT
Hi,

my .edit plugin is under version control there everything worked fine. The .editor plugin was completly newly created. After having a by hand created plugin the .editor plugin generation works fine as well. Therefore I versioned my .editor plugin as well to fix the problem.

Ralph
Comment 5 Ed Merks CLA 2011-10-27 04:12:34 EDT
When I modify our tools tests to generate edit and editor projects they end up looking like this:

?xml version="1.0" encoding="UTF-8"?>
projectDescription>
 <name>library.java.1.4.editor</name>
 <comment></comment>
 <projects>
 </projects>
 <buildSpec>
   <buildCommand>
     <name>org.eclipse.jdt.core.javabuilder</name>
     <arguments>
     </arguments>
   </buildCommand>
   <buildCommand>
     <name>org.eclipse.pde.ManifestBuilder</name>
     <arguments>
     </arguments>
   </buildCommand>
   <buildCommand>
     <name>org.eclipse.pde.SchemaBuilder</name>
     <arguments>
     </arguments>
   </buildCommand>
 </buildSpec>
 <natures>
   <nature>org.eclipse.jdt.core.javanature</nature>
   <nature>org.eclipse.pde.PluginNature</nature>
 </natures>
/projectDescription>

So it looks to me like it's working properly.
Comment 6 Ralph Gerbig CLA 2011-10-27 04:16:05 EDT
Hi Ed,

what is the plugin name in the CVS so that I can check it out? Is it somewhere around org.eclipse.emf/org.eclipse.emf/tests/ in the CVS?

Thanks,

Ralph
Comment 7 Ed Merks CLA 2011-10-27 04:29:44 EDT
It's org.eclipse.emf.test.tools.  I couldn't figure out how to make the tests generate edit and editor stuff, so I used the debugger to modify the values of edit and editor in Generator.PlatformRunnable to be true.