{"id":5877,"date":"2020-04-03T12:55:49","date_gmt":"2020-04-03T19:55:49","guid":{"rendered":"https:\/\/visualgdb.com\/w\/?p=5877"},"modified":"2020-10-22T13:37:20","modified_gmt":"2020-10-22T20:37:20","slug":"visualgdb-project-type-overview","status":"publish","type":"post","link":"https:\/\/visualgdb.com\/documentation\/projects\/overview\/","title":{"rendered":"VisualGDB Project Type Overview"},"content":{"rendered":"<h2>Overview<\/h2>\n<p>This page provides an overview of various VisualGDB project types. We will explain the advantages and limitations of those types, and will show how to understand the type of your existing project. You can find an overview of the most commonly used project types below:<\/p>\n<table style=\"border-collapse: collapse; width: 100%; height: 264px;\" border=\"1\">\n<tbody>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\">Project Type<\/td>\n<td style=\"width: 20%; height: 24px;\">Supported Targets<\/td>\n<td style=\"width: 20%; height: 24px;\">Build Settings Stored in<\/td>\n<td style=\"width: 20%; height: 24px;\">Build Managed by<\/td>\n<td style=\"width: 20%; height: 24px;\">Tools Needed to Build<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\"><a href=\"#msbuild\">MSBuild<\/a><\/td>\n<td style=\"width: 20%; height: 24px;\">Embedded, Linux<\/td>\n<td style=\"width: 20%; height: 24px;\"><strong>.vcxproj<\/strong> file<\/td>\n<td style=\"width: 20%; height: 24px;\">MSBuild + VisualGDB<\/td>\n<td style=\"width: 20%; height: 24px;\">Visual Studio + VisualGDB<\/td>\n<\/tr>\n<tr style=\"height: 48px;\">\n<td style=\"width: 20%; height: 48px;\"><a href=\"#make\">Legacy GNU Make<\/a><\/td>\n<td style=\"width: 20%; height: 48px;\">Embedded, Linux, Android, MinGW\/Cygwin<\/td>\n<td style=\"width: 20%; height: 48px;\">Makefile<\/td>\n<td style=\"width: 20%; height: 48px;\">GNU Make<\/td>\n<td style=\"width: 20%; height: 48px;\">GNU Make<\/td>\n<\/tr>\n<tr style=\"height: 48px;\">\n<td style=\"width: 20%; height: 48px;\"><a href=\"#cmake\">Advanced CMake<\/a><\/td>\n<td style=\"width: 20%; height: 48px;\">Embedded, Linux, Windows (import only), Android<\/td>\n<td style=\"width: 20%; height: 48px;\">CMakeLists.txt<\/td>\n<td style=\"width: 20%; height: 48px;\">CMake<\/td>\n<td style=\"width: 20%; height: 48px;\">CMake, Ninja\/Make<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\"><a href=\"#legacy\">Legacy QMake and CMake<\/a><\/td>\n<td style=\"width: 20%; height: 24px;\">Linux<\/td>\n<td style=\"width: 20%; height: 24px;\"><\/td>\n<td style=\"width: 20%; height: 24px;\">QMake\/CMake<\/td>\n<td style=\"width: 20%; height: 24px;\">QMake\/CMake<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\"><a href=\"#custom\">Custom Imported<\/a><\/td>\n<td style=\"width: 20%; height: 24px;\"><\/td>\n<td style=\"width: 20%; height: 24px;\">external files<\/td>\n<td style=\"width: 20%; height: 24px;\">external tools<\/td>\n<td style=\"width: 20%; height: 24px;\">external tools<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\"><a href=\"#mbed\">Advanced Mbed<\/a><\/td>\n<td style=\"width: 20%; height: 24px;\">Mbed<\/td>\n<td style=\"width: 20%; height: 24px;\">mbed_app.json<\/td>\n<td style=\"width: 20%; height: 24px;\">mbed-cli<\/td>\n<td style=\"width: 20%; height: 24px;\">python, mbed<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\"><a href=\"#arduino\">Advanced Arduino<\/a><\/td>\n<td style=\"width: 20%; height: 24px;\">Arduino<\/td>\n<td style=\"width: 20%; height: 24px;\"><strong>.vgdbproj<\/strong> file<\/td>\n<td style=\"width: 20%; height: 24px;\">arduino-builder.exe<\/td>\n<td style=\"width: 20%; height: 24px;\">Arduino Build Tools<\/td>\n<\/tr>\n<tr style=\"height: 24px;\">\n<td style=\"width: 20%; height: 24px;\"><a href=\"#espidf\">Advanced ESP-IDF<\/a><\/td>\n<td style=\"width: 20%; height: 24px;\">ESP32<\/td>\n<td style=\"width: 20%; height: 24px;\">component.mk\/CMakeLists.txt<\/td>\n<td style=\"width: 20%; height: 24px;\">ESP-IDF<\/td>\n<td style=\"width: 20%; height: 24px;\">ESP-IDF, CMake, Ninja<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>The <strong>legacy<\/strong> project types work by creating a VC++ project on top of the actual build scripts (e.g. <strong>Makefile<\/strong> or <strong>CMakeLists.txt<\/strong>). VisualGDB updates the underlying scripts to reflect files added via Solution Explorer, but the rest of the build settings are disconnected from the Visual Studio GUI (most can be edited via VisualGDB Project Properties).<\/p>\n<p>The <strong>advanced<\/strong> projects query the exact project structure from the underlying build system (e.g. Arduino or CMake) and render it in Solution Explorer. VisualGDB fully controls the contents of Solution Explorer for those projects and provides convenient commands and settings windows for editing various common settings.<\/p>\n<h2><a id=\"msbuild\"><\/a>MSBuild<\/h2>\n<p>The MSBuild-based projects are very similar to the regular VC++ Windows projects. VisualGDB provides its own highly optimized backend for the MSBuild system, supporting GCC, Clang IAR and Keil compilers. You can tell an MSBuild-based project by the &#8220;<strong>VisualGDB<\/strong>&#8221; platform name in Configuration Manager <strong>and<\/strong> the regular VC++ project icon: <a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/msb.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5878\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/msb.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>VisualGDB fully controls the build process of MSBuild-based projects and allows tweaking it via numerous settings in the regular VS properties windows. You can find a detailed description of the MSBuild projects on <a href=\"https:\/\/visualgdb.com\/documentation\/projects\/msbuild\/\">this page<\/a>.<\/p>\n<p>MSBuild-based projects support most properties and features of the regular Win32 projects: property sheets, per-configuration settings, custom targets, etc. We recommend using them for all new Embedded projects. If you are familiar with Visual Studio and VC++, we also recommend using MSBuild for Linux projects. Otherwise, please consider <a href=\"#cmake\">Advanced CMake<\/a>.<\/p>\n<p>Note that MSBuild-based projects do not support the <strong>ESP32<\/strong> devices, as they come with their own SDK (ESP-IDF). If you are targeting an ESP32 device, please use the <a href=\"#espidf\">Advanced ESP-IDF Project Subsystem<\/a> instead.<\/p>\n<h2><a id=\"make\"><\/a>Legacy GNU Make<\/h2>\n<p>The GNU Make-based projects consist of a Makefile containing the actual build settings, and a dummy VC++ project that hands over the build logic to <strong>VisualGDB.exe<\/strong>. You can tell a GNU Make-based project (and other legacy projects) by the &#8220;<strong>x86<\/strong>&#8221; or &#8220;<strong>Win32<\/strong>&#8221; platform name and the regular VC++ project icon:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/make.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5879\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/make.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>VisualGDB, in turn, launches GNU Make, that handles the build.<\/p>\n<p>You can edit most build settings of GNU Make projects via VisualGDB Project Properties:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/make2.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5880\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/make2.png\" alt=\"\" width=\"976\" height=\"652\" \/><\/a>Any changes made here will be saved to the Makefile, and the IntelliSense settings of the dummy VC++ project will be updated accordingly. Note that this only works for Makefiles created with VisualGDB (that follow the VisualGDB Makefile structure).<\/p>\n<p>This project type is recommended if you are familiar with GNU Make and are planning to extend the Makefile with custom targets. For all other scenarios, please consider using <a href=\"#cmake\">Advanced CMake<\/a> or <a href=\"#msbuild\">MSBuild<\/a> instead.<\/p>\n<h2><a id=\"cmake\"><\/a>Advanced CMake<\/h2>\n<p>Advanced CMake projects are thin wrappers on top of the <strong>CMakeLists.txt<\/strong> files. The build settings for CMake projects are stored in the <strong>CMakeLists.txt<\/strong> files, allowing the projects to be built on any machine that has CMake installed. VisualGDB provides convenient GUI for most commonly used CMake settings and will automatically edit <strong>CMakeLists.txt<\/strong> when you change them. You can tell an Advanced CMake project by the <strong>CMake<\/strong> icon in Solution Explorer:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/cmake.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5882\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/cmake.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>Advanced CMake projects support multiple targets per project (e.g. executable + static library), allow <a href=\"https:\/\/visualgdb.com\/tutorials\/cmake\/debugger\/\">stepping through CMakeLists.txt files<\/a> and are generally recommended over other project types, as long as your platform is supported.<\/p>\n<p>Starting from VisualGDB 5.5, the Advanced CMake Project Subsystem fully supports embedded projects. See <a href=\"https:\/\/visualgdb.com\/documentation\/embedded\/cmake\/\">this page<\/a> for detailed documentation on them.<\/p>\n<h2><a id=\"legacy\"><\/a>Legacy QMake and CMake<\/h2>\n<p>The legacy QMake and CMake projects are similar to the <a href=\"#make\">GNU Make-based projects<\/a>, having the same advantages and disadvantages:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/legacy.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5883\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/legacy.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>We generally do not recommend them for new projects, unless you need compatibility with earlier VisualGDB versions.<\/p>\n<h2><a id=\"custom\"><\/a>Custom Imported Projects<\/h2>\n<p>This project type is used for existing complex projects that are not based on CMake and do not follow the VisualGDB Makefile layout. You can create it by selecting the generic &#8220;Import&#8221; option in either Embedded or Linux project wizard:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/import.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5886\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/import.png\" alt=\"\" width=\"886\" height=\"693\" \/><\/a>Custom imported projects are very similar to the Legacy projects. Unlike GNU Make projects, VisualGDB does not make any assumptions about the underlying build system. It will simply launch the build\/clean command line specified via VisualGDB Project Properties and will assume that it produced the binary specified in the &#8220;Main binary&#8221; field:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/custom.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5887\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/custom.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>For this type of project, VisualGDB will not automatically update the IntelliSense settings, so you would need to configure IntelliSense manually via VisualGDB Project Properties.<\/p>\n<p>We recommend using this type to quickly import existing large projects into VisualGDB without converting any settings. You will be instantly able to build and debug the project, although IntelliSense will not be precise, and changing build settings would require manually editing your existing Make files. Once you get comfortable with VisualGDB, we advise converting your project to CMake and using the <a href=\"#cmake\">Advanced CMake Project Subsystem<\/a> with it.<\/p>\n<h2><a id=\"mbed\"><\/a>Advanced Mbed<\/h2>\n<p>Advanced Mbed projects work by integrating the <strong>mbed-cli<\/strong> tools into Visual Studio. VisualGDB lets mbed handle the actual build of the project, discovers the underlying project structure and renders it in Solution Explorer, allowing you to tweak various build parameters:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/mbed.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5888\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/mbed.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>Advanced Mbed projects can support multiple targets (i.e. boards) that can be added via the <strong>Add-&gt;Manage mbed Boards<\/strong> command in Solution Explorer.<\/p>\n<p>You can build Advanced Mbed projects outside VisualGDB by running the build command shown in the VisualGDB Build window. This will produce the same results as building the project with VisualGDB.<\/p>\n<p>We recommend using Mbed (and the Advanced Mbed Project System) if you are targeting one of the platforms supported by mbed and would like to take advantage of the libraries included with the Mbed OS. Another good use for Mbed would be to create portable projects that can simultaneously target multiple boards supported by mbed.<\/p>\n<h2><a id=\"arduino\"><\/a>Advanced Arduino<\/h2>\n<p>Advanced Arduino projects work by integrating the Arduino Build system (<strong>arduino-builder.exe<\/strong>) into Visual Studio. They use the same build logic and produce the same results as Arduino IDE. VisualGDB supports the regular Arduino targets as well as the ESP32, ESP8266, STM32 and Bluno M3 Arduino cores. The project structure shown in Solution Explorer is queried directly from the Arduino build tools and hence 100% matches the built project:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/arduino.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5889\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/arduino.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>VisualGDB also supports numerous Arduino libraries and packages that can be managed via <strong>Tools-&gt;VisualGDB-&gt;Manage VisualGDB Packages<\/strong>.<\/p>\n<p>We recommend using Arduino projects for quick prototyping, or if you would like to use a specific Arduino-based library. As most settings for Arduino projects are automatically guessed by the Arduino build system, the initial setup is considerably easier, compared to other project types. That said, the auto-detection of settings makes it harder to tweak and understand the build process, so if you are planning a large project, please consider using <a href=\"#msbuild\">MSBuild<\/a> instead.<\/p>\n<p>For more information see our documentation on the <a href=\"https:\/\/visualgdb.com\/documentation\/projects\/arduino\/\">Advanced Arduino Project Structure<\/a>.<\/p>\n<h2><a id=\"espidf\"><\/a>Advanced ESP-IDF<\/h2>\n<p>The Advanced ESP-IDF projects are specifically designed to integrate the <a href=\"https:\/\/docs.espressif.com\/projects\/esp-idf\/en\/latest\/esp32\/\">ESP-IDF framework<\/a> into Visual Studio. They are based on the <a href=\"#cmake\">Advanced CMake<\/a> projects and render the detailed and precise structure of your project (including the ESP-IDF framework) in Solution Explorer, providing numerous commands and settings pages for controlling most commonly used settings:<a href=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/idf.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5891\" src=\"https:\/\/visualgdb.com\/w\/wp-content\/uploads\/2020\/04\/idf.png\" alt=\"\" width=\"1182\" height=\"759\" \/><\/a>If you are targeting an ESP32 device (or an ESP8266 device with RTOS SDK 3.0+) and do not want to use the Arduino core, the Advanced ESP-IDF project type is the project type to use.<\/p>\n<p>For more information, see our documentation on <a href=\"https:\/\/visualgdb.com\/documentation\/espidf\/\">Advanced ESP-IDF Project Structure<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview This page provides an overview of various VisualGDB project types. We will explain the advantages and limitations of those<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[201],"tags":[],"_links":{"self":[{"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/posts\/5877"}],"collection":[{"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/comments?post=5877"}],"version-history":[{"count":6,"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/posts\/5877\/revisions"}],"predecessor-version":[{"id":7047,"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/posts\/5877\/revisions\/7047"}],"wp:attachment":[{"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/media?parent=5877"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/categories?post=5877"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/visualgdb.com\/w\/wp-json\/wp\/v2\/tags?post=5877"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}