prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Installation issue: py-lxml doesn't use the spack libxslt and libexslt libraries
  It looks like py-lxml should have AUTO_RPATH set to true. Otherwise it picks up the OS versions of libxslt instead of the spack built versions. I added this to the package.py and the library dependencies were correct:
  
  ```
      def setup_build_environment(self, env):
          env.set('AUTO_RPATH', 'true')
  ```
  
  </issue>
  <code>
  [start of var/spack/repos/builtin/packages/py-lxml/package.py]
  1 # Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
  2 # Spack Project Developers. See the top-level COPYRIGHT file for details.
  3 #
  4 # SPDX-License-Identifier: (Apache-2.0 OR MIT)
  5 
  6 from spack import *
  7 
  8 
  9 class PyLxml(PythonPackage):
  10     """lxml is the most feature-rich and easy-to-use library for processing
  11     XML and HTML in the Python language."""
  12 
  13     homepage = "http://lxml.de/"
  14     url      = "https://pypi.io/packages/source/l/lxml/lxml-4.4.1.tar.gz"
  15 
  16     version('4.4.1', sha256='c81cb40bff373ab7a7446d6bbca0190bccc5be3448b47b51d729e37799bb5692')
  17     version('4.3.3', sha256='4a03dd682f8e35a10234904e0b9508d705ff98cf962c5851ed052e9340df3d90')
  18     version('4.2.5', sha256='36720698c29e7a9626a0dc802ef8885f8f0239bfd1689628ecd459a061f2807f')
  19     version('3.7.3', sha256='aa502d78a51ee7d127b4824ff96500f0181d3c7826e6ee7b800d068be79361c7')
  20     version('2.3', sha256='eea1b8d29532739c1383cb4794c5eacd6176f0972b59e8d29348335b87ff2e66')
  21 
  22     variant('html5', default=False, description='Enable html5lib backend')
  23     variant('htmlsoup',  default=False, description='Enable BeautifulSoup4 backend')
  24     variant('cssselect',   default=False, description='Enable cssselect module')
  25 
  26     depends_on('python@2.7:2.8,3.5:', type=('build', 'run'))
  27     depends_on('py-setuptools', type='build')
  28     depends_on('libxml2', type=('build', 'run'))
  29     depends_on('libxslt', type=('build', 'run'))
  30     depends_on('py-html5lib', when='+html5', type=('build', 'run'))
  31     depends_on('py-beautifulsoup4', when='+htmlsoup', type=('build', 'run'))
  32     depends_on('py-cssselect@0.7:', when='+cssselect', type=('build', 'run'))
  33
  [end of var/spack/repos/builtin/packages/py-lxml/package.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/var/spack/repos/builtin/packages/py-lxml/package.py b/var/spack/repos/builtin/packages/py-lxml/package.py
  --- a/var/spack/repos/builtin/packages/py-lxml/package.py
  +++ b/var/spack/repos/builtin/packages/py-lxml/package.py
  @@ -13,6 +13,7 @@
       homepage = "http://lxml.de/"
       url      = "https://pypi.io/packages/source/l/lxml/lxml-4.4.1.tar.gz"
   
  +    version('4.5.2', sha256='cdc13a1682b2a6241080745b1953719e7fe0850b40a5c71ca574f090a1391df6')
       version('4.4.1', sha256='c81cb40bff373ab7a7446d6bbca0190bccc5be3448b47b51d729e37799bb5692')
       version('4.3.3', sha256='4a03dd682f8e35a10234904e0b9508d705ff98cf962c5851ed052e9340df3d90')
       version('4.2.5', sha256='36720698c29e7a9626a0dc802ef8885f8f0239bfd1689628ecd459a061f2807f')
  @@ -25,8 +26,8 @@
   
       depends_on('python@2.7:2.8,3.5:', type=('build', 'run'))
       depends_on('py-setuptools', type='build')
  -    depends_on('libxml2', type=('build', 'run'))
  -    depends_on('libxslt', type=('build', 'run'))
  +    depends_on('libxml2', type=('build', 'link', 'run'))
  +    depends_on('libxslt', type=('build', 'link', 'run'))
       depends_on('py-html5lib', when='+html5', type=('build', 'run'))
       depends_on('py-beautifulsoup4', when='+htmlsoup', type=('build', 'run'))
       depends_on('py-cssselect@0.7:', when='+cssselect', type=('build', 'run'))
  
verification_info: {"golden_diff": "diff --git a/var/spack/repos/builtin/packages/py-lxml/package.py b/var/spack/repos/builtin/packages/py-lxml/package.py\n--- a/var/spack/repos/builtin/packages/py-lxml/package.py\n+++ b/var/spack/repos/builtin/packages/py-lxml/package.py\n@@ -13,6 +13,7 @@\n     homepage = \"http://lxml.de/\"\n     url      = \"https://pypi.io/packages/source/l/lxml/lxml-4.4.1.tar.gz\"\n \n+    version('4.5.2', sha256='cdc13a1682b2a6241080745b1953719e7fe0850b40a5c71ca574f090a1391df6')\n     version('4.4.1', sha256='c81cb40bff373ab7a7446d6bbca0190bccc5be3448b47b51d729e37799bb5692')\n     version('4.3.3', sha256='4a03dd682f8e35a10234904e0b9508d705ff98cf962c5851ed052e9340df3d90')\n     version('4.2.5', sha256='36720698c29e7a9626a0dc802ef8885f8f0239bfd1689628ecd459a061f2807f')\n@@ -25,8 +26,8 @@\n \n     depends_on('python@2.7:2.8,3.5:', type=('build', 'run'))\n     depends_on('py-setuptools', type='build')\n-    depends_on('libxml2', type=('build', 'run'))\n-    depends_on('libxslt', type=('build', 'run'))\n+    depends_on('libxml2', type=('build', 'link', 'run'))\n+    depends_on('libxslt', type=('build', 'link', 'run'))\n     depends_on('py-html5lib', when='+html5', type=('build', 'run'))\n     depends_on('py-beautifulsoup4', when='+htmlsoup', type=('build', 'run'))\n     depends_on('py-cssselect@0.7:', when='+cssselect', type=('build', 'run'))\n", "issue": "Installation issue: py-lxml doesn't use the spack libxslt and libexslt libraries\nIt looks like py-lxml should have AUTO_RPATH set to true. Otherwise it picks up the OS versions of libxslt instead of the spack built versions. I added this to the package.py and the library dependencies were correct:\r\n\r\n```\r\n    def setup_build_environment(self, env):\r\n        env.set('AUTO_RPATH', 'true')\r\n```\n", "before_files": [{"content": "# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\nfrom spack import *\n\n\nclass PyLxml(PythonPackage):\n    \"\"\"lxml is the most feature-rich and easy-to-use library for processing\n    XML and HTML in the Python language.\"\"\"\n\n    homepage = \"http://lxml.de/\"\n    url      = \"https://pypi.io/packages/source/l/lxml/lxml-4.4.1.tar.gz\"\n\n    version('4.4.1', sha256='c81cb40bff373ab7a7446d6bbca0190bccc5be3448b47b51d729e37799bb5692')\n    version('4.3.3', sha256='4a03dd682f8e35a10234904e0b9508d705ff98cf962c5851ed052e9340df3d90')\n    version('4.2.5', sha256='36720698c29e7a9626a0dc802ef8885f8f0239bfd1689628ecd459a061f2807f')\n    version('3.7.3', sha256='aa502d78a51ee7d127b4824ff96500f0181d3c7826e6ee7b800d068be79361c7')\n    version('2.3', sha256='eea1b8d29532739c1383cb4794c5eacd6176f0972b59e8d29348335b87ff2e66')\n\n    variant('html5', default=False, description='Enable html5lib backend')\n    variant('htmlsoup',  default=False, description='Enable BeautifulSoup4 backend')\n    variant('cssselect',   default=False, description='Enable cssselect module')\n\n    depends_on('python@2.7:2.8,3.5:', type=('build', 'run'))\n    depends_on('py-setuptools', type='build')\n    depends_on('libxml2', type=('build', 'run'))\n    depends_on('libxslt', type=('build', 'run'))\n    depends_on('py-html5lib', when='+html5', type=('build', 'run'))\n    depends_on('py-beautifulsoup4', when='+htmlsoup', type=('build', 'run'))\n    depends_on('py-cssselect@0.7:', when='+cssselect', type=('build', 'run'))\n", "path": "var/spack/repos/builtin/packages/py-lxml/package.py"}]}