Actions
Bug #3696
closedmd_to_c.py requires python 2
Status:
Fixed
Priority:
Normal
Assignee:
-
Category:
General
Target version:
-
Start date:
2016-04-06
Due date:
% Done:
100%
Estimated time:
Found in version:
4.1-1817~gfc6b8ce
Affected Versions:
Description
The file support/doc/md_to_c.py has shebang "#!/usr/bin/env python". On Arch Linux and some other distributions, this points to python 3. This causes a build failure:
Markdown: docs/markdown/before_begin.md Markdown: docs/markdown/install_tvheadend.md Markdown: docs/markdown/install_hardware.md Markdown: docs/markdown/configure_tvheadend.md Markdown: docs/markdown/epg.md Traceback (most recent call last): File "support/doc/md_to_c.py", line 403, in <module> text = fp.read(1024*1024*2) File "/usr/lib/python3.5/encodings/ascii.py", line 26, in decode return codecs.ascii_decode(input, self.errors)[0] UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 961: ordinal not in range(128) Makefile:671: recipe for target '/build/tvheadend-git/src/tvheadend-git/build.linux/docs-timestamp' failed
Changing the shebang to "#!/usr/bin/env python2" causes the file to run with python 2 and fixes the build. I believe this should work for any distribution that now defaults to python 3 and still has 2 installed.
Actions