Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] Building product for OSX

Thanks, so the directory structure is correct.
However, when the application is run (with the ini file elsewhere) we get an error message about some companion library not being found. It seems that the launcher needs to be told where to find the ini file.
From the command line this would be the --launcher.ini <path> argument, but how do I get tycho to generate something that passes the argument with the correct path to the launcher?

On Tue, Aug 4, 2015 at 2:38 PM, David M Williams <david_williams@xxxxxxxxxx> wrote:
The change of location of the ini file has so do with changing rules from Apple about how an App is signed.
See their document near
https://developer.apple.com/library/mac/technotes/tn2206/_index.html#//apple_ref/doc/uid/DTS40007919-CH1-TNTAG300
(Plus, there are number of bugs in CBI component that discuss this change in signing rules).

The ini file should not be in the same directory as the launcher (it is not a bug) ... the ini file is considered a resource file, and hence should be with other resource files.
If the ini file is in the same directory as the launcher, then it can not be signed.




From:        Lutz Wrage <lutz.wrage@xxxxxxxxx>
To:        Tycho user list <tycho-user@xxxxxxxxxxx>,
Date:        08/04/2015 09:44 AM
Subject:        [tycho-user] Building product for OSX
Sent by:        tycho-user-bounces@xxxxxxxxxxx




I am building an eclipse based product for win32, linux, and macosx. Until tycho 0.22.0 the maxosx build worked just fine by adding the corresponding environment to the tycho target-platform configuration plugin.
With tycho 0.23.{0,1} the directory structure in the zip file has changed such that the launcher (osate) and the corresponding ini file (osate.ini) are no longer in the same directory so the launcher can't run. They used to be in a subdir MacOS.
I also tried to switch to building an app bundle by using the following pom elements:
1. Set macosx-bundled to true

            <plugin>
                <groupId>org.eclipse.tycho</groupId>
                <artifactId>tycho-p2-repository-plugin</artifactId>
                <version>${tycho.version}</version>
                <configuration>
                    <profileProperties>
                        <macosx-bundled>true</macosx-bundled>
                    </profileProperties>
                </configuration>
            </plugin>

2. Set macosx root folder

            <plugin>
                <groupId>org.eclipse.tycho</groupId>
                <artifactId>tycho-p2-director-plugin</artifactId>
                <version>${tycho.version}</version>
                <executions>
                    <execution>
                        <id>materialize-products</id>
                        <goals>
                            <goal>materialize-products</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>archive-products</id>
                        <goals>
                            <goal>archive-products</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <formats>
                        <win32>zip</win32>
                        <linux>tar.gz</linux>
                        <macosx>tar.gz</macosx>
                    </formats>
                    <products>
                        <product>
                            <id>osate2</id>
                            <archiveFileName>${
product.id}-${unqualifiedVersion}-${buildQualifier}</archiveFileName>
                            <rootFolders>
                                <rootFolder>${
product.id}</rootFolder>
                                <macosx>${
product.id}.app</macosx>
                            </rootFolders>
                        </product>
                    </products>
                </configuration>
            </plugin>

The resulting directory structure looks like a macosx app bundle BUT the ini file is still not in the same directory as the launcher.

osate2.app/
└── Contents
   ├──
Eclipse
   │   ├──
configuration
   │   ├──
features
   │   ├──
p2
   │   ├──
plugins
   │   ├── artifacts.xml
   │   ├── epl-v10.html
   │   └── osate.ini
   ├──
MacOS
   │   └──
osate
   └── Info.plist

Am I missing some configuration or is this a bug?

Thanks!_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/tycho-user


_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/tycho-user


Back to the top