Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Equinox Initializer

Equinox Initializer

(largely from initializers.exsd) Equinox allows plugins to be initialized if they so choose. Plugins that need to be initialized should provide an extension to the org.eclipse.equinox.initializer.initializers extension point. The initializers are run when the org.eclipse.equinox.initializer.configInitializer application is being run. The order in which the initializers are run is not guaranteed to be consistent.

FileInitializer Example

This initializer application extracts files to their "localURL" -- that is, the location on the filesystem where they will be extracted by Equinox. The files will be extracted to <eclipse-home>/configuration/org.eclipse.osgi/bundles/<bundle ID>/<#>/.cp.

The filename patterns that you want to extract should be specified in a file in a properties format like this:

<bundle name regex> = <filename regex>

For example, to extract all HTML files from the org.eclipse.team.core.cvs bundle, all files ending with .so in all bundles, and all files named about.html in all bundles, the properties file would look like this:

.* = *.so,about.html
org.eclipse.team.core.cvs = *.html

This application should be run through the generic initializer mechanism and not run directly.

Here is how to run this application from outside Eclipse:

java -cp startup.jar org.eclipse.core.launcher.Main
     -application org.eclipse.equinox.initializer.configInitializer
     [-justThisArchOSWS]
     -fileInitializer <fileWithFilePatternsToExtract>

Note: Files that are extracted will be printed to the console.

CVS

The FileInitializer is in currently in the Equinox Incubator in CVS here:

:pserver:anonymous@dev.eclipse.org/cvsroot/eclipse co equinox-incubator/org.eclipse.equinox.initializer

Download

The FileInitializer is available for download from the incubator section of the equinox download page.

Linux Distribution Packaging Use Case

Many of the Linux distributions that currently ship the Eclipse SDK use this application to extract shared libraries from SWT and other fragments that contain JNI shared libraries. This is done to avoid having the shared libraries extracted to the user's home directory. For more information, see bug 90535.

Note: The use of this initializer creates a default configuration which may limit the functionality for Eclipse users who do not have write permissions for <eclipse-home>/configuration. To get around this problem, it is necessary to delete everything in this configuration area except for config.ini and the files which are extracted into org.eclipse.osgi.

Back to the top