Error compiling PyICU 2.0 with ICU 52
Created by: mjansche
I'm installing PyICU with pip in a Travis continuous build using Travis's Ubuntu "trusty" image, for which apt-get install libicu-dev installs ICU 52. The pip install of PyICU started failing today after the release of 2.0. Here is what I think is the relevant error message, taken from the full log:
In file included from measureunit.cpp:29:0:
measureunit.cpp: In function ‘int t_measure_init(t_measure*, PyObject*, PyObject*)’:
measureunit.cpp:1686:70: error: cannot allocate an object of abstract type ‘icu_52::Measure’
Formattable(d), (MeasureUnit *) unit->clone(), status));
^
macros.h:95:9: note: in definition of macro ‘INT_STATUS_CALL’
action; \
^
In file included from /usr/include/x86_64-linux-gnu/unicode/curramt.h:18:0,
from /usr/include/x86_64-linux-gnu/unicode/numfmt.h:39,
from /usr/include/x86_64-linux-gnu/unicode/datefmt.h:28,
from common.h:114,
from measureunit.cpp:24:
/usr/include/x86_64-linux-gnu/unicode/measure.h:45:18: note: because the following virtual functions are pure within ‘icu_52::Measure’:
class U_I18N_API Measure: public UObject {
^
/usr/include/x86_64-linux-gnu/unicode/measure.h:77:22: note: virtual icu_52::UObject* icu_52::Measure::clone() const
virtual UObject* clone() const = 0;
^
In other words, new Measure(...) is not possible because icu_52::Measure is abstract, since its clone() method is pure virtual.
In ICU 52-1 Measure::clone() was pure virtual. But starting from ICU 53-1 Measure::clone() lost its purity.
This was never an issue with PyICU < 2. Any plans to support ICU 52 for PyICU?