![]() ![]() A macro can refer to a value that's defined by Visual Studio or the MSBuild system, or to a user-defined value. MSBuild supports the use of compile-time constants for certain string values, such as include directories and paths, called macros. For more information about the settings on each property page, see Property Pages (C++). ![]() idl file, the MIDL property page isn't displayed. For example, if the project doesn't have an. The Property Pages dialog box shows only the property pages that are relevant to the current project. Or, you can browse documentation for all the options at MSVC compiler options and MSVC linker options. To read documentation about a specific option, select the option in the center pane and press F1. These options translate directly to command-line options that will be passed to the compiler. Specify symbol (.pdb) and source files in the Visual Studio debuggerĬ++ compiler and linker options are located under the C/C++ and Linker nodes in the left pane under Configuration Properties.Debugging Preparation: Visual C++ Project Types.Project settings for a C++ debug configuration.For more information, see /CLRIMAGETYPE (Specify Type of CLR Image).įor more information about setting properties for a Debug build, see: It's only relevant for C++/CLI and other. The Any CPU target platform value that you might see in Configuration Manager has no effect on native C++ projects. For more information about these two platforms, see Running 32-bit applications. ![]() Win32 means 32-bit Windows and 圆4 means 64-bit Windows. The x86 target platform that you might see in Configuration Manager is identical to Win32 in native C++ projects. They include but aren't limited to Win32, 圆4, ARM, ARM64, Android, and iOS. The available target platforms for C++ projects depend on the kind of project. You can build a project for more than one platform. Target platform refers to the kind of device and operating system that the executable will run on. You can set properties for any configuration here it doesn't have to be the active one. Also note that the active configuration is still Debug. Note the different value for the Optimization property. The following illustration shows the same project property page, but the configuration has been changed to Release. When the Optimization property is set here, it will apply only to Debug Win32 builds, the currently active configuration, as shown by the red arrows. The following illustration shows the property pages with the configuration and platform information controls at the top. ![]() You can always see and change the configuration and platform a property value should apply to. Should it apply only to Debug Win32 builds, or should it also apply to Debug ARM64 and Debug 圆4? For example, the Optimization property, by default, is set to Maximize Speed (/O2) in a Release configuration, but it's disabled in the Debug configuration. So when you set a property, it's important to pay attention to which configuration and platform the new value should apply to. To generate the correct code, the compiler has to know both the specific platform the program will run on and which specific compiler options to use. But most properties are configuration-dependent. Some properties, such as the application name, apply to all build variations and target platforms, whether it's a debug or release build. The default properties are shown in the General pane in the Property Pages:Īpplying properties to build configurations and target platforms For example, an ATL project has properties related to MIDL files, but these properties are absent in a basic console application. The defaults vary somewhat depending on the kind of project and what options you choose in the app wizard. When you create a project, the system assigns values for various properties. To access the property pages, choose Project > project-name Properties from the main menu, or right-click on the project node in Solution Explorer and choose Properties. Typically, you use property pages to view and modify these properties. This information includes the application name, extension (such as DLL, LIB, EXE), compiler options, linker options, debugger settings, custom build steps, and many other things. In the IDE, all information that's needed to build a project is exposed as properties. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |