# HG changeset patch # User timkelly # Date 1267730206 21600 # Node ID 27b0f877c86eb44e37674893bc19ff49fba452d3 # Parent 326a4daf12798148719295943186f492523dd56b Fix bug 10835. diff -r 326a4daf1279 -r 27b0f877c86e project/com.nokia.carbide.cpp.project.ui/src/com/nokia/carbide/cpp/internal/project/ui/sharedui/BuilderSelectionComposite.java --- a/project/com.nokia.carbide.cpp.project.ui/src/com/nokia/carbide/cpp/internal/project/ui/sharedui/BuilderSelectionComposite.java Wed Mar 03 14:14:55 2010 -0600 +++ b/project/com.nokia.carbide.cpp.project.ui/src/com/nokia/carbide/cpp/internal/project/ui/sharedui/BuilderSelectionComposite.java Thu Mar 04 13:16:46 2010 -0600 @@ -16,12 +16,11 @@ */ package com.nokia.carbide.cpp.internal.project.ui.sharedui; +import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.Status; import org.eclipse.jface.dialogs.IDialogSettings; import org.eclipse.swt.SWT; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Combo; @@ -31,7 +30,6 @@ import com.nokia.carbide.cpp.internal.api.sdk.SBSv2Utils; import com.nokia.carbide.cpp.internal.project.ui.Messages; import com.nokia.carbide.cpp.internal.project.ui.ProjectUIPlugin; -import com.nokia.carbide.cpp.internal.sdk.core.model.SDKManager; import com.nokia.carbide.cpp.sdk.core.SDKCorePlugin; import com.nokia.carbide.cpp.sdk.ui.shared.BuildTargetsPage; @@ -88,11 +86,17 @@ IStatus status = null; if (builderCombo != null && builderCombo.getSelectionIndex() == 1) { + IPath sbsBinPath = SBSv2Utils.getSBSBinDirectory(); + // if SBSv2 is selected, make sure SBS_HOME is defined if (SBSv2Utils.getSBSBinDirectory() == null){ status = new Status(Status.ERROR, ProjectUIPlugin.PLUGIN_ID, "SBS_HOME environment variable is not defined. Carbide needs this variable to find the base SBS install."); } + // check to see if SBS_HOME directory really exists + else if (!sbsBinPath.toFile().exists()){ + status = new Status(Status.ERROR, ProjectUIPlugin.PLUGIN_ID, "SBS_HOME environment variable path does not exist: " + sbsBinPath.toOSString()); + } // check the raptor version else if (SDKCorePlugin.getSDKManager().getSBSv2Version(false).getMajor() == 0){ // Try to scan again....