Skip to content

Commit

Permalink
backend/vs: Move Microsoft.Cpp.props to before ItemDefinitionGroup.
Browse files Browse the repository at this point in the history
The main reason for this move is to make it easier to merge the copies of
project generation. But as far as I can tell, the Microsoft.Cpp.props import
also belongs before the ItemDefinitionGroup.

Originally the order seems to have been that way, but 431a9ea changed it in
the course of other changes.
  • Loading branch information
anarazel committed Oct 8, 2021
1 parent 3f8c78b commit 157f11d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions mesonbuild/backend/vs2010backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -867,6 +867,9 @@ def gen_vcxproj(self, target, ofname, guid):
if '/INCREMENTAL:NO' in buildtype_link_args:
ET.SubElement(type_config, 'LinkIncremental').text = 'false'

# End configuration (but note we add further to type_config, below)
ET.SubElement(root, 'Import', Project=r'$(VCTargetsPath)\Microsoft.Cpp.props')

# Build information
compiles = ET.SubElement(root, 'ItemDefinitionGroup')
clconf = ET.SubElement(compiles, 'ClCompile')
Expand Down Expand Up @@ -930,8 +933,6 @@ def gen_vcxproj(self, target, ofname, guid):
ET.SubElement(clconf, 'ExceptionHandling').text = 'false'
else: # 'sc' or 'default'
ET.SubElement(clconf, 'ExceptionHandling').text = 'Sync'
# End configuration
ET.SubElement(root, 'Import', Project=r'$(VCTargetsPath)\Microsoft.Cpp.props')
generated_files, custom_target_output_files, generated_files_include_dirs = self.generate_custom_generator_commands(target, root)
(gen_src, gen_hdrs, gen_objs, gen_langs) = self.split_sources(generated_files)
(custom_src, custom_hdrs, custom_objs, custom_langs) = self.split_sources(custom_target_output_files)
Expand Down

0 comments on commit 157f11d

Please sign in to comment.