Bug 231273 - editors/libreoffice: Fails to build with Python 2.7
Summary: editors/libreoffice: Fails to build with Python 2.7
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Li-Wen Hsu
Keywords: needs-qa
Depends on:
Reported: 2018-09-09 22:42 UTC by Mikhail Teterin
Modified: 2020-06-17 01:36 UTC (History)
5 users (show)

See Also:
bugzilla: maintainer-feedback? (office)


Note You need to log in before you can comment on or make changes to this bug.
Description Mikhail Teterin freebsd_committer 2018-09-09 22:42:12 UTC
The error:

/spare/usr/ports/editors/libreoffice/work/libreoffice- error: static_assert failed "bad assumption"
    static_assert(sizeof (wchar_t) == Py_UNICODE_SIZE, "bad assumption");
    ^             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/spare/usr/ports/editors/libreoffice/work/libreoffice- error: no matching function for call to 'PyUnicodeUCS2_FromUnicode'
    ret = PyRef( PyUnicode_FromUnicode( reinterpret_cast<wchar_t const *>(str.getStr()), str.getLength() ), SAL_NO_ACQUIRE );
/opt/include/python2.7/unicodeobject.h:196:32: note: expanded from macro 'PyUnicode_FromUnicode'
# define PyUnicode_FromUnicode PyUnicodeUCS2_FromUnicode
/opt/include/python2.7/unicodeobject.h:464:23: note: candidate function not viable: no known conversion from 'const wchar_t *' to 'const Py_UNICODE *' (aka 'const unsigned short *') for 1st argument
PyAPI_FUNC(PyObject*) PyUnicode_FromUnicode(
/opt/include/python2.7/unicodeobject.h:196:32: note: expanded from macro 'PyUnicode_FromUnicode'
# define PyUnicode_FromUnicode PyUnicodeUCS2_FromUnicode
7 warnings and 2 errors generated.
Comment 2 Mikhail Teterin freebsd_committer 2018-09-10 02:44:47 UTC
Could it because I have the UCS2 option enabled in lang/python27 -- instead of UCS4, which is the default?
Comment 3 Walter Schwarzenfeld freebsd_triage 2019-08-03 07:36:31 UTC
Is this still relevant after change of the python default version to 3.6?
Comment 4 Kubilay Kocak freebsd_committer freebsd_triage 2019-08-25 04:18:11 UTC
(In reply to Mikhail Teterin from comment #2)

Likely, could you test with the latest tree, with lang/python27 with UCS4 and let us know if its still reproducible
Comment 5 VVD 2020-04-24 12:48:43 UTC
Time to close this.
Comment 6 Li-Wen Hsu freebsd_committer 2020-06-16 22:09:16 UTC
Feedback timeout.
Comment 7 Kubilay Kocak freebsd_committer freebsd_triage 2020-06-17 01:36:29 UTC
^Triage: Assign to committer that resolved, such that if/when re-opened, they can re-triage