Thank you so much for the response :-) ..As it has been suspected, the
module is compiled with sun cc compiler, in 64 bit Solaris environment.
I can be happy with 32 bit compilation with gcc compiler also. Here I tried
recompiling PAR-Packer by re-generating the makefile with the command:
perl Makefile.PL CC=gcc
Here in the Makefile, the CC flag is chosen as 'gcc' as I expected. But
still when I do a 'make', All the 'C' libraries are again getting compiled
with 'cc' compiler so I still get that warning from sha1.c file.
From the above discussion, if I some how use 'gcc' and re-compile the
package, this warning will be gone? If so, can you please guide as to how to
make the module use 'gcc' instead of 'cc'.
Further more, how far this 'sha1.c' file involve in the basic functionality
of PAR-Packer?? Is this warning something really important that I'm not
supposed to get? Because, I use pp in the scripts directory to generate the
*.par file and I use par.pl file to generate the executable binary. Every
thing is working fine for me.
I believe that, since the whole idea of this module deals with binaries and
stuff, and this warning I got is, I guess relates to bit copy (>> operator
has to do some thing with bit/byte shift am I right?) Should I take it more
seriously?
Many Thanks,
Bhaskar.S
Show quoted text----- Original Message -----
From: "RSCHUPP via RT" <bug-PAR@rt.cpan.org>
To: <bhaskar_s@thbs.com>
Sent: Tuesday, February 03, 2009 6:13 PM
Subject: [rt.cpan.org #41866] Warning message for file sha1.c when doing a
'make'
> <URL:
https://rt.cpan.org/Ticket/Display.html?id=41866 >
>
> If I read the code in myldr/sha1.c correctly the line should be
>
> W[i] = T32(T >> 32);
>
> which is inside a #if BYTEORDER == 0x87654321
>
> This warning implies that ULONG is a 32-bit quantity whereas
> the code assumes is 64-bit.
> "/usr/perl5/5.6.1/lib/sun4-solaris-64int/CORE/config.h" in the
> other warning implies is that this is a 64-bit Perl and
> the one shipped with Solaris. Is it a 64-bit Solaris then?
> What compiler was used, the Sun compiler or gcc?
>
> Sorry, I don't have access to a 64-bit Solaris, but the
> following lines at the start of sha1.c look highly suspicious:
>
> #if defined(U64TYPE) && (defined(USE_64_BIT_INT) || ((BYTEORDER !=
> 0x1234) && (BYTEORDER != 0x4321)))
> typedef U64TYPE ULONG;
> # if BYTEORDER == 0x1234
> # undef BYTEORDER
> # define BYTEORDER 0x12345678
> # elif BYTEORDER == 0x4321
> # undef BYTEORDER
> # define BYTEORDER 0x87654321
> # endif
> #else
> # if (!defined(__GNUC__) || !defined(_WINNT_H))
> typedef unsigned long ULONG; /* 32-or-more-bit quantity */
> # endif
> #endif
>
> Looks like the author is trying to work around some flaw
> in Perl's configuration - he overrides BYTEORDER obtained from
> $Config{byteorder}. Note that macros USE_64_BIT_INT and
> U64TYPE are #define'd in the above config.h, but it isn't
> #include'd anywhere. So assuming a non-gcc compiler
> (since gcc will #define __GNUC__) this would imply
>
> typedef unsigned long ULONG; /* 32-or-more-bit quantity */
>
> takes hold which might explain the mismatch (probably should
> be "unsigned long long").
>