Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 331721 - [mac] Product Publisher does not cope with different launcher names
Summary: [mac] Product Publisher does not cope with different launcher names
Status: CLOSED DUPLICATE of bug 313997
Alias: None
Product: Equinox
Classification: Eclipse Project
Component: p2 (show other bugs)
Version: 3.6.1   Edit
Hardware: Macintosh Mac OS X - Carbon (unsup.)
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: P2 Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-02 16:20 EST by Brian de Alwis CLA
Modified: 2010-12-02 19:48 EST (History)
1 user (show)

See Also:


Attachments
Patch to BrandingIron and ExecutablesDescription (21.43 KB, patch)
2010-12-02 16:47 EST, Brian de Alwis CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brian de Alwis CLA 2010-12-02 16:20:02 EST
Builds: Eclipse R3.6.1, but the problem is still present in HEAD.  

I've been trying and failing to publish a product for cocoa-macosx-x86_64 using the ProductPublisher app.  In my case, my product has an explicit launcher name.  Although the publishing appears to work, the executables aren't properly branded, and the the app icon isn't present.

In tracing through the code, I discovered that the ExecutablesDescriptor's files list isn't properly updated for different launcher names.  #updateExecutableName() makes some incorrect file name inferences based on the executable name that don't hold for the executable features:
   1. the target .ini file looked for is "launcher.ini", when it's actually "eclipse.ini" 
   2. the app looked for is "launcher.app", when it's actually "Eclipse.app"
   3. the icon file wasn't being recorded

I discovered that this is the same problem reported in bug 325301 against Buckminster, which seems to have copied the BrandingIron from p2's publisher.

I've attached a patch that ports bug 325301's fix to org.eclipse.equinox.p2.publisher's BrandingIron (and with a minor adjustment to EquinoxExecutableAction).  I haven't been able to run any tests at the moment -- though it works in my testing.

I haven't looked at what other changes they've made.  From the history of the BrandingIron they've clearly made other changes, and they likely should be folded back in.
Comment 1 Brian de Alwis CLA 2010-12-02 16:47:05 EST
Created attachment 184413 [details]
Patch to BrandingIron and ExecutablesDescription

Port of the patch for bug 325301 to p2.publisher
Comment 2 Jeff McAffer CLA 2010-12-02 19:48:55 EST
I believe this is a dupe of bug 313997.  We should look at the patch here and patch there, the one in Buckminster and what they have done in Tycho to see if unification is possible.

*** This bug has been marked as a duplicate of bug 313997 ***