mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

203 lines
8.7 KiB

  1. Copied from linuxfromscratch.org and rediffed against 4.1.2 for ROCK Linux.
  2. Submitted By: Jim Gifford (patches at jg555 dot com)
  3. Date: 2005-08-27
  4. Initial Package Version: 4.0.1
  5. Origin: Jim Gifford
  6. Rediffed against 4.1.0 by Chris Staub
  7. Upstream Status: On Hold
  8. Description: Makes GCC Posix Compliant
  9. --- gcc-4.1.2/contrib/test_summary 2004-08-26 07:51:22.000000000 +0200
  10. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/contrib/test_summary 2007-09-17 03:26:52.000000000 +0200
  11. @@ -106,7 +106,7 @@
  12. srcdir = configflags;
  13. sub(/\/configure .*/, "", srcdir);
  14. printf "LAST_UPDATED: ";
  15. - system("tail -1 " srcdir "/LAST_UPDATED");
  16. + system("tail -n 1 " srcdir "/LAST_UPDATED");
  17. print "";
  18. sub(/^[^ ]*\/configure */, " ", configflags);
  19. --- gcc-4.1.2/gcc/configure 2006-11-13 23:09:55.000000000 +0100
  20. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/gcc/configure 2007-09-17 03:26:52.000000000 +0200
  21. @@ -14318,7 +14318,7 @@
  22. # and we got the correct data, then succeed.
  23. if test x$gcc_cv_objdump != x \
  24. && $gcc_cv_objdump -s -j .eh_frame conftest.o 2>/dev/null \
  25. - | tail -3 > conftest.got \
  26. + | tail -n 3 > conftest.got \
  27. && { cmp conftest.lit conftest.got > /dev/null 2>&1 \
  28. || cmp conftest.big conftest.got > /dev/null 2>&1; }
  29. then
  30. --- gcc-4.1.2/gcc/configure.ac 2006-11-13 23:09:55.000000000 +0100
  31. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/gcc/configure.ac 2007-09-17 03:26:52.000000000 +0200
  32. @@ -2124,7 +2124,7 @@
  33. # and we got the correct data, then succeed.
  34. if test x$gcc_cv_objdump != x \
  35. && $gcc_cv_objdump -s -j .eh_frame conftest.o 2>/dev/null \
  36. - | tail -3 > conftest.got \
  37. + | tail -n 3 > conftest.got \
  38. && { cmp conftest.lit conftest.got > /dev/null 2>&1 \
  39. || cmp conftest.big conftest.got > /dev/null 2>&1; }
  40. then
  41. --- gcc-4.1.2/libjava/configure 2007-02-14 06:17:22.000000000 +0100
  42. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/libjava/configure 2007-09-17 03:26:52.000000000 +0200
  43. @@ -6736,8 +6736,8 @@
  44. echo $ECHO_N "checking whether 'ld' is at least 2.13... $ECHO_C" >&6
  45. LD_PROG=`$CC --print-prog-name=ld`
  46. LD_VERSION=`$LD_PROG --version`
  47. -LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  48. -LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 2`
  49. +LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  50. +LD_VERSION_MINOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 2`
  51. if expr "$LD_VERSION_MAJOR" \> 2 > /dev/null; then
  52. LD_OK="ok"
  53. else
  54. --- gcc-4.1.2/libjava/mingwld.m4 2005-08-23 00:36:35.000000000 +0200
  55. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/libjava/mingwld.m4 2007-09-17 03:26:52.000000000 +0200
  56. @@ -3,8 +3,8 @@
  57. AC_MSG_CHECKING(whether 'ld' is at least 2.13)
  58. LD_PROG=`$CC --print-prog-name=ld`
  59. LD_VERSION=`$LD_PROG --version`
  60. -LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  61. -LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 2`
  62. +LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  63. +LD_VERSION_MINOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 2`
  64. if expr "$LD_VERSION_MAJOR" \> 2 > /dev/null; then
  65. LD_OK="ok"
  66. else
  67. --- gcc-4.1.2/libstdc++-v3/acinclude.m4 2007-01-29 11:51:01.000000000 +0100
  68. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/libstdc++-v3/acinclude.m4 2007-09-17 07:33:27.000000000 +0200
  69. @@ -224,7 +224,7 @@
  70. # does some of this, but throws away the result.
  71. if test x"$with_gnu_ld" = x"yes"; then
  72. changequote(,)
  73. - ldver=`$LD --version 2>/dev/null | head -1 | \
  74. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  75. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  76. changequote([,])
  77. glibcxx_gnu_ld_version=`echo $ldver | \
  78. --- gcc-4.1.2/libstdc++-v3/configure 2007-01-29 11:51:01.000000000 +0100
  79. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/libstdc++-v3/configure 2007-09-17 07:37:10.000000000 +0200
  80. @@ -8280,7 +8280,7 @@
  81. # does some of this, but throws away the result.
  82. if test x"$with_gnu_ld" = x"yes"; then
  83. - ldver=`$LD --version 2>/dev/null | head -1 | \
  84. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  85. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  86. glibcxx_gnu_ld_version=`echo $ldver | \
  87. @@ -53121,7 +53121,7 @@
  88. # does some of this, but throws away the result.
  89. if test x"$with_gnu_ld" = x"yes"; then
  90. - ldver=`$LD --version 2>/dev/null | head -1 | \
  91. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  92. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  93. glibcxx_gnu_ld_version=`echo $ldver | \
  94. @@ -74455,7 +74455,7 @@
  95. # does some of this, but throws away the result.
  96. if test x"$with_gnu_ld" = x"yes"; then
  97. - ldver=`$LD --version 2>/dev/null | head -1 | \
  98. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  99. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  100. glibcxx_gnu_ld_version=`echo $ldver | \
  101. @@ -75952,7 +75952,7 @@
  102. # does some of this, but throws away the result.
  103. if test x"$with_gnu_ld" = x"yes"; then
  104. - ldver=`$LD --version 2>/dev/null | head -1 | \
  105. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  106. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  107. glibcxx_gnu_ld_version=`echo $ldver | \
  108. @@ -77325,7 +77325,7 @@
  109. # does some of this, but throws away the result.
  110. if test x"$with_gnu_ld" = x"yes"; then
  111. - ldver=`$LD --version 2>/dev/null | head -1 | \
  112. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  113. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  114. glibcxx_gnu_ld_version=`echo $ldver | \
  115. @@ -79485,7 +79485,7 @@
  116. # does some of this, but throws away the result.
  117. if test x"$with_gnu_ld" = x"yes"; then
  118. - ldver=`$LD --version 2>/dev/null | head -1 | \
  119. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  120. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  121. glibcxx_gnu_ld_version=`echo $ldver | \
  122. @@ -80304,7 +80304,7 @@
  123. # does some of this, but throws away the result.
  124. if test x"$with_gnu_ld" = x"yes"; then
  125. - ldver=`$LD --version 2>/dev/null | head -1 | \
  126. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  127. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  128. glibcxx_gnu_ld_version=`echo $ldver | \
  129. @@ -81679,7 +81679,7 @@
  130. # does some of this, but throws away the result.
  131. if test x"$with_gnu_ld" = x"yes"; then
  132. - ldver=`$LD --version 2>/dev/null | head -1 | \
  133. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  134. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  135. glibcxx_gnu_ld_version=`echo $ldver | \
  136. @@ -83446,7 +83446,7 @@
  137. # does some of this, but throws away the result.
  138. if test x"$with_gnu_ld" = x"yes"; then
  139. - ldver=`$LD --version 2>/dev/null | head -1 | \
  140. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  141. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  142. glibcxx_gnu_ld_version=`echo $ldver | \
  143. @@ -84663,7 +84663,7 @@
  144. # does some of this, but throws away the result.
  145. if test x"$with_gnu_ld" = x"yes"; then
  146. - ldver=`$LD --version 2>/dev/null | head -1 | \
  147. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  148. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  149. glibcxx_gnu_ld_version=`echo $ldver | \
  150. @@ -85664,7 +85664,7 @@
  151. # does some of this, but throws away the result.
  152. if test x"$with_gnu_ld" = x"yes"; then
  153. - ldver=`$LD --version 2>/dev/null | head -1 | \
  154. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  155. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  156. glibcxx_gnu_ld_version=`echo $ldver | \
  157. --- gcc-4.1.2/ltcf-c.sh 2005-11-18 23:53:08.000000000 +0100
  158. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/ltcf-c.sh 2007-09-17 03:26:53.000000000 +0200
  159. @@ -153,7 +153,7 @@
  160. # If the export-symbols file already is a .def file (1st line
  161. # is EXPORTS), use it as is.
  162. # If DATA tags from a recent dlltool are present, honour them!
  163. - archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
  164. + archive_expsym_cmds='if test "x`head -n 1 $export_symbols`" = xEXPORTS; then
  165. cp $export_symbols $output_objdir/$soname-def;
  166. else
  167. echo EXPORTS > $output_objdir/$soname-def;
  168. --- gcc-4.1.2/ltcf-gcj.sh 2005-07-16 04:30:53.000000000 +0200
  169. +++ src.gcc41.1189992263.16998.3710433526/gcc-4.1.2/ltcf-gcj.sh 2007-09-17 03:26:53.000000000 +0200
  170. @@ -156,7 +156,7 @@
  171. # If the export-symbols file already is a .def file (1st line
  172. # is EXPORTS), use it as is.
  173. # If DATA tags from a recent dlltool are present, honour them!
  174. - archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
  175. + archive_expsym_cmds='if test "x`head -n 1 $export_symbols`" = xEXPORTS; then
  176. cp $export_symbols $output_objdir/$soname-def;
  177. else
  178. echo EXPORTS > $output_objdir/$soname-def;