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

Bug 352457

Summary: [publisher] Unbranded Mac OS X Product cannot be installed on case sensitive file system
Product: [Eclipse Project] Equinox Reporter: Tobias Oberlies <t-oberlies>
Component: p2Assignee: Tobias Oberlies <t-oberlies>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.7   
Target Milestone: Juno M6   
Hardware: PC   
OS: Linux   
Whiteboard:
Bug Depends on:    
Bug Blocks: 331974, 349877, 368246    

Description Tobias Oberlies CLA 2011-07-19 09:28:47 EDT
For unbranded Max OS X products, the launcher name is "eclipse", but the Mac application folder is "Eclipse.app". When generating touchpoint for making the launcher executable, the launcher name "eclipse" is used to construct the path to the executable, yielding a path that doesn't exist when it is interpreted in a case-sensitive manner.

Currently, this instruction is generated:
  chmod(targetDir:${installFolder}/eclipse.app/Contents/MacOS/, targetFile:eclipse, permissions:755) 
It should however be
  chmod(targetDir:${installFolder}/Eclipse.app/Contents/MacOS/, targetFile:eclipse, permissions:755) 


This problem only occurs for unbranded products. If the product has a custom launcher name, e.g. "myrcp", the app folder is has the same capitalization, i.e. "myrcp.app". AFAIK this is uncommon on Mac - and unless we want to magically uppercase the first letter [1], the only solution is to have two launcher name properties for Mac products: one command line name e.g. "eclipse" and one for the name shown by the Finder, e.g. "Eclipse".

[1] If you think this is a good idea, you should convert "i" to uppercase with a turkish locale.
Comment 1 Tobias Oberlies CLA 2011-07-19 09:29:39 EDT
In case someone is looking for the code writing the chmod instruction, it is 
    at org.eclipse.equinox.p2.publisher.eclipse.EquinoxExecutableAction.computeInstallActions(EquinoxExecutableAction:178)
Comment 2 Tobias Oberlies CLA 2012-03-02 12:13:06 EST
Given that there is a failing PDE build test due to this problem, I applied a simple and low risk fix for this problem (91384a5 [1])

There are a lot of better ways to fix this:
- The ExecutablesDescriptor should know about the executable bit of the files it includes
- The product configuration should explicitly specify the name of the xyz.app folder in Mac

All this would however entail larger changes that I'm not comfortable doing without increased test coverage of the EquinoxExecutableAction and a way to execute these tests on a case-sensitive file system.

[1] http://git.eclipse.org/c/equinox/rt.equinox.p2.git/commit/?id=91384a5355b53e448aa8e09b48800f10e6e49f36