---------- Forwarded message ----------
From: li fei <tezuka158@gmail.com>
Date: 2007-10-12 ÏÂÎç12:00
Subject: The problem of grub-0.97 install
To: l4 <l4-hackers@os.inf.tu-dresden.de>

Hi!all,
    When I compiled the grub, I met some problems. I patched the patches which I down from the http://os.inf.tu-dresden.de/~adam/grub/0.97/.
    I patched the patches from the grub-0.97-os.1.diff to the grub-0.97-grub-0.97-os.5.diff, and I found they all have mistakes, the error from the grub-0.97-os.2.diff to the grub-0.97-os.5 were the same.Below are the errors:

    pre_stage2_exec-bios.o : In function `get_cdinfo':
    /home/l4/Desktop/grub-0.97/stage2/bios.c:179: undefined reference to `__stack_chk_fail'
    pre_stage2_exec-bios.o: In function `get_diskinfo':
    /home/l4/Desktop/grub- 0.97/stage2/bios.c:317: undefined reference to `__stack_chk_fail'
    pre_stage2_exec-boot.o: In function `load_image':
    /home/l4/Desktop/grub-0.97/stage2/boot.c:759: undefined reference to `__stack_chk_fail'
    pre_stage2_exec-builtins.o: In function `blocklist_func':
    /home/l4/Desktop/grub-0.97/stage2/builtins.c:224: undefined reference to `__stack_chk_fail'
    pre_stage2_exec-builtins.o: In function `embed_func':
    /home/l4/Desktop/grub-0.97/stage2/builtins.c:1191: undefined reference to `__stack_chk_fail'
    pre_stage2_exec-builtins.o:/home/l4/Desktop
/grub-0.97/stage2/builtins.c:1350: more undefined references to `__stack_chk_fail' follow
    collect2: ld returned 1 exit status
    make[2]: *** [pre_stage2.exec] Error 1
    make[2]: Leaving directory `/home/l4/Desktop/grub-0.97/stage2'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/home/l4/Desktop/grub- 0.97'
    make: *** [all] Error 2

    And the error when I patched the grub-0.97-os.1.diff is different. The error is below:
   
   
  builtins.c: In function 'vbeset_func':
  builtins.c :4891: warning: pointer targets in passing argument 1 of 'get_vbe_pmif' differ in signedness
  builtins.c:4891: warning: pointer targets in passing argument 2 of 'get_vbe_pmif' differ in signedness
  builtins.c: In function 'toggle_func':
  builtins.c:5463: error: invalid storage class for function 'process_var'
  builtins.c:5463: warning: no previous prototype for 'process_var'
  builtins.c:5523: error: invalid storage class for function 'process_block'
  builtins.c:5523: warning: no previous prototype for 'process_block'
  builtins.c: In function 'toggle_trigger_init':
  builtins.c:5744: error: invalid storage class for function 'detect_vmware'
  builtins.c:5744: warning: no previous prototype for 'detect_vmware'
  make[2]: *** [pre_stage2_exec- builtins.o] Error 1
  make[2]: Leaving directory `/home/l4/grub-0.97/stage2'
  make[1]: *** [all-recursive] Error 1
  make[1]: Leaving directory `/home/l4/grub-0.97'
  make: *** [all] Error 2

 I compiled the grub under the ubuntu 7.04 environment, using the gcc-4.1.2 and g++-4.1.2.