Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 127576

Summary: product export does not create the eclipse.ini
Product: [Eclipse Project] PDE Reporter: Pascal Rapicault <pascal>
Component: BuildAssignee: Andrew Niefer <aniefer>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.2   
Target Milestone: 3.2 M6   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
patch
none
patch
none
Patch containing some modifications
none
updated none

Description Pascal Rapicault CLA 2006-02-13 17:12:20 EST
The product export does not create the eclipse.ini file.
Comment 1 Andrew Niefer CLA 2006-02-22 14:21:12 EST
Created attachment 35176 [details]
patch

Patch adds generation of eclipse.ini and inclusion of the launcher feature.

Parsing of the .product file in ProductFile.java is rewritten as a state machine.  Getting the values of the program & vm args did not fit easily in the old pattern.  This also allows better detection of a bad .product file when we start logging.  Parsing is now done at construction time and throws a CoreException on File not found or invalid xml.
Comment 2 Andrew Niefer CLA 2006-02-24 11:16:22 EST
Created attachment 35310 [details]
patch

Fix small mistake in parsing .product file that was in previous patch.
Comment 3 Pascal Rapicault CLA 2006-02-27 11:37:47 EST
Created attachment 35410 [details]
Patch containing some modifications

The attached patch updates the wellknown values of the config.ini.

Some missing things of the patch:
- The default values obtained from the parser are sometimes leading to errors if a value is not set (for example the getConfigIni() was returning "" which later caused an NPE, a similar thing happened where the exe did not had a name (".exe"), if the splash screen has no value, an entry is still generated in the config.ini).
- Need to write the application id in the config.ini.
- The eclipse.ini is not written at the correct place for Mac (is it moved by the branding iron?)
- in createEclipseProductFile, 	if (!dir.exists() || !dir.isDirectory()) dir.mkdirs(); what happens when "dir" exists but it is a file.
Comment 4 Andrew Niefer CLA 2006-02-28 17:16:01 EST
Created attachment 35507 [details]
updated

-default values from product parser are null, add handling of null in callers
-write eclipse.application in config.ini
-For Mac, put launcher ini file in /<launcher>.app/Contents/MacOS/<launcher>.ini
-when os==* only generate config.ini 
-handle when destination directory already exists as a file (we can't create anything)
Comment 5 Pascal Rapicault CLA 2006-03-02 15:45:39 EST
This patch has been released in HEAD.
We will need to make sure that an warning is reported if the launcher feature is missing.