|
1 | 1 | """The vcpkg provider implementation""" |
2 | 2 |
|
3 | | -import json |
4 | 3 | import subprocess |
5 | 4 | from logging import getLogger |
6 | 5 | from os import name as system_name |
@@ -121,68 +120,9 @@ def _create_cmake_sync_data(self) -> CMakeSyncData: |
121 | 120 | Returns: |
122 | 121 | CMakeSyncData configured for vcpkg integration |
123 | 122 | """ |
124 | | - # Providers are now responsible for generating their own preset file |
125 | | - # Create provider sync data with vcpkg configuration |
126 | | - provider_preset_path = self.core_data.cppython_data.tool_path / 'providers' / 'vcpkg.json' |
127 | | - provider_preset_path.parent.mkdir(parents=True, exist_ok=True) |
128 | | - |
129 | 123 | # Create CMakeSyncData with vcpkg configuration |
130 | 124 | vcpkg_cmake_path = self.core_data.cppython_data.install_path / 'scripts/buildsystems/vcpkg.cmake' |
131 | 125 |
|
132 | | - # Create a custom provider preset with vcpkg configuration |
133 | | - provider_preset = { |
134 | | - 'version': 9, |
135 | | - 'configurePresets': [ |
136 | | - { |
137 | | - 'name': 'vcpkg-base', |
138 | | - 'hidden': True, |
139 | | - 'cacheVariables': {'CMAKE_PROJECT_TOP_LEVEL_INCLUDES': str(vcpkg_cmake_path.as_posix())}, |
140 | | - }, |
141 | | - { |
142 | | - 'name': 'vcpkg-release', |
143 | | - 'hidden': True, |
144 | | - 'inherits': 'vcpkg-base', |
145 | | - 'cacheVariables': {'CMAKE_BUILD_TYPE': 'Release'}, |
146 | | - }, |
147 | | - { |
148 | | - 'name': 'vcpkg-debug', |
149 | | - 'hidden': True, |
150 | | - 'inherits': 'vcpkg-base', |
151 | | - 'cacheVariables': {'CMAKE_BUILD_TYPE': 'Debug'}, |
152 | | - }, |
153 | | - ], |
154 | | - 'buildPresets': [ |
155 | | - { |
156 | | - 'name': 'vcpkg-multi-release', |
157 | | - 'configurePreset': 'vcpkg-base', |
158 | | - 'configuration': 'Release', |
159 | | - 'hidden': True, |
160 | | - }, |
161 | | - { |
162 | | - 'name': 'vcpkg-multi-debug', |
163 | | - 'configurePreset': 'vcpkg-base', |
164 | | - 'configuration': 'Debug', |
165 | | - 'hidden': True, |
166 | | - }, |
167 | | - { |
168 | | - 'name': 'vcpkg-release', |
169 | | - 'configurePreset': 'vcpkg-release', |
170 | | - 'configuration': 'Release', |
171 | | - 'hidden': True, |
172 | | - }, |
173 | | - { |
174 | | - 'name': 'vcpkg-debug', |
175 | | - 'configurePreset': 'vcpkg-debug', |
176 | | - 'configuration': 'Debug', |
177 | | - 'hidden': True, |
178 | | - }, |
179 | | - ], |
180 | | - } |
181 | | - |
182 | | - # Write the preset file |
183 | | - with open(provider_preset_path, 'w', encoding='utf-8') as f: |
184 | | - json.dump(provider_preset, f, indent=4) |
185 | | - |
186 | 126 | return CMakeSyncData( |
187 | 127 | provider_name=TypeName('vcpkg'), |
188 | 128 | preset_file=provider_preset_path, |
|
0 commit comments