1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768 |
- # Build recipe for markupsafe.
- #
- # Copyright (C) 2019-2022 Matias Fonzo, <selk@dragora.org>.
- #
- # Licensed under the Apache License, Version 2.0 (the "License");
- # you may not use this file except in compliance with the License.
- # You may obtain a copy of the License at
- #
- # http://www.apache.org/licenses/LICENSE-2.0
- #
- # Unless required by applicable law or agreed to in writing, software
- # distributed under the License is distributed on an "AS IS" BASIS,
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- # See the License for the specific language governing permissions and
- # limitations under the License.
- # Exit immediately on any error
- set -e
- program=MarkupSafe
- version=2.1.1
- release=1
- pkgname=python-${program}
- # Define a category for the output of the package name
- pkgcategory=python
- tarname=${program}-${version}.tar.gz
- # Remote source(s)
- fetch=https://files.pythonhosted.org/packages/1d/97/2288fe498044284f39ab8950703e88abbac2abbdf65524d576157af70556/$tarname
- description="
- A Python module that implements a XML/HTML/XHTML Markup safe string.
- MarkupSafe implements a text object that escapes characters so it is
- safe to use in HTML and XML. Characters that have special meanings
- are replaced so that they display as the actual characters. This
- mitigates injection attacks, meaning untrusted user input can safely
- be displayed on a page. Escaping is implemented in C so it is as
- efficient as possible.
- "
- homepage=https://palletsprojects.com/p/markupsafe
- license="BSD License (BSD-3-Clause)"
- docs="CHANGES* LICENSE* PKG-INFO README*"
- docsdir="${docdir}/${pkgname}-${version}"
- build()
- {
- unpack "${tardir}/$tarname"
- cd "$srcdir"
- # Set sane permissions
- chmod -R u+w,go-w,a+rX-s .
- python3 setup.py build
- python3 setup.py install --prefix=/usr --root="$destdir" --optimize=1
- # Copy documentation
- mkdir -p "${destdir}/$docsdir"
- cp -p $docs "${destdir}/$docsdir"
- }
|