prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  [package] catch2/2.9.2: Expected CMake scripts to be included in the package 
  ### Package and Environment Details (include every applicable attribute)
    * Package Name/Version: **catch2/2.9.2**
  
  I expected to have access to cmake scripts that are installed with Catch2.
  
  The helper scripts are set to be installed.
  
  https://github.com/conan-io/conan-center-index/blob/6a7ff72be4e6fa6362112459f7319f6e6e565a99/recipes/catch2/2.x.x/conanfile.py#L33
  
  Then they are deleted during packaging.
  
  https://github.com/conan-io/conan-center-index/blob/6a7ff72be4e6fa6362112459f7319f6e6e565a99/recipes/catch2/2.x.x/conanfile.py#L51
  
  Currently, I am using the older bincrafters package (catch2/2.5.0@bincrafters/stable) which still includes the CMake scripts. I would need to maintain my own conan package to use the newer version of Catch2.
  
  </issue>
  <code>
  [start of recipes/catch2/2.x.x/conanfile.py]
  1 #!/usr/bin/env python
  2 
  3 import os
  4 
  5 from conans import ConanFile, CMake, tools
  6 
  7 
  8 class ConanRecipe(ConanFile):
  9     name = "catch2"
  10     description = "A modern, C++-native, header-only, framework for unit-tests, TDD and BDD"
  11     topics = ("conan", "catch2", "header-only", "unit-test", "tdd", "bdd")
  12     homepage = "https://github.com/catchorg/Catch2"
  13     url = "https://github.com/conan-io/conan-center-index"
  14     license = "BSL-1.0"
  15 
  16     settings = "os", "compiler", "build_type", "arch"
  17 
  18     generators = "cmake"
  19 
  20     _source_subfolder = "source_subfolder"
  21 
  22     def source(self):
  23         tools.get(**self.conan_data["sources"][self.version])
  24         extracted_dir = "Catch2-" + self.version
  25         os.rename(extracted_dir, self._source_subfolder)
  26 
  27     _build_subfolder = "build_subfolder"
  28 
  29     def _configure_cmake(self):
  30         cmake = CMake(self)
  31         cmake.definitions["BUILD_TESTING"] = "OFF"
  32         cmake.definitions["CATCH_INSTALL_DOCS"] = "OFF"
  33         cmake.definitions["CATCH_INSTALL_HELPERS"] = "ON"
  34         cmake.configure(
  35             source_folder=self._source_subfolder,
  36             build_folder=self._build_subfolder
  37         )
  38         return cmake
  39 
  40     def build(self):
  41         cmake = self._configure_cmake()
  42         cmake.build()
  43 
  44     def package(self):
  45         self.copy(pattern="LICENSE.txt", dst="licenses",
  46                   src=self._source_subfolder)
  47 
  48         cmake = self._configure_cmake()
  49         cmake.install()
  50 
  51         tools.rmdir(os.path.join(self.package_folder, "lib", "cmake"))
  52         tools.rmdir(os.path.join(self.package_folder, "share"))
  53 
  54     def package_id(self):
  55         self.info.header_only()
  56
  [end of recipes/catch2/2.x.x/conanfile.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/recipes/catch2/2.x.x/conanfile.py b/recipes/catch2/2.x.x/conanfile.py
  --- a/recipes/catch2/2.x.x/conanfile.py
  +++ b/recipes/catch2/2.x.x/conanfile.py
  @@ -1,5 +1,3 @@
  -#!/usr/bin/env python
  -
   import os
   
   from conans import ConanFile, CMake, tools
  @@ -12,20 +10,16 @@
       homepage = "https://github.com/catchorg/Catch2"
       url = "https://github.com/conan-io/conan-center-index"
       license = "BSL-1.0"
  -
       settings = "os", "compiler", "build_type", "arch"
  -
       generators = "cmake"
  -
       _source_subfolder = "source_subfolder"
  +    _build_subfolder = "build_subfolder"
   
       def source(self):
           tools.get(**self.conan_data["sources"][self.version])
           extracted_dir = "Catch2-" + self.version
           os.rename(extracted_dir, self._source_subfolder)
   
  -    _build_subfolder = "build_subfolder"
  -
       def _configure_cmake(self):
           cmake = CMake(self)
           cmake.definitions["BUILD_TESTING"] = "OFF"
  @@ -42,14 +36,18 @@
           cmake.build()
   
       def package(self):
  -        self.copy(pattern="LICENSE.txt", dst="licenses",
  -                  src=self._source_subfolder)
  -
  +        self.copy(pattern="LICENSE.txt", dst="licenses", src=self._source_subfolder)
           cmake = self._configure_cmake()
           cmake.install()
  -
           tools.rmdir(os.path.join(self.package_folder, "lib", "cmake"))
           tools.rmdir(os.path.join(self.package_folder, "share"))
  +        for cmake_file in ["ParseAndAddCatchTests.cmake", "Catch.cmake"]:
  +            self.copy(cmake_file,
  +                      src=os.path.join(self._source_subfolder, "contrib"),
  +                      dst=os.path.join("lib", "cmake", "Catch2"))
   
       def package_id(self):
           self.info.header_only()
  +
  +    def package_info(self):
  +        self.cpp_info.builddirs = [os.path.join("lib", "cmake", "Catch2")]
  
verification_info: {"golden_diff": "diff --git a/recipes/catch2/2.x.x/conanfile.py b/recipes/catch2/2.x.x/conanfile.py\n--- a/recipes/catch2/2.x.x/conanfile.py\n+++ b/recipes/catch2/2.x.x/conanfile.py\n@@ -1,5 +1,3 @@\n-#!/usr/bin/env python\n-\n import os\n \n from conans import ConanFile, CMake, tools\n@@ -12,20 +10,16 @@\n     homepage = \"https://github.com/catchorg/Catch2\"\n     url = \"https://github.com/conan-io/conan-center-index\"\n     license = \"BSL-1.0\"\n-\n     settings = \"os\", \"compiler\", \"build_type\", \"arch\"\n-\n     generators = \"cmake\"\n-\n     _source_subfolder = \"source_subfolder\"\n+    _build_subfolder = \"build_subfolder\"\n \n     def source(self):\n         tools.get(**self.conan_data[\"sources\"][self.version])\n         extracted_dir = \"Catch2-\" + self.version\n         os.rename(extracted_dir, self._source_subfolder)\n \n-    _build_subfolder = \"build_subfolder\"\n-\n     def _configure_cmake(self):\n         cmake = CMake(self)\n         cmake.definitions[\"BUILD_TESTING\"] = \"OFF\"\n@@ -42,14 +36,18 @@\n         cmake.build()\n \n     def package(self):\n-        self.copy(pattern=\"LICENSE.txt\", dst=\"licenses\",\n-                  src=self._source_subfolder)\n-\n+        self.copy(pattern=\"LICENSE.txt\", dst=\"licenses\", src=self._source_subfolder)\n         cmake = self._configure_cmake()\n         cmake.install()\n-\n         tools.rmdir(os.path.join(self.package_folder, \"lib\", \"cmake\"))\n         tools.rmdir(os.path.join(self.package_folder, \"share\"))\n+        for cmake_file in [\"ParseAndAddCatchTests.cmake\", \"Catch.cmake\"]:\n+            self.copy(cmake_file,\n+                      src=os.path.join(self._source_subfolder, \"contrib\"),\n+                      dst=os.path.join(\"lib\", \"cmake\", \"Catch2\"))\n \n     def package_id(self):\n         self.info.header_only()\n+\n+    def package_info(self):\n+        self.cpp_info.builddirs = [os.path.join(\"lib\", \"cmake\", \"Catch2\")]\n", "issue": "[package] catch2/2.9.2: Expected CMake scripts to be included in the package \n### Package and Environment Details (include every applicable attribute)\r\n  * Package Name/Version: **catch2/2.9.2**\r\n\r\nI expected to have access to cmake scripts that are installed with Catch2.\r\n\r\nThe helper scripts are set to be installed.\r\n\r\nhttps://github.com/conan-io/conan-center-index/blob/6a7ff72be4e6fa6362112459f7319f6e6e565a99/recipes/catch2/2.x.x/conanfile.py#L33\r\n\r\nThen they are deleted during packaging.\r\n\r\nhttps://github.com/conan-io/conan-center-index/blob/6a7ff72be4e6fa6362112459f7319f6e6e565a99/recipes/catch2/2.x.x/conanfile.py#L51\r\n\r\nCurrently, I am using the older bincrafters package (catch2/2.5.0@bincrafters/stable) which still includes the CMake scripts. I would need to maintain my own conan package to use the newer version of Catch2.\n", "before_files": [{"content": "#!/usr/bin/env python\n\nimport os\n\nfrom conans import ConanFile, CMake, tools\n\n\nclass ConanRecipe(ConanFile):\n    name = \"catch2\"\n    description = \"A modern, C++-native, header-only, framework for unit-tests, TDD and BDD\"\n    topics = (\"conan\", \"catch2\", \"header-only\", \"unit-test\", \"tdd\", \"bdd\")\n    homepage = \"https://github.com/catchorg/Catch2\"\n    url = \"https://github.com/conan-io/conan-center-index\"\n    license = \"BSL-1.0\"\n\n    settings = \"os\", \"compiler\", \"build_type\", \"arch\"\n\n    generators = \"cmake\"\n\n    _source_subfolder = \"source_subfolder\"\n\n    def source(self):\n        tools.get(**self.conan_data[\"sources\"][self.version])\n        extracted_dir = \"Catch2-\" + self.version\n        os.rename(extracted_dir, self._source_subfolder)\n\n    _build_subfolder = \"build_subfolder\"\n\n    def _configure_cmake(self):\n        cmake = CMake(self)\n        cmake.definitions[\"BUILD_TESTING\"] = \"OFF\"\n        cmake.definitions[\"CATCH_INSTALL_DOCS\"] = \"OFF\"\n        cmake.definitions[\"CATCH_INSTALL_HELPERS\"] = \"ON\"\n        cmake.configure(\n            source_folder=self._source_subfolder,\n            build_folder=self._build_subfolder\n        )\n        return cmake\n\n    def build(self):\n        cmake = self._configure_cmake()\n        cmake.build()\n\n    def package(self):\n        self.copy(pattern=\"LICENSE.txt\", dst=\"licenses\",\n                  src=self._source_subfolder)\n\n        cmake = self._configure_cmake()\n        cmake.install()\n\n        tools.rmdir(os.path.join(self.package_folder, \"lib\", \"cmake\"))\n        tools.rmdir(os.path.join(self.package_folder, \"share\"))\n\n    def package_id(self):\n        self.info.header_only()\n", "path": "recipes/catch2/2.x.x/conanfile.py"}]}