mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 14:42:11 +02:00
Bug 321259: Need to set environment dir before sourcing init file, so that we look for the init file in the right place
This commit is contained in:
parent
48b6e9207f
commit
0718dffac3
1 changed files with 24 additions and 24 deletions
|
@ -144,7 +144,30 @@ public class GDBJtagDSFFinalLaunchSequence extends Sequence {
|
||||||
|
|
||||||
requestMonitor.done();
|
requestMonitor.done();
|
||||||
}},
|
}},
|
||||||
/*
|
/*
|
||||||
|
* Specify GDB's working directory
|
||||||
|
*/
|
||||||
|
new Step() {
|
||||||
|
@Override
|
||||||
|
public void execute(final RequestMonitor requestMonitor) {
|
||||||
|
IPath dir = null;
|
||||||
|
try {
|
||||||
|
dir = fGDBBackend.getGDBWorkingDirectory();
|
||||||
|
} catch (CoreException e) {
|
||||||
|
requestMonitor.setStatus(new Status(IStatus.ERROR, Activator.PLUGIN_ID, -1, "Cannot get working directory", e)); //$NON-NLS-1$
|
||||||
|
requestMonitor.done();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (dir != null) {
|
||||||
|
fCommandControl.queueCommand(
|
||||||
|
fCommandFactory.createMIEnvironmentCD(fCommandControl.getContext(), dir.toPortableString()),
|
||||||
|
new DataRequestMonitor<MIInfo>(getExecutor(), requestMonitor));
|
||||||
|
} else {
|
||||||
|
requestMonitor.done();
|
||||||
|
}
|
||||||
|
}},
|
||||||
|
/*
|
||||||
* Source the gdbinit file specified in the launch
|
* Source the gdbinit file specified in the launch
|
||||||
*/
|
*/
|
||||||
new Step() {
|
new Step() {
|
||||||
|
@ -198,29 +221,6 @@ public class GDBJtagDSFFinalLaunchSequence extends Sequence {
|
||||||
requestMonitor.done();
|
requestMonitor.done();
|
||||||
}
|
}
|
||||||
}},
|
}},
|
||||||
/*
|
|
||||||
* Specify GDB's working directory
|
|
||||||
*/
|
|
||||||
new Step() {
|
|
||||||
@Override
|
|
||||||
public void execute(final RequestMonitor requestMonitor) {
|
|
||||||
IPath dir = null;
|
|
||||||
try {
|
|
||||||
dir = fGDBBackend.getGDBWorkingDirectory();
|
|
||||||
} catch (CoreException e) {
|
|
||||||
requestMonitor.setStatus(new Status(IStatus.ERROR, Activator.PLUGIN_ID, -1, "Cannot get working directory", e)); //$NON-NLS-1$
|
|
||||||
requestMonitor.done();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (dir != null) {
|
|
||||||
fCommandControl.queueCommand(
|
|
||||||
fCommandFactory.createMIEnvironmentCD(fCommandControl.getContext(), dir.toPortableString()),
|
|
||||||
new DataRequestMonitor<MIInfo>(getExecutor(), requestMonitor));
|
|
||||||
} else {
|
|
||||||
requestMonitor.done();
|
|
||||||
}
|
|
||||||
}},
|
|
||||||
/*
|
/*
|
||||||
* Specify environment variables if needed
|
* Specify environment variables if needed
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue