Exemple #1
0
 private static void AddSourceFiles(IDebuggee debuggee)
 {
     debuggee.AddSourceFiles(
         SourceMappingHelper.Main,
         Path.Combine(SourceMappingHelper.WriterFolder, SourceMappingHelper.Writer),
         Path.Combine(SourceMappingHelper.ManagerFolder, SourceMappingHelper.Manager));
 }
Exemple #2
0
        /// <summary>
        /// Compile the shared library
        /// </summary>
        private void CompileSharedLib(ITestSettings settings, int debuggeeMoniker)
        {
            IDebuggee debuggee = Debuggee.Create(this, settings.CompilerSettings, debuggeeName, debuggeeMoniker, outLibName, CompilerOutputType.SharedLibrary);

            debuggee.AddSourceFiles(srcLibName);
            debuggee.Compile();
        }
Exemple #3
0
 /// <summary>
 /// Create the debuggee and compile the application
 /// </summary>
 private static IDebuggee CompileApp(ILoggingComponent logger, ITestSettings settings, int debuggeeMoniker)
 {
     lock (syncObject)
     {
         IDebuggee debuggee = Debuggee.Create(logger, settings.CompilerSettings, debuggeeName, debuggeeMoniker, outAppName);
         debuggee.AddSourceFiles(srcClassName, srcAppName);
         debuggee.Compile();
         return(debuggee);
     }
 }
Exemple #4
0
        public void CompileHelloDebuggee(ITestSettings settings)
        {
            this.TestPurpose("Create and compile the 'hello' debuggee");
            this.WriteSettings(settings);

            IDebuggee debuggee = Debuggee.Create(this, settings.CompilerSettings, HelloName, DebuggeeMonikers.HelloWorld.Sample);

            debuggee.AddSourceFiles(HelloSourceName);
            debuggee.Compile();
        }
Exemple #5
0
        private void CompileSharedLib(ITestSettings settings, int debuggeeMoniker, bool symbol)
        {
            IDebuggee debuggee = Debuggee.Create(this, settings.CompilerSettings, Name, debuggeeMoniker, OutLibName, CompilerOutputType.SharedLibrary);

            debuggee.AddSourceFiles(SrcLibName);
            debuggee.CompilerOptions = CompilerOption.OptimizeLevel2;
            if (symbol)
            {
                debuggee.CompilerOptions = CompilerOption.GenerateSymbols;
            }
            debuggee.Compile();
        }
Exemple #6
0
 private static void AddSourceFiles(IDebuggee debuggee)
 {
     // Add a source files, specify type, compile
     debuggee.AddSourceFiles(
         SinkHelper.Main,
         SinkHelper.Arguments,
         SinkHelper.Calling,
         SinkHelper.Environment,
         SinkHelper.Feature,
         SinkHelper.Threading,
         SinkHelper.NonTerminating,
         SinkHelper.Expression);
     debuggee.CompilerOptions |= CompilerOption.SupportThreading;
 }
Exemple #7
0
        private void CompileApp(ITestSettings settings, int debuggeeMoniker)
        {
            IDebuggee debuggee = Debuggee.Open(this, settings.CompilerSettings, Name, debuggeeMoniker, null, CompilerOutputType.Executable);

            switch (settings.DebuggerSettings.DebuggerType)
            {
            case SupportedDebugger.Gdb_Cygwin:
            case SupportedDebugger.Gdb_Gnu:
            case SupportedDebugger.Lldb:
                debuggee.AddLibraries("dl");
                break;
            }

            debuggee.AddSourceFiles(SourceName, UserDefinedClassName);
            debuggee.CompilerOptions = CompilerOption.OptimizeLevel2;
            debuggee.CompilerOptions = CompilerOption.GenerateSymbols;
            debuggee.Compile();
        }
Exemple #8
0
        /// <summary>
        /// Compile the application
        /// </summary>
        private void CompileApp(ITestSettings settings, int debuggeeMoniker)
        {
            IDebuggee debuggee = Debuggee.Open(this, settings.CompilerSettings, debuggeeName, debuggeeMoniker, outAppName);

            switch (settings.DebuggerSettings.DebuggerType)
            {
            case SupportedDebugger.Gdb_Cygwin:
            case SupportedDebugger.Gdb_Gnu:
            case SupportedDebugger.Lldb:
                debuggee.AddLibraries("dl");
                break;

            case SupportedDebugger.Gdb_MinGW:
                // The sharedlib debuggee contains both POSIX and Windows support on loading dynamic library, we use "_MinGW" to identify the relevant testing code
                debuggee.AddDefineConstant("_MINGW");
                break;
            }

            debuggee.AddSourceFiles(srcAppName);

            debuggee.Compile();
        }