flintlib / arb

Arb has been merged into FLINT -- use https://github.com/flintlib/flint/ instead
http://arblib.org/
GNU Lesser General Public License v2.1
455 stars 137 forks source link

static declaration of ‘fmpz_ui_pow_ui’ follows non-static declaration #454

Closed tillea closed 6 months ago

tillea commented 9 months ago

Hi, when building arb with gcc-13 an issue is uncovered that was reported in a Debian bug report. As you can see there the build fails with

gcc -fPIC -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -I/<<PKGBUILDDIR>> -I/usr/local/  include -I/usr/local/include -I/usr/include -c add_si.c -o ../build/fmpr/add_si.lo -MMD -MP -MF "../build/fmpr/add_si.d" -MT "../build/fmpr/add_si.d" -MT "../build/fmpr/add_si.lo"
In file included from /<<PKGBUILDDIR>>/fmpr.h:30,
                 from add_naive.c:12:
/<<PKGBUILDDIR>>/fmpz_extras.h:208:1: error: static declaration of ‘fmpz_ui_pow_ui’ follows non-static declaration
  208 | fmpz_ui_pow_ui(fmpz_t x, ulong b, ulong e)
      | ^~~~~~~~~~~~~~
In file included from /<<PKGBUILDDIR>>/fmpr.h:23:
/usr/include/flint/fmpz.h:422:6: note: previous declaration of ‘fmpz_ui_pow_ui’ with type ‘void(fmpz *, mp_limb_t,  mp_limb_t)’ {aka ‘void(long int *, long unsigned int,  long unsigned int)’}
  422 | void fmpz_ui_pow_ui(fmpz_t x, ulong b, ulong e);
      |      ^~~~~~~~~~~~~~
...

Kind regards, Andreas.

fredrik-johansson commented 9 months ago

Arb has been merged with flint 3.0; the standalone arb library is not compatible with flint 3.0.

Debian should remove the separate flint-arb package once it has upgraded flint to 3.0.