BSD Ports

converters/py-webencodings 0.5.1_1 MidnightBSD

Character encoding aliases for legacy web content

System
MidnightBSD
Repository
mports
Maintainer
[email protected]
License
bsd3
Categories
converters, www, python

Description

In order to be compatible with legacy web content when interpreting something like Content-Type: text/html; charset=latin1, tools need to use a particular set of aliases for encoding labels as well as some overriding rules.

For example, US-ASCII and iso-8859-1 on the web are actually aliases for windows-1252, and an UTF-8 or UTF-16 BOM takes precedence over any other encoding declaration.

The Encoding standard defines all such details so that implementations do not have to reverse-engineer each other.

This module has encoding labels and BOM detection, but the actual implementation for encoders and decoders is Python's.

In the other systems

SystemPortVersion
MidnightBSDconverters/py-webencodings0.5.1_1
FreeBSDconverters/py-webencodings0.5.1_1
DragonFlyconverters/py-webencodings0.5.1_1
HardenedBSDconverters/py-webencodings0.5.1_1
GhostBSDconverters/py-webencodings0.5.1_1
OPNsenseconverters/py-webencodings0.5.1_1

Install

Binary package:

mport install ${PYTHON_PKGNAMEPREFIX}webencodings

From mports:

cd /usr/mports/converters/py-webencodings && make install clean

To depend on this port in another port's Makefile:

RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}webencodings>0:converters/py-webencodings

Dependencies

Configuration

No options to configure.

USES
python:2.7+
Service scripts
none

Files

distinfo 1
FileSizeSHA256
webencodings-0.5.1.tar.gz9721b36a1c245f2d304965eb4e0a82848379241dc04b865afcc4aab16748587e1923
Master sites 1
  • PYPI