On 8 June 2010 23:05, James Vega wrote:
> On Sun, Jun 6, 2010 at 1:42 PM, björn wrote:
>
>> My config.log looks like this:
>>
>> configure:11865: checking for off_t
>> configure:11895: gcc -c -O2 -fno-strength-reduce -Wall  -DMACOS_X_UNIX
>> -no-cpp-precomp conftest.c >&5
>> configure:11901: $? = 0
>> configure:11916: result: yes
>>
>> It seems that it never even tries to figure out the proper size.
>
> That's the only occurence of off_t?  The size checking is performed much
> later than checking for the existence of off_t.

Yes, that is the only occurrence of off_t.  But...it seems the problem
stems from the fact I use autoconf 2.61 to generate src/configure (I
have to generate this file since my configure.in contains
modifications for MacVim).  See my previous post in reply to Tony.

>> (2) On Mac OS X 10.6 sizeof(long) == sizeof(off_t) so the test in
>> vim.h would never do anything even if (1) was ok.  A new test is
>> needed as to when LONG_LONG_OFF_T should be defined in vim.h.  I guess
>> this will need to be Mac OS X specific, but I don't know for sure
>> hence my first post asking for advice.
>
> The sole purpose of LONG_LONG_OFF_T is for systems where sizeof(long) !=
> sizeof(off_t), since on those systems we can't simply print off_t as a
> long.  Since you've shown that the sizes are the same on your system,
> and forcing use of "%lld" makes your compiler shut up, it looks like a
> bug in your compiler.

$ gcc --version
i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5659)

All I can say is that if you want to print an off_t value on OS X 10.6
then "%lld" must be used or that warning pops up.

Since those two lines in fileio.c are the only places where an off_t
is printed I may just go ahead and add some MacVim-specific #ifdefs to
get rid of the warning in the MacVim code, unless some other solution
presents itself.  I might also try some Apple-specific mailing list to
see if I can get any answers there about this warning.

Thanks,
Björn

-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Raspunde prin e-mail lui