This repository was archived by the owner on Nov 11, 2024. It is now read-only.
File tree 4 files changed +31
-13
lines changed
4 files changed +31
-13
lines changed Original file line number Diff line number Diff line change @@ -68,9 +68,9 @@ to package SDB releases.
68
68
Additionally, ` MODE ` can be set to ` Debug ` (default) or ` Release ` to indicate
69
69
the kind of build desired.
70
70
71
- Finally, ` MONO_PREFIX ` can be set to tell the test runner which Mono executable
72
- should be used. See the description of ` RuntimePrefix ` further down for more
73
- information.
71
+ Finally, ` MONO_PREFIX ` and ` MONO_BINARY ` can be set to tell the test runner
72
+ which Mono executable should be used. See the description of ` RuntimePrefix `
73
+ and ` RuntimeExecutable ` further down for more information.
74
74
75
75
## Usage
76
76
@@ -189,6 +189,13 @@ will want to set it to something like `C:\Program Files (x86)\Mono-3.0.10`.
189
189
Or if you have Mono in some other directory, you might set it to e.g.
190
190
` /opt/mono ` .
191
191
192
+ The ` RuntimeExecutable ` element is another way to specify which Mono executable
193
+ to use. If ` RuntimePrefix ` is empty, then ` RuntimeExecutable ` is taken as the
194
+ full path to the Mono executable. If both elements are non-empty, they are
195
+ combined as ` Path.Combine(RuntimePrefix, "bin", RuntimeExecutable) ` . This
196
+ configuration element is useful for switching between ` mono32 ` and ` mono64 ` on
197
+ OS X in particular.
198
+
192
199
You may want to set ` DisableColors ` to ` true ` if you don't want the fancy ANSI
193
200
color codes that SDB emits.
194
201
Original file line number Diff line number Diff line change @@ -81,13 +81,16 @@ let runTest () =
81
81
for _ in 1 .. 3 do
82
82
recv proc |> ignore
83
83
84
- // Set the `RuntimePrefix` to `MONO_PREFIX` as
85
- // specified in the `Makefile`.
84
+ // Set runtime location options from the `Makefile`.
86
85
let prefix = Environment.GetEnvironmentVariable( " MONO_PREFIX" )
86
+ let exec = Environment.GetEnvironmentVariable( " MONO_BINARY" )
87
87
88
88
send proc ( " config set RuntimePrefix " + prefix)
89
89
recv proc |> ignore
90
90
91
+ send proc ( " config set RuntimeExecutable " + exec)
92
+ recv proc |> ignore
93
+
91
94
let mutable ex = null
92
95
93
96
try
Original file line number Diff line number Diff line change @@ -79,6 +79,8 @@ public sealed class Configuration
79
79
80
80
public bool PreferDisassembly { get ; set ; }
81
81
82
+ public string RuntimeExecutable { get ; set ; }
83
+
82
84
public string RuntimePrefix { get ; set ; }
83
85
84
86
public bool SaveDatabaseAutomatically { get ; set ; }
@@ -157,6 +159,9 @@ public static bool Read()
157
159
158
160
if ( Current . DefaultDatabaseFile == null )
159
161
Current . DefaultDatabaseFile = string . Empty ;
162
+
163
+ if ( Current . RuntimeExecutable == null )
164
+ Current . RuntimeExecutable = string . Empty ;
160
165
}
161
166
}
162
167
catch ( Exception ex )
@@ -198,6 +203,7 @@ public static void Defaults()
198
203
Current . MaxConnectionAttempts = 1 ;
199
204
Current . MemberEvaluationTimeout = 5000 ;
200
205
Current . RuntimePrefix = "/usr" ;
206
+ Current . RuntimeExecutable = string . Empty ;
201
207
Current . StepOverPropertiesAndOperators = true ;
202
208
203
209
var defs = Current . Extra . Select ( kvp => Tuple . Create ( kvp . Key , kvp . Value . Item1 , kvp . Value . Item2 ) ) ;
Original file line number Diff line number Diff line change @@ -410,17 +410,19 @@ public static void Run(FileInfo file)
410
410
_debuggeeKilled = false ;
411
411
_kind = SessionKind . Launched ;
412
412
413
- var info = new SoftDebuggerStartInfo ( Configuration . Current . RuntimePrefix ,
414
- new Dictionary < string , string > ( EnvironmentVariables ) )
413
+ var args = new SoftDebuggerLaunchArgs ( Configuration . Current . RuntimePrefix ,
414
+ new Dictionary < string , string > ( EnvironmentVariables ) )
415
+ {
416
+ MonoExecutableFileName = Configuration . Current . RuntimeExecutable ,
417
+ MaxConnectionAttempts = Configuration . Current . MaxConnectionAttempts ,
418
+ TimeBetweenConnectionAttempts = Configuration . Current . ConnectionAttemptInterval
419
+ } ;
420
+
421
+ var info = new SoftDebuggerStartInfo ( args )
415
422
{
416
423
Command = file . FullName ,
417
424
Arguments = Arguments ,
418
- WorkingDirectory = WorkingDirectory ,
419
- StartArgs =
420
- {
421
- MaxConnectionAttempts = Configuration . Current . MaxConnectionAttempts ,
422
- TimeBetweenConnectionAttempts = Configuration . Current . ConnectionAttemptInterval
423
- }
425
+ WorkingDirectory = WorkingDirectory
424
426
} ;
425
427
426
428
// We need to ignore `SIGINT` while we start the inferior
You can’t perform that action at this time.
0 commit comments