Building the systemimager-4.0.2-1.src.rpm on x86_64 on Centos5 fails with an error on kexec: $ rpmbuild -bb SPECS/systemimager.spec ... ... gcc -g -O2 -Wall -g -fno-strict-aliasing -I./include -I./util_lib/include -DVERSION='"20061214"' -DRELEASE_DATE='"14th December 2006"' -DPACKAGE='"kexec-tools-testing"' -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_ZLIB_H=1 -Wall -g -fno-strict-aliasing -Ikexec/arch/x86_64/include -o /root/RPM/BUILD/systemimager-4.0.2/src/kexec-tools-testing-20061214/objdir/kexec/arch/i386/kexec-multiboot-x86.o -c kexec/arch/i386/kexec-multiboot-x86.c kexec/kexec-elf-rel.c: In function ‘elf_rel_load’: kexec/kexec-elf-rel.c:115: warning: ‘rela.r_offset’ may be used uninitialized in this function kexec/kexec-elf-rel.c:115: warning: ‘rela.r_sym’ may be used uninitialized in this function kexec/kexec-elf-rel.c:115: warning: ‘rela.r_type’ may be used uninitialized in this function kexec/kexec-elf-rel.c:115: warning: ‘rela.r_addend’ may be used uninitialized in this function kexec/kexec-elf-rel.c:90: warning: ‘rela.r_offset’ may be used uninitialized in this function kexec/kexec-elf-rel.c:90: warning: ‘rela.r_sym’ may be used uninitialized in this function kexec/kexec-elf-rel.c:90: warning: ‘rela.r_type’ may be used uninitialized in this function kexec/kexec-elf-rel.c:90: warning: ‘rela.r_addend’ may be used uninitialized in this function kexec/arch/i386/kexec-multiboot-x86.c: In function ‘multiboot_x86_load’: kexec/arch/i386/kexec-multiboot-x86.c:217: warning: pointer targets in passing argument 3 of ‘elf_rel_build_load’ differ in signedness kexec/arch/i386/kexec-elf-x86.c: In function ‘elf_x86_load’: kexec/arch/i386/kexec-elf-x86.c:189: warning: pointer targets in passing argument 3 of ‘elf_rel_build_load’ differ in signedness kexec/arch/i386/kexec-elf-x86.c:202: warning: pointer targets in passing argument 3 of ‘elf_boot_notes’ differ in signedness kexec/arch/i386/kexec-elf-x86.c:250: warning: pointer targets in assignment differ in signedness kexec/arch/i386/kexec-multiboot-x86.c:346: error: ‘PAGE_SIZE’ undeclared (first use in this function) kexec/arch/i386/kexec-multiboot-x86.c:346: error: (Each undeclared identifier is reported only once kexec/arch/i386/kexec-multiboot-x86.c:346: error: for each function it appears in.) mkdir -p /root/RPM/BUILD/systemimager-4.0.2/src/kexec-tools-testing-20061214/objdir/kexec/arch/i386 kexec/arch/i386/kexec-bzImage.c: In function ‘do_bzImage_load’: kexec/arch/i386/kexec-bzImage.c:131: warning: pointer targets in assignment differ in signedness make[1]: *** [/root/RPM/BUILD/systemimager-4.0.2/src/kexec-tools-testing-20061214/objdir/kexec/arch/i386/kexec-multiboot-x86.o] Error 1 make[1]: *** Waiting for unfinished jobs.... kexec/arch/i386/kexec-bzImage.c:187: warning: pointer targets in passing argument 3 of ‘elf_rel_build_load’ differ in signedness kexec/arch/i386/kexec-bzImage.c:190: warning: pointer targets in passing argument 3 of ‘elf_rel_build_load’ differ in signedness kexec/arch/i386/kexec-bzImage.c:251: warning: pointer targets in passing argument 7 of ‘setup_linux_bootloader_parameters’ differ in signedness gcc -g -O2 -Wall -g -fno-strict-aliasing -I./include -I./util_lib/include -DVERSION='"20061214"' -DRELEASE_DATE='"14th December 2006"' -DPACKAGE='"kexec-tools-testing"' -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_ZLIB_H=1 -Wall -g -fno-strict-aliasing -Ikexec/arch/x86_64/include -o /root/RPM/BUILD/systemimager-4.0.2/src/kexec-tools-testing-20061214/objdir/kexec/arch/i386/kexec-beoboot-x86.o -c kexec/arch/i386/kexec-beoboot-x86.c kexec/arch/i386/kexec-beoboot-x86.c: In function ‘beoboot_load’: kexec/arch/i386/kexec-beoboot-x86.c:125: warning: pointer targets in assignment differ in signedness kexec/arch/i386/kexec-beoboot-x86.c:136: warning: pointer targets in passing argument 2 of ‘do_bzImage_load’ differ in signedness kexec/arch/i386/kexec-beoboot-x86.c:136: warning: pointer targets in passing argument 4 of ‘do_bzImage_load’ differ in signedness kexec/arch/i386/kexec-beoboot-x86.c:136: warning: pointer targets in passing argument 6 of ‘do_bzImage_load’ differ in signedness make[1]: Leaving directory `/root/RPM/BUILD/systemimager-4.0.2/src/kexec-tools-testing-20061214' make: *** [/root/RPM/BUILD/systemimager-4.0.2/src/kexec-tools-testing-20061214/objdir/build/sbin/kexec] Error 2 error: Bad exit status from /var/tmp/rpm-tmp.51508 (%build)
This appears to be related to this issue: http://osdir.com/ml/boot-loaders.fastboot.general/2007-02/msg00307.html Adding the following patch to the file systemimager-4.0.2/patches/kexec.multiboot.patch allows the build to complete: --- ./kexec/arch/i386/kexec-multiboot-x86.c 2008-06-24 14:53:12.000000000 +0100 +++ ./kexec_foo/arch/i386/kexec-multiboot-x86.c 2008-06-24 14:51:59.000000000 +0100 @@ -343,7 +343,7 @@ /* Pick the next aligned spot to load it in */ freespace = add_buffer(info, buf, mod_size, mod_size, - PAGE_SIZE, 0, 0xffffffffUL, 1); + getpagesize(), 0, 0xffffffffUL, 1); /* Add the module command line */ sprintf(mod_clp, "%s", mod_command_line); -- Jonathan Barber High Performance Computing Analyst Tel. +44 (0) 1382 386389 ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ sisuite-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/sisuite-users
