As Florian also noticed (and mentioned in a code comment) - some compilers flame out at "static const" for the 8 definitions in ctc-utils.h
../gpucompute/ctc-utils.h:37:35: error: ‘constexpr’ needed for in-class initialization of static data member ‘log_zero_’ of non-integral type
but changing the definitions to static constexpr fixes this. In my case it was because of running an older C compiler that came by default with Ubuntu 12.04. I believe on newer OS releases (14.04 and up), the compiler does not mind.
Maybe we should update the code to the form that works for more compilers?
As Florian also noticed (and mentioned in a code comment) - some compilers flame out at "static const" for the 8 definitions in ctc-utils.h
../gpucompute/ctc-utils.h:37:35: error: ‘constexpr’ needed for in-class initialization of static data member ‘log_zero_’ of non-integral type
but changing the definitions tostatic constexpr
fixes this. In my case it was because of running an older C compiler that came by default with Ubuntu 12.04. I believe on newer OS releases (14.04 and up), the compiler does not mind.Maybe we should update the code to the form that works for more compilers?
Breaks: ilva@ilva-VirtualBox:~/eesen/src$ g++ --version g++ (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Works: vagrant@vagrant-ubuntu-trusty-64:~/bin$ g++ --version g++ (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4