def METHOD_NAME(self):
    apply_conandata_patches(self)
    if is_msvc(self):
        solution_msvc_year = "2017" if Version(self.version) < "1.0.24" else "2019"
        solution = f"libusb_{'dll' if self.options.shared else 'static'}_{solution_msvc_year}.vcxproj"
        vcxproj_path = os.path.join(self.source_folder, "msvc", solution)
        #==============================
        # TODO: to remove once https://github.com/conan-io/conan/pull/12817 available in conan client
        replace_in_file(
            self, vcxproj_path,
            "<WholeProgramOptimization Condition=\"'$(Configuration)'=='Release'\">true</WholeProgramOptimization>",
            "",
        )
        old_toolset = "v141" if Version(self.version) < "1.0.24" else "v142"
        new_toolset = MSBuildToolchain(self).toolset
        replace_in_file(
            self, vcxproj_path,
            f"<PlatformToolset>{old_toolset}</PlatformToolset>",
            f"<PlatformToolset>{new_toolset}</PlatformToolset>",
        )
        conantoolchain_props = os.path.join(self.generators_folder, MSBuildToolchain.filename)
        replace_in_file(
            self, vcxproj_path,
            "<Import Project=\"$(VCTargetsPath)\\Microsoft.Cpp.targets\" />",
            f"<Import Project=\"{conantoolchain_props}\" /><Import Project=\"$(VCTargetsPath)\\Microsoft.Cpp.targets\" />",
        )
        #==============================
        msbuild = MSBuild(self)
        msbuild.build_type = self._msbuild_configuration
        msbuild.METHOD_NAME(vcxproj_path)
    else:
        autotools = Autotools(self)
        autotools.configure()
        autotools.make()