Bent Vangli
2005-Jul-04 20:49 UTC
[Samba] Samba Compile Error on 3.0.7 and 3.0.8 Pre 1 on X64 Fedora
Hi Exact same error occures on a dual AMD64 Fedora Core 3 64 bit with samba 3.0.20Pre1. However, I have discovered taht putting the compile option "-m32" in the C compiler flags, which force 32 bit compilation, the error doesn't happen. The sad part of the story is that compilation crash later in the process. It may be a compilatotor/linker error when assembler code is created, but it may as well be some some 32/64 bit spesific code creating this odd stuff. The generated assemblercode is deleted before I could investigate it, and I haven't the knowledge of how to keep it. A medicine to this problem should be found, and I am sure it exists because a samba 3.10.x rpm compiled for Fedora Core 3 64 bit is in existence. Sadly, I havent' been able to find those settings. Maybe someone knows? with best regards Bent Vangli
Guus Leeuw jr.
2005-Jul-05 03:22 UTC
[Samba] Samba Compile Error on 3.0.7 and 3.0.8 Pre 1 on X64 Fedora
> -----Original Message----- > From: samba-bounces+guus-leeuw=gmx.de@lists.samba.org [mailto:samba- > bounces+guus-leeuw=gmx.de@lists.samba.org] On Behalf Of Bent Vangli > Sent: Monday, July 04, 2005 22:49 > > It may be a compilatotor/linker error when assembler code is created, but > it may as well be some some 32/64 bit spesific code creating this odd > stuff. The generated assemblercode is deleted before I could investigate > it, and I haven't the knowledge of how to keep it.gcc -S source.c > source.S Guus -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.323 / Virus Database: 267.8.8/37 - Release Date: 01/07/2005
Bent Vangli
2005-Jul-06 20:45 UTC
[Samba] Samba Compile Error on 3.0.7 and 3.0.8 Pre 1 on X64 Fedora
Hi Thank Guus. Your advise helped. I am now able to pinpoint the exact code that creates this error. References below are to Samba 3.0.20Pre1 "dynconfig.c" has an include statement that incorporate the file "include/includes.h". This latter file. On line 494 in this file a macro is runned if you have valgrind installed (valgrind is a memory check utility designed for x86 processors): /* Special macros that are no-ops except when run under Valgrind on * x86. They've moved a little bit from valgrind 1.0.4 to 1.9.4 */ #if HAVE_VALGRIND_MEMCHECK_H /* memcheck.h includes valgrind.h */ #include <valgrind/memcheck.h> #elif HAVE_VALGRIND_H #include <valgrind.h> #endif Using your advise Guus, I edited the Makefile to create .S file an analyzed it. As the error report stated during normal compilation, I found on both reported error lines the following assembler code: movl %rsi, %eax This statement doesn't seem to be valid for the AMD64 processor. I also tryed to download a fresh new version of valgrind. That to bailed out in error because of this statement. IMHO it looks like that valgrind isn't 64 bit compliant. Further on it also look like samba detect the 64 bit prosecor as x86 (which isn't tatally wrong :-)) ) and therefor include valgrind code if that is installed. On Fedora 64 bit version, valgrind is included in the 32 bit parts, and thus is used. Suggestion: A better test should be included to not select valgrind on 64 bit systemes, or better - valgrind should be rewritten to be 64 bit compliant. Medicine: Delete the above section in "include/includes.h", then compilation run just fine. All tests was done on Fedora Core 3 64 bit dual opteron system. Very best regards Bent Vangli