Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 248767
Collapse All | Expand All

(-)src/org/eclipse/pde/internal/build/builder/ClasspathComputer3_0.java (-1 / +2 lines)
Lines 180-186 Link Here
180
		String root = generator.getLocation(model);
180
		String root = generator.getLocation(model);
181
		IPath base = Utils.makeRelative(new Path(root), new Path(baseLocation));
181
		IPath base = Utils.makeRelative(new Path(root), new Path(baseLocation));
182
		Properties modelProps = getBuildPropertiesFor(model);
182
		Properties modelProps = getBuildPropertiesFor(model);
183
		ModelBuildScriptGenerator.specialDotProcessing(modelProps, libraries);
183
		if (modelProps != AbstractScriptGenerator.MissingProperties.getInstance())
184
			ModelBuildScriptGenerator.specialDotProcessing(modelProps, libraries);
184
		for (int i = 0; i < libraries.length; i++) {
185
		for (int i = 0; i < libraries.length; i++) {
185
			addDevEntries(model, baseLocation, classpath, Utils.getArrayFromString(modelProps.getProperty(PROPERTY_OUTPUT_PREFIX + libraries[i])), modelProps);
186
			addDevEntries(model, baseLocation, classpath, Utils.getArrayFromString(modelProps.getProperty(PROPERTY_OUTPUT_PREFIX + libraries[i])), modelProps);
186
			addPathAndCheck(model, base, libraries[i], modelProps, classpath);
187
			addPathAndCheck(model, base, libraries[i], modelProps, classpath);
(-)src/org/eclipse/pde/build/internal/tests/ScriptGenerationTests.java (+23 lines)
Lines 653-656 Link Here
653
		}
653
		}
654
		assertLogContainsLines(buildFolder.getFile("log.log"), new String [] {"Problem occurred while considering plugin: Test Bundle org.foo.", "invalid format"});
654
		assertLogContainsLines(buildFolder.getFile("log.log"), new String [] {"Problem occurred while considering plugin: Test Bundle org.foo.", "invalid format"});
655
	}
655
	}
656
657
	public void testBug248767() throws Exception {
658
		IFolder rootFolder = newTest("248767");
659
660
		// Build 1 creates a binary version of A
661
		IFolder build1 = rootFolder.getFolder("build1");
662
		Utils.generateFeature(build1, "F1", null, new String[] {"A;unpack=true", "org.eclipse.osgi"});
663
		Properties properties = BuildConfiguration.getBuilderProperties(build1);
664
		properties.put("topLevelElementId", "F1");
665
		properties.put("archivesFormat", "*,*,*-folder");
666
		Utils.storeBuildProperties(build1, properties);
667
		runBuild(build1);
668
		build1.refreshLocal(IResource.DEPTH_INFINITE, null);
669
		
670
		//Build 2 compiles B against binary A
671
		IFolder build2 = rootFolder.getFolder("build2");
672
		Utils.generateFeature(build2, "F2", null, new String[] {"A", "B"});
673
		properties = BuildConfiguration.getBuilderProperties(build2);
674
		properties.put("topLevelElementId", "F2");
675
		properties.put("baseLocation", build1.getFolder("tmp/eclipse").getLocation().toOSString());
676
		Utils.storeBuildProperties(build2, properties);
677
		runBuild(build2);
678
	}
656
}
679
}
(-)resources/248767/build1/plugins/A/library/a/Activator.java (+35 lines)
Added Link Here
1
package a;
2
3
import org.osgi.framework.BundleContext;
4
5
/**
6
 * The activator class controls the plug-in life cycle
7
 */
8
public class Activator {
9
	private static BundleContext myContext = null;
10
	private static Application myApplication = null;
11
	
12
	/**
13
	 * The constructor
14
	 */
15
	private Activator() {
16
	}
17
18
	/*
19
	 * (non-Javadoc)
20
	 * @see org.eclipse.core.runtime.Plugins#start(org.osgi.framework.BundleContext)
21
	 */
22
	public void start(BundleContext context) throws Exception {
23
		myContext = context;
24
		myApplication = new Application();
25
	}
26
	
27
	public static BundleContext getContext() {
28
		return myContext;
29
	}
30
	
31
	public static Application getApplication() {
32
		return myApplication;
33
	}
34
35
}
(-)resources/248767/build2/plugins/B/.classpath (+7 lines)
Added Link Here
1
<?xml version="1.0" encoding="UTF-8"?>
2
<classpath>
3
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
4
	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
5
	<classpathentry kind="src" path="src"/>
6
	<classpathentry kind="output" path="bin"/>
7
</classpath>
(-)resources/248767/build1/plugins/A/src/a/Application.java (+24 lines)
Added Link Here
1
package a;
2
3
import org.eclipse.osgi.service.runnable.ParameterizedRunnable;
4
5
/**
6
 * This class controls all aspects of the application's execution
7
 */
8
public class Application implements ParameterizedRunnable {
9
10
	/* (non-Javadoc)
11
	 * @see org.eclipse.equinox.app.IApplication#start(org.eclipse.equinox.app.IApplicationContext)
12
	 */
13
	public Object run(Object context) {
14
		System.out.println("Hello RCP World!");
15
		return null;
16
	}
17
18
	/* (non-Javadoc)
19
	 * @see org.eclipse.equinox.app.IApplication#stop()
20
	 */
21
	public void stop() {
22
		// nothing to do
23
	}
24
}
(-)resources/248767/build1/plugins/A/.project (+28 lines)
Added Link Here
1
<?xml version="1.0" encoding="UTF-8"?>
2
<projectDescription>
3
	<name>A</name>
4
	<comment></comment>
5
	<projects>
6
	</projects>
7
	<buildSpec>
8
		<buildCommand>
9
			<name>org.eclipse.jdt.core.javabuilder</name>
10
			<arguments>
11
			</arguments>
12
		</buildCommand>
13
		<buildCommand>
14
			<name>org.eclipse.pde.ManifestBuilder</name>
15
			<arguments>
16
			</arguments>
17
		</buildCommand>
18
		<buildCommand>
19
			<name>org.eclipse.pde.SchemaBuilder</name>
20
			<arguments>
21
			</arguments>
22
		</buildCommand>
23
	</buildSpec>
24
	<natures>
25
		<nature>org.eclipse.pde.PluginNature</nature>
26
		<nature>org.eclipse.jdt.core.javanature</nature>
27
	</natures>
28
</projectDescription>
(-)resources/248767/build2/plugins/B/META-INF/MANIFEST.MF (+10 lines)
Added Link Here
1
Manifest-Version: 1.0
2
Bundle-ManifestVersion: 2
3
Bundle-Name: B Plug-in
4
Bundle-SymbolicName: B
5
Bundle-Version: 1.0.0
6
Bundle-Activator: b.Activator
7
Require-Bundle: A;bundle-version="1.0.0",
8
 org.eclipse.osgi;bundle-version="3.5.0"
9
Bundle-RequiredExecutionEnvironment: J2SE-1.5
10
Bundle-ActivationPolicy: lazy
(-)resources/248767/build1/plugins/A/plugin.xml (+15 lines)
Added Link Here
1
<?xml version="1.0" encoding="UTF-8"?>
2
<?eclipse version="3.2"?>
3
<plugin>
4
5
   <extension
6
         id="application"
7
         point="org.eclipse.core.runtime.applications">
8
      <application>
9
         <run
10
               class="a.Application">
11
         </run>
12
      </application>
13
   </extension>
14
15
</plugin>
(-)resources/248767/build2/plugins/B/.project (+28 lines)
Added Link Here
1
<?xml version="1.0" encoding="UTF-8"?>
2
<projectDescription>
3
	<name>B</name>
4
	<comment></comment>
5
	<projects>
6
	</projects>
7
	<buildSpec>
8
		<buildCommand>
9
			<name>org.eclipse.jdt.core.javabuilder</name>
10
			<arguments>
11
			</arguments>
12
		</buildCommand>
13
		<buildCommand>
14
			<name>org.eclipse.pde.ManifestBuilder</name>
15
			<arguments>
16
			</arguments>
17
		</buildCommand>
18
		<buildCommand>
19
			<name>org.eclipse.pde.SchemaBuilder</name>
20
			<arguments>
21
			</arguments>
22
		</buildCommand>
23
	</buildSpec>
24
	<natures>
25
		<nature>org.eclipse.pde.PluginNature</nature>
26
		<nature>org.eclipse.jdt.core.javanature</nature>
27
	</natures>
28
</projectDescription>
(-)resources/248767/build1/plugins/A/.classpath (+8 lines)
Added Link Here
1
<?xml version="1.0" encoding="UTF-8"?>
2
<classpath>
3
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
4
	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
5
	<classpathentry kind="src" path="src"/>
6
	<classpathentry kind="src" output="bin_lib" path="library"/>
7
	<classpathentry kind="output" path="bin"/>
8
</classpath>
(-)resources/248767/build2/plugins/B/build.properties (+4 lines)
Added Link Here
1
source.. = src/
2
output.. = bin/
3
bin.includes = META-INF/,\
4
               .
(-)resources/248767/build2/plugins/B/src/b/Activator.java (+20 lines)
Added Link Here
1
package b;
2
3
import org.osgi.framework.BundleContext;
4
5
import a.Application;
6
7
/**
8
 * The activator class controls the plug-in life cycle
9
 */
10
public class Activator {
11
	/**
12
	 * The constructor
13
	 */
14
	public Activator() {
15
		BundleContext context = a.Activator.getContext();
16
		context.getBundle();
17
		Application app = new Application();
18
		app.run(null);
19
	}
20
}
(-)resources/248767/build1/plugins/A/build.properties (+10 lines)
Added Link Here
1
source.. = src/
2
output.. = bin/
3
bin.includes = plugin.xml,\
4
               META-INF/,\
5
               .,\
6
               library.jar
7
jars.compile.order = .,\
8
                     library.jar
9
source.library.jar = library/
10
output.library.jar = bin_lib/
(-)resources/248767/build1/plugins/A/META-INF/MANIFEST.MF (+11 lines)
Added Link Here
1
Manifest-Version: 1.0
2
Bundle-ManifestVersion: 2
3
Bundle-Name: A Plug-in
4
Bundle-SymbolicName: A; singleton:=true
5
Bundle-Version: 1.0.0
6
Bundle-Activator: a.Activator
7
Bundle-ClassPath: ., library.jar
8
Bundle-RequiredExecutionEnvironment: J2SE-1.5
9
Bundle-ActivationPolicy: lazy
10
Export-Package: a
11
Require-Bundle: org.eclipse.osgi;bundle-version="3.5.0"

Return to bug 248767