gagolews / stringi

Fast and portable character string processing in R (with the Unicode ICU)
https://stringi.gagolewski.com/
Other
304 stars 44 forks source link

Install error in ubuntu 14.04 #367

Closed dvajdual closed 4 years ago

dvajdual commented 4 years ago

Hi! I am checking my package usung travis in some os, in ubuntu 14.04 also. Package stringi is dependence of package "remotes", that automatically installed when I checking package. And there is mistake when building from source. (In January 8th build there were any errors)

g++ -std=gnu++11 -I"/home/travis/R-bin/lib/R/include" -DNDEBUG -I. -I/usr/include/x86_64-linux-gnu -UDEBUG -DNDEBUG -DU_HAVE_ELF_H -I/home/travis/R-bin/include -fpic -fpic -g -O2 -c stri_search_regex_count.cpp -o stri_search_regex_count.o

stri_search_regex_count.cpp: In function ‘SEXPREC* stri_count_regex(SEXP, SEXP, SEXP)’:

stri_search_regex_count.cpp:92:48: error: no matching function for call to ‘icu_52::RegexMatcher::find(UErrorCode&)’

      int m_res = (bool)matcher->find(status);

                                            ^

In file included from stri_container_regex.h:37,

             from stri_search_regex_count.cpp:35:

/usr/include/x86_64-linux-gnu/unicode/regex.h:810:19: note: candidate: ‘virtual UBool icu_52::RegexMatcher::find()’

 virtual UBool find();

               ^~~~

/usr/include/x86_64-linux-gnu/unicode/regex.h:810:19: note: candidate expects 0 arguments, 1 provided

/usr/include/x86_64-linux-gnu/unicode/regex.h:822:19: note: candidate: ‘virtual UBool icu_52::RegexMatcher::find(int64_t, UErrorCode&)’

 virtual UBool find(int64_t start, UErrorCode &status);

               ^~~~

/usr/include/x86_64-linux-gnu/unicode/regex.h:822:19: note: candidate expects 2 arguments, 1 provided

make: *** [stri_search_regex_count.o] Error 1

ERROR: compilation failed for package ‘stringi’

Also will be helpful:

Build system information

Build language: r

Build group: stable

Build dist: trusty

Build id: 143912341

Job id: 274289251

Runtime kernel version: 4.4.0-101-generic

travis-build version: 1c634e1df

Build image provisioning date and time

Tue Dec 5 21:46:03 UTC 2017

Operating System Details

Distributor ID: Ubuntu

Description: Ubuntu 14.04.5 LTS

Release: 14.04

Codename: trusty

Cookbooks Version

7c2c6a6 https://github.com/travis-ci/travis-cookbooks/tree/7c2c6a6

git version

git version 2.15.1

bash version

GNU bash, version 4.3.11(1)-release (x86_64-pc-linux-gnu)

gcc version

gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4

Copyright (C) 2013 Free Software Foundation, Inc.

This is free software; see the source for copying conditions. There is NO

warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

jeroen commented 4 years ago

A lot of people see this error on Travis workers that run Ubuntu 14.04.

It was introduced by https://github.com/gagolews/stringi/commit/476e086519c1699be2be51a35ddfd1ca96b6702c because the matcher->find(status) api is not available on ICU 52.1.

g++ -std=gnu++11 -I"/home/travis/R-bin/lib/R/include" -DNDEBUG -I. -I/usr/include/x86_64-linux-gnu     -UDEBUG -DNDEBUG -DU_HAVE_ELF_H  -I/home/travis/R-bin/include -fpic -fpic  -g -O2  -c stri_search_regex_count.cpp -o stri_search_regex_count.o
stri_search_regex_count.cpp: In function ‘SEXPREC* stri_count_regex(SEXP, SEXP, SEXP)’:
stri_search_regex_count.cpp:92:48: error: no matching function for call to ‘icu_52::RegexMatcher::find(UErrorCode&)’
          int m_res = (bool)matcher->find(status);
                                                ^
stri_search_regex_count.cpp:92:48: note: candidates are:
In file included from stri_container_regex.h:37:0,
                 from stri_search_regex_count.cpp:35:
/usr/include/x86_64-linux-gnu/unicode/regex.h:810:19: note: virtual UBool icu_52::RegexMatcher::find()
     virtual UBool find();
                   ^
/usr/include/x86_64-linux-gnu/unicode/regex.h:810:19: note:   candidate expects 0 arguments, 1 provided
/usr/include/x86_64-linux-gnu/unicode/regex.h:822:19: note: virtual UBool icu_52::RegexMatcher::find(int64_t, UErrorCode&)
     virtual UBool find(int64_t start, UErrorCode &status);
                   ^
/usr/include/x86_64-linux-gnu/unicode/regex.h:822:19: note:   candidate expects 2 arguments, 1 provided
gagolews commented 4 years ago

Duplicate of #366

Fix on the way to CRAN.