Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build debuggees for CodeAnalysis #1450

Merged
merged 1 commit into from
Apr 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions eng/pipelines/templates/CodeAnalysis.template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ steps:

- template: ../tasks/CredScan.yml

- template: ../steps/BuildSolution.yml
parameters:
Solution: '$(Build.SourcesDirectory)\test\CppTests\debuggees\sln\debuggees.sln'
Configuration: 'Debug'
OneESPT: false

- task: DownloadPipelineArtifact@2
displayName: Download Pipeline Artifact
inputs:
Expand Down
5 changes: 5 additions & 0 deletions test/CppTests/debuggees/sln/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# sln folder for debuggees

This folder is used for compliance only.
This will build native files with Visual Studio that will be used
to be scanned for CodeQL.
107 changes: 107 additions & 0 deletions test/CppTests/debuggees/sln/debuggees.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hello", "hello\hello.vcxproj", "{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "exception", "exception\exception.vcxproj", "{DACA1CDE-23F8-487E-80AD-3092B08408FA}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "kitchensink", "kitchensink\kitchensink.vcxproj", "{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "natvis", "natvis\natvis.vcxproj", "{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sharedlib", "sharedlib\sharedlib.vcxproj", "{440C02EE-BE4E-497E-9611-ED2624441EC6}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "sourcemap", "sourcemap\sourcemap.vcxproj", "{30C2C825-3FA4-45D3-94CD-880FF8001B82}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Debug|Any CPU.ActiveCfg = Debug|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Debug|Any CPU.Build.0 = Debug|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Debug|x64.ActiveCfg = Debug|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Debug|x64.Build.0 = Debug|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Debug|x86.ActiveCfg = Debug|Win32
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Debug|x86.Build.0 = Debug|Win32
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Release|Any CPU.ActiveCfg = Release|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Release|Any CPU.Build.0 = Release|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Release|x64.ActiveCfg = Release|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Release|x64.Build.0 = Release|x64
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Release|x86.ActiveCfg = Release|Win32
{6CA48F21-AF81-4A33-9BBA-0C8132482FF4}.Release|x86.Build.0 = Release|Win32
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Debug|Any CPU.ActiveCfg = Debug|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Debug|Any CPU.Build.0 = Debug|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Debug|x64.ActiveCfg = Debug|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Debug|x64.Build.0 = Debug|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Debug|x86.ActiveCfg = Debug|Win32
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Debug|x86.Build.0 = Debug|Win32
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Release|Any CPU.ActiveCfg = Release|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Release|Any CPU.Build.0 = Release|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Release|x64.ActiveCfg = Release|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Release|x64.Build.0 = Release|x64
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Release|x86.ActiveCfg = Release|Win32
{DACA1CDE-23F8-487E-80AD-3092B08408FA}.Release|x86.Build.0 = Release|Win32
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Debug|Any CPU.ActiveCfg = Debug|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Debug|Any CPU.Build.0 = Debug|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Debug|x64.ActiveCfg = Debug|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Debug|x64.Build.0 = Debug|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Debug|x86.ActiveCfg = Debug|Win32
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Debug|x86.Build.0 = Debug|Win32
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Release|Any CPU.ActiveCfg = Release|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Release|Any CPU.Build.0 = Release|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Release|x64.ActiveCfg = Release|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Release|x64.Build.0 = Release|x64
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Release|x86.ActiveCfg = Release|Win32
{4B56DB42-CBDF-4D0B-A344-83FDF5B502A6}.Release|x86.Build.0 = Release|Win32
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Debug|Any CPU.ActiveCfg = Debug|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Debug|Any CPU.Build.0 = Debug|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Debug|x64.ActiveCfg = Debug|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Debug|x64.Build.0 = Debug|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Debug|x86.ActiveCfg = Debug|Win32
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Debug|x86.Build.0 = Debug|Win32
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Release|Any CPU.ActiveCfg = Release|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Release|Any CPU.Build.0 = Release|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Release|x64.ActiveCfg = Release|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Release|x64.Build.0 = Release|x64
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Release|x86.ActiveCfg = Release|Win32
{A1EB57C0-004A-41D5-BBF0-9E31B53DEF7B}.Release|x86.Build.0 = Release|Win32
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Debug|Any CPU.ActiveCfg = Debug|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Debug|Any CPU.Build.0 = Debug|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Debug|x64.ActiveCfg = Debug|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Debug|x64.Build.0 = Debug|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Debug|x86.ActiveCfg = Debug|Win32
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Debug|x86.Build.0 = Debug|Win32
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Release|Any CPU.ActiveCfg = Release|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Release|Any CPU.Build.0 = Release|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Release|x64.ActiveCfg = Release|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Release|x64.Build.0 = Release|x64
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Release|x86.ActiveCfg = Release|Win32
{440C02EE-BE4E-497E-9611-ED2624441EC6}.Release|x86.Build.0 = Release|Win32
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Debug|Any CPU.ActiveCfg = Debug|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Debug|Any CPU.Build.0 = Debug|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Debug|x64.ActiveCfg = Debug|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Debug|x64.Build.0 = Debug|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Debug|x86.ActiveCfg = Debug|Win32
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Debug|x86.Build.0 = Debug|Win32
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Release|Any CPU.ActiveCfg = Release|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Release|Any CPU.Build.0 = Release|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Release|x64.ActiveCfg = Release|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Release|x64.Build.0 = Release|x64
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Release|x86.ActiveCfg = Release|Win32
{30C2C825-3FA4-45D3-94CD-880FF8001B82}.Release|x86.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {A012557E-A900-406D-A59E-9EFC180EA5BB}
EndGlobalSection
EndGlobal
139 changes: 139 additions & 0 deletions test/CppTests/debuggees/sln/exception/exception.vcxproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>17.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{daca1cde-23f8-487e-80ad-3092b08408fa}</ProjectGuid>
<RootNamespace>exception</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\exception\src\exception.cpp" />
<ClCompile Include="..\..\exception\src\main.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\exception\src\exception.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
30 changes: 30 additions & 0 deletions test/CppTests/debuggees/sln/exception/exception.vcxproj.filters
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\exception\src\exception.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\..\exception\src\main.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\exception\src\exception.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
</Project>
Loading
Loading