diff --git a/ChangeLog b/ChangeLog index 62df432ae..d1dd888c6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +1999-09-23 OKUJI Yoshinori + + * acinclude.m4 (grub_ASM_ADDR32): First, create a template + source file "conftest.s.in", and then, replace @ADDR32@ with + "addr32" if GRUB_CV_ASM_PREFIX_REQUIREMENT is yes, otherwise, + replace it with "addr32;". Reported by John Tobey + . + 1999-09-23 OKUJI Yoshinori * stage2/builtins.c (debug_fs_print_func): Renamed to ... diff --git a/THANKS b/THANKS index 69e74d830..0fe291fa5 100644 --- a/THANKS +++ b/THANKS @@ -17,6 +17,7 @@ Eric Hanchrow Heiko Schroeder Hisazumi Kenji Jochen Hoenicke +John Tobey Klaus Reichl Kunihiro Ishiguro Mark Lundeberg diff --git a/acinclude.m4 b/acinclude.m4 index 1c4a0c372..3f927b3c1 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -93,17 +93,25 @@ AC_DEFUN(grub_ASM_ADDR32, AC_REQUIRE([grub_ASM_PREFIX_REQUIREMENT]) AC_MSG_CHECKING([for .code16 addr32 assembler support]) AC_CACHE_VAL(grub_cv_asm_addr32, -[cat > conftest.s <<\EOF +[cat > conftest.s.in <<\EOF .code16 -l1: ADDR32 movb %al, l1 +l1: @ADDR32@ movb %al, l1 EOF +if test "x$grub_cv_asm_prefix_requirement" = xyes; then + sed -e s/@ADDR32@/addr32/ < conftest.s.in > conftest.s +else + sed -e s/@ADDR32@/addr32\;/ < conftest.s.in > conftest.s +fi + if AC_TRY_COMMAND([${CC-cc} -c conftest.s]) && test -s conftest.o; then grub_cv_asm_addr32=yes else grub_cv_asm_addr32=no fi + rm -f conftest*]) + AC_MSG_RESULT([$grub_cv_asm_addr32])]) dnl diff --git a/aclocal.m4 b/aclocal.m4 index 369077bfd..e89e2d7f3 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -105,17 +105,25 @@ AC_DEFUN(grub_ASM_ADDR32, AC_REQUIRE([grub_ASM_PREFIX_REQUIREMENT]) AC_MSG_CHECKING([for .code16 addr32 assembler support]) AC_CACHE_VAL(grub_cv_asm_addr32, -[cat > conftest.s <<\EOF +[cat > conftest.s.in <<\EOF .code16 -l1: ADDR32 movb %al, l1 +l1: @ADDR32@ movb %al, l1 EOF +if test "x$grub_cv_asm_prefix_requirement" = xyes; then + sed -e s/@ADDR32@/addr32/ < conftest.s.in > conftest.s +else + sed -e s/@ADDR32@/addr32\;/ < conftest.s.in > conftest.s +fi + if AC_TRY_COMMAND([${CC-cc} -c conftest.s]) && test -s conftest.o; then grub_cv_asm_addr32=yes else grub_cv_asm_addr32=no fi + rm -f conftest*]) + AC_MSG_RESULT([$grub_cv_asm_addr32])]) dnl diff --git a/configure b/configure index 73d63014f..c34d7897a 100644 --- a/configure +++ b/configure @@ -1611,19 +1611,27 @@ echo "configure:1611: checking for .code16 addr32 assembler support" >&5 if eval "test \"\${grub_cv_asm_addr32+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.s <<\EOF + cat > conftest.s.in <<\EOF .code16 -l1: ADDR32 movb %al, l1 +l1: @ADDR32@ movb %al, l1 EOF -if { ac_try='${CC-cc} -c conftest.s'; { (eval echo configure:1620: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then +if test "x$grub_cv_asm_prefix_requirement" = xyes; then + sed -e s/@ADDR32@/addr32/ < conftest.s.in > conftest.s +else + sed -e s/@ADDR32@/addr32\;/ < conftest.s.in > conftest.s +fi + +if { ac_try='${CC-cc} -c conftest.s'; { (eval echo configure:1626: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then grub_cv_asm_addr32=yes else grub_cv_asm_addr32=no fi + rm -f conftest* fi + echo "$ac_t""$grub_cv_asm_addr32" 1>&6 if test "x$grub_cv_asm_addr32" != xyes; then { echo "configure: error: GRUB requires GAS .code16 addr32 support; upgrade your binutils" 1>&2; exit 1; } @@ -1631,7 +1639,7 @@ fi echo $ac_n "checking if start is defined by the compiler""... $ac_c" 1>&6 -echo "configure:1635: checking if start is defined by the compiler" >&5 +echo "configure:1643: checking if start is defined by the compiler" >&5 if eval "test \"\${grub_cv_check_start_symbol+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1644,7 +1652,7 @@ main (void) } EOF -if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1648: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then +if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1656: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then grub_cv_check_start_symbol=yes else grub_cv_check_start_symbol=no @@ -1665,7 +1673,7 @@ echo "$ac_t""$grub_cv_check_start_symbol" 1>&6 echo $ac_n "checking if _start is defined by the compiler""... $ac_c" 1>&6 -echo "configure:1669: checking if _start is defined by the compiler" >&5 +echo "configure:1677: checking if _start is defined by the compiler" >&5 if eval "test \"\${grub_cv_check_uscore_start_symbol+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1678,7 +1686,7 @@ main (void) } EOF -if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1682: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then +if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then grub_cv_check_uscore_start_symbol=yes else grub_cv_check_uscore_start_symbol=no @@ -1704,7 +1712,7 @@ fi echo $ac_n "checking if end is defined by the compiler""... $ac_c" 1>&6 -echo "configure:1708: checking if end is defined by the compiler" >&5 +echo "configure:1716: checking if end is defined by the compiler" >&5 if eval "test \"\${grub_cv_check_end_symbol+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1717,7 +1725,7 @@ main (void) } EOF -if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1721: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then +if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1729: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then grub_cv_check_end_symbol=yes else grub_cv_check_end_symbol=no @@ -1738,7 +1746,7 @@ echo "$ac_t""$grub_cv_check_end_symbol" 1>&6 echo $ac_n "checking if _end is defined by the compiler""... $ac_c" 1>&6 -echo "configure:1742: checking if _end is defined by the compiler" >&5 +echo "configure:1750: checking if _end is defined by the compiler" >&5 if eval "test \"\${grub_cv_check_uscore_end_symbol+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1751,7 +1759,7 @@ main (void) } EOF -if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1755: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then +if { ac_try='${CC-cc} conftest.c -o conftest'; { (eval echo configure:1763: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then grub_cv_check_uscore_end_symbol=yes else grub_cv_check_uscore_end_symbol=no @@ -1777,7 +1785,7 @@ fi # Check for curses libraries. echo $ac_n "checking for wgetch in -lncurses""... $ac_c" 1>&6 -echo "configure:1781: checking for wgetch in -lncurses" >&5 +echo "configure:1789: checking for wgetch in -lncurses" >&5 ac_lib_var=`echo ncurses'_'wgetch | sed 'y%./+-:%__p__%'` if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1785,7 +1793,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lncurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1819,7 +1827,7 @@ EOF else echo "$ac_t""no" 1>&6 echo $ac_n "checking for wgetch in -lcurses""... $ac_c" 1>&6 -echo "configure:1823: checking for wgetch in -lcurses" >&5 +echo "configure:1831: checking for wgetch in -lcurses" >&5 ac_lib_var=`echo curses'_'wgetch | sed 'y%./+-:%__p__%'` if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -1827,7 +1835,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lcurses $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1850: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -1868,7 +1876,7 @@ fi # Check for headers. echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:1872: checking how to run the C preprocessor" >&5 +echo "configure:1880: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -1883,13 +1891,13 @@ else # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1893: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1901: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1900,13 +1908,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1910: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1918: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1917,13 +1925,13 @@ else rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1927: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1935: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1951,17 +1959,17 @@ for ac_hdr in string.h strings.h ncurses/curses.h ncurses.h curses.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:1955: checking for $ac_hdr" >&5 +echo "configure:1963: checking for $ac_hdr" >&5 if eval "test \"\${ac_cv_header_$ac_safe+set}\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1973: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest*