| Summary: | symbolic link missing from "Mac packages" | ||
|---|---|---|---|
| Product: | [Technology] EPP | Reporter: | David Williams <david_williams> |
| Component: | Packager | Assignee: | Project Inbox <epp.packager-inbox> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | beth, gunnar, manderse, mknauer |
| Version: | 4.4.0 | ||
| Target Milestone: | 4.4.0M6 | ||
| Hardware: | PC | ||
| OS: | Mac OS X | ||
| Whiteboard: | |||
|
Description
David Williams
Bug 402052 describes what we in the Eclipse Platform learned about this issue. It include a link back to the "root problem" in some core code Tycho makes use of: http://jira.codehaus.org/browse/PLXCOMP-207 The "key" is to examine your actual "target" on build machine, to see if the symbolic link exists there, and if so, sounds like it is the same issue, and is simply a matter of using a different "archiver" than the one Tycho uses. We, in Platform, simply use 'tar' (literally, on Linux) in a "post build" step to tar up the target directory, since it maintains symbolic links (by default), and "throw away" the tar created by Tycho/Maven (for Mac's). To be concrete, see http://git.eclipse.org/c/platform/eclipse.platform.releng.aggregator.git/tree/production/build-functions.shsource#n766 Ideally this could be a "post packaging" step in your Tycho/Maven scripts and use "antrun" plugin, but even then your ant script may have to call out to native tar command using 'exec' ... since I don't think Ant's tar task natively supports symbolic links either? (see apache bug https://issues.apache.org/bugzilla/show_bug.cgi?id=15244). [I would have sworn I saw a release note recently that limitation had been fixed ... but could not find it with any easy google search and instead found these old apache bug reports. So if you find out differently, let us know :) ] Setting target milestone to 4.4M6 - I didn't find the time to solve this in time for M5. *** Bug 427827 has been marked as a duplicate of this bug. *** *** Bug 424488 has been marked as a duplicate of this bug. *** Testing required. The solution creates tar.gz archives that contain correct symbolic links. It replaces tycho-p2-director:archive-products (which doesn't work) with a Bash shell script that is executed within the Maven build only if the build is running on a Unix operating system (where we can safely assume that tar, gzip, and zip work). After some investigation I had to find out that no Java build tool is able to create anything that looks like a valid tar archive including symlinks, not Maven, not Ant, ... commit d237984161d39db3ee24ab5438f08194b7426aed commit ecf0e2310eeed9b30305606ecdf79db5ad77115b > After some investigation I had to find out that no Java > build tool is able to create anything that looks like a valid tar archive > including symlinks, not Maven, not Ant, ... > In bug 402052 comment 14, Jan Sievers has pointed to bug tycho bug 429809 ... "may eventually provide a more general solution" (based on Apache's commons compress and Java 7 file nio). Just FYI. Works! I can now launch from Mac command line again. Great! Thanks for testing/reporting back! |