{
try
{
addNature(prj, IVdmRtCoreConstants.NATURE);
IVdmProject p = (IVdmProject) prj.getAdapter(IVdmProject.class);
Assert.isNotNull(p, "Project could not be adapted");
p.setBuilder(Release.DEFAULT);
addNature(prj, IDestecsCoreConstants.NATURE);
addBuilder(prj, "org.destecs.ide.vdmmetadatabuilder.builder", null, null);
addBuilder(prj, IDestecsCoreConstants.BUILDER_ID, null, null);
addBuilder(prj, IDestecsCoreConstants.SCRIPT_BUILDER_ID, null, null);
IDestecsProject dp = (IDestecsProject) prj.getAdapter(IDestecsProject.class);
ModelBuildPath modelPath = p.getModelBuildPath();
modelPath.add(dp.getVdmModelFolder());
modelPath.remove(prj);
modelPath.setOutput(dp.getOutputFolder());
modelPath.setLibrary(dp.getVdmModelFolder().getFolder("lib"));
modelPath.save();
p.getModel().clean();
prj.build(IncrementalProjectBuilder.FULL_BUILD, new NullProgressMonitor());
IProjectDescription d = prj.getDescription();
d.setComment("DESTECS-"+getPlatformBundleVersion());