Bug#827319: vim: FTBFS[alpha,kfreebsd-*]: Test_tagcase() failed

Steven Chamberlain steven at pyro.eu.org
Sat Oct 15 18:19:34 UTC 2016


James McCoy wrote:
> Lo and behold, configuring without --enable-perlinterp but adding
> "-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" to PERL_CFLAGS in
> src/auto/config.mk reproduces the issue.

Thanks, I did miscompile vim-gtk before and came to the wrong
conclusion about -fwrapv

> Which begs the question, why does configure think the defines aren't
> necessary?

By default in <features.h>, unless something else is requested, we will
define:

| # define _POSIX_C_SOURCE        200809L
| # define __USE_XOPEN2K          1

and that means from <stdio.h> we will get fseeko(), but *not*
__USE_LARGEFILE or __USE_LARGEFILE64:

| #if defined __USE_LARGEFILE || defined __USE_XOPEN2K
| # ifndef __USE_FILE_OFFSET64
[...]
| extern int fseeko (FILE *__stream, __off_t __off, int __whence);

and so vim's configure testcase will pass:

| $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
| if ${ac_cv_sys_largefile_source+:} false; then :
|   $as_echo_n "(cached) " >&6
| else
|   while :; do
|   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
| /* end confdefs.h.  */
| #include <sys/types.h> /* for off_t */
|      #include <stdio.h>
| int
| main ()
| {
| int (*fp) (FILE *, off_t, int) = fseeko;
|      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
|   ;
|   return 0;
| }
| _ACEOF
| if ac_fn_c_try_link "$LINENO"; then :
|   ac_cv_sys_largefile_source=no; break
| fi

I will try to see how the situation is different on linux-i386.

Regards,
-- 
Steven Chamberlain
steven at pyro.eu.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-vim-maintainers/attachments/20161015/6d0b14d3/attachment.sig>


More information about the pkg-vim-maintainers mailing list