On Sat, 12 Nov 2005 09:58:49 -0800, Jerry Gay wrote: > > the following output is snipped from parrot's build output with msvc-7.1:
> classes\env.pmc(26) : warning C4273: '__p__environ' : inconsistent dll linkage > D:\usr\local\perl\bin\perl.exe build_tools\pmc2c.pl --c > classes\env.pmc > normally, i'm able to squash all compiler warnings, but i'm having > trouble tracking this one down. this, by the way, is the *final* > compiler warning with msvc, so the person who fixes this bug gets the > 'clean windows' award :) The story goes like this: classes/env.pmc extern char **environ; Vc7/include/stdlib.h #define environ _environ #define _environ (*__p__environ()) _CRTIMP char *** __cdecl __p__environ(void); #define _CRTIMP __declspec(dllimport) So, F<classes/env.pmc> declares C<environ> without specific linkage, whereas F<stdlib.h> says it should be imported from a DLL (namely msvcrt71.dll). Hence the "inconsistent dll linkage" warning. There are two possible solutions: 1) Don't declare C<environ> in F<classes/env.pmc> 2) "Correctly" declare C<environ> as _CRTIMP extern char **environ; Hope this helps, Ron