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.

260 lines
11 KiB

  1. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  2. #
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. # Please add additional copyright information _after_ the line containing
  5. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  6. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  7. #
  8. # ROCK Linux: rock-src/package/base/gcc/gcc40/head-tail.patch
  9. # ROCK Linux is Copyright (C) 1998 - 2006 Clifford Wolf
  10. #
  11. # This patch file is dual-licensed. It is available under the license the
  12. # patched project is licensed under, as long as it is an OpenSource license
  13. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  14. # of the GNU General Public License as published by the Free Software
  15. # Foundation; either version 2 of the License, or (at your option) any later
  16. # version.
  17. #
  18. # --- ROCK-COPYRIGHT-NOTE-END ---
  19. --- ./gcc/testsuite/ada/acats/run_all.sh.orig 2004-04-26 23:15:54.000000000 +0200
  20. +++ ./gcc/testsuite/ada/acats/run_all.sh 2005-03-25 19:24:49.000000000 +0100
  21. @@ -229,7 +229,7 @@
  22. ls ${i}?.adb > ${i}.lst 2> /dev/null
  23. ls ${i}*m.adb >> ${i}.lst 2> /dev/null
  24. ls ${i}.adb >> ${i}.lst 2> /dev/null
  25. - main=`tail -1 ${i}.lst`
  26. + main=`tail -n 1 ${i}.lst`
  27. binmain=`echo $main | sed -e 's/\(.*\)\..*/\1/g'`
  28. echo "BUILD $main" >> $dir/acats.log
  29. EXTERNAL_OBJECTS=""
  30. --- ./gcc/Makefile.in.orig 2005-02-17 09:47:19.000000000 +0100
  31. +++ ./gcc/Makefile.in 2005-03-25 19:24:31.000000000 +0100
  32. @@ -3898,8 +3898,8 @@
  33. for file in $$dir/*$(objext); do \
  34. case "$@" in \
  35. slowcompare* ) \
  36. - tail +16c ./$$file > tmp-foo1; \
  37. - tail +16c stage$$stage/$$file > tmp-foo2 \
  38. + tail -n +16c ./$$file > tmp-foo1; \
  39. + tail -n +16c stage$$stage/$$file > tmp-foo2 \
  40. && (cmp tmp-foo1 tmp-foo2 > /dev/null 2>&1 || echo $$file differs >> .bad_compare) || true; \
  41. ;; \
  42. fastcompare* ) \
  43. --- ./gcc/configure.orig 2005-02-25 19:42:35.000000000 +0100
  44. +++ ./gcc/configure 2005-03-25 19:24:32.000000000 +0100
  45. @@ -13489,7 +13489,7 @@
  46. # and we got the correct data, then succeed.
  47. if test x$gcc_cv_objdump != x \
  48. && $gcc_cv_objdump -s -j .eh_frame conftest.o 2>/dev/null \
  49. - | tail -3 > conftest.got \
  50. + | tail -n 3 > conftest.got \
  51. && { cmp conftest.lit conftest.got > /dev/null 2>&1 \
  52. || cmp conftest.big conftest.got > /dev/null 2>&1; }
  53. then
  54. --- ./gcc/configure.ac.orig 2005-02-25 19:42:35.000000000 +0100
  55. +++ ./gcc/configure.ac 2005-03-25 19:24:33.000000000 +0100
  56. @@ -2211,7 +2211,7 @@
  57. # and we got the correct data, then succeed.
  58. if test x$gcc_cv_objdump != x \
  59. && $gcc_cv_objdump -s -j .eh_frame conftest.o 2>/dev/null \
  60. - | tail -3 > conftest.got \
  61. + | tail -n 3 > conftest.got \
  62. && { cmp conftest.lit conftest.got > /dev/null 2>&1 \
  63. || cmp conftest.big conftest.got > /dev/null 2>&1; }
  64. then
  65. --- ./config/acx.m4.orig 2004-08-14 00:31:45.000000000 +0200
  66. +++ ./config/acx.m4 2005-03-25 19:25:10.000000000 +0100
  67. @@ -228,7 +228,7 @@
  68. [AC_CACHE_CHECK([how to compare bootstrapped objects], gcc_cv_prog_cmp_skip,
  69. [ echo abfoo >t1
  70. echo cdfoo >t2
  71. - gcc_cv_prog_cmp_skip='tail +16c $$f1 > tmp-foo1; tail +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
  72. + gcc_cv_prog_cmp_skip='tail -n +16c $$f1 > tmp-foo1; tail -n +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
  73. if cmp t1 t2 2 2 > /dev/null 2>&1; then
  74. if cmp t1 t2 1 1 > /dev/null 2>&1; then
  75. :
  76. --- ./contrib/test_summary.orig 2004-08-26 07:51:22.000000000 +0200
  77. +++ ./contrib/test_summary 2005-03-25 19:25:10.628454344 +0100
  78. @@ -106,7 +106,7 @@
  79. srcdir = configflags;
  80. sub(/\/configure .*/, "", srcdir);
  81. printf "LAST_UPDATED: ";
  82. - system("tail -1 " srcdir "/LAST_UPDATED");
  83. + system("tail -n 1 " srcdir "/LAST_UPDATED");
  84. print "";
  85. sub(/^[^ ]*\/configure */, " ", configflags);
  86. --- ./libjava/acinclude.m4.orig 2004-09-23 03:14:00.000000000 +0200
  87. +++ ./libjava/acinclude.m4 2005-03-25 19:25:17.422421504 +0100
  88. @@ -17,8 +17,8 @@
  89. AC_MSG_CHECKING(whether 'ld' is at least 2.13)
  90. LD_PROG=`$CC --print-prog-name=ld`
  91. LD_VERSION=`$LD_PROG --version`
  92. -LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  93. -LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 2`
  94. +LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  95. +LD_VERSION_MINOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 2`
  96. if expr "$LD_VERSION_MAJOR" \> 2 > /dev/null; then
  97. LD_OK="ok"
  98. else
  99. --- ./libjava/configure.orig 2005-03-20 00:15:42.000000000 +0100
  100. +++ ./libjava/configure 2005-03-25 19:25:17.592395664 +0100
  101. @@ -5918,8 +5918,8 @@
  102. echo $ECHO_N "checking whether 'ld' is at least 2.13... $ECHO_C" >&6
  103. LD_PROG=`$CC --print-prog-name=ld`
  104. LD_VERSION=`$LD_PROG --version`
  105. -LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  106. -LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d '.' -f 2`
  107. +LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 1 | cut -d ' ' -f 4`
  108. +LD_VERSION_MINOR=`echo "$LD_VERSION" | head -n 1 | cut -d '.' -f 2`
  109. if expr "$LD_VERSION_MAJOR" \> 2 > /dev/null; then
  110. LD_OK="ok"
  111. else
  112. --- ./libstdc++-v3/acinclude.m4.orig 2005-02-24 19:55:16.000000000 +0100
  113. +++ ./libstdc++-v3/acinclude.m4 2005-03-25 19:25:34.534820024 +0100
  114. @@ -241,7 +241,7 @@
  115. # Start by getting the version number. I think the libtool test already
  116. # does some of this, but throws away the result.
  117. changequote(,)
  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. changequote([,])
  122. glibcxx_gnu_ld_version=`echo $ldver | \
  123. --- ./libstdc++-v3/configure.orig 2005-02-24 19:55:17.000000000 +0100
  124. +++ ./libstdc++-v3/configure 2005-03-25 19:25:35.386690520 +0100
  125. @@ -9880,7 +9880,7 @@
  126. # Start by getting the version number. I think the libtool test already
  127. # does some of this, but throws away the result.
  128. - ldver=`$LD --version 2>/dev/null | head -1 | \
  129. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  130. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  131. glibcxx_gnu_ld_version=`echo $ldver | \
  132. @@ -55252,7 +55252,7 @@
  133. # Start by getting the version number. I think the libtool test already
  134. # does some of this, but throws away the result.
  135. - ldver=`$LD --version 2>/dev/null | head -1 | \
  136. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  137. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  138. glibcxx_gnu_ld_version=`echo $ldver | \
  139. @@ -76923,7 +76923,7 @@
  140. # Start by getting the version number. I think the libtool test already
  141. # does some of this, but throws away the result.
  142. - ldver=`$LD --version 2>/dev/null | head -1 | \
  143. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  144. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  145. glibcxx_gnu_ld_version=`echo $ldver | \
  146. @@ -79292,7 +79292,7 @@
  147. # Start by getting the version number. I think the libtool test already
  148. # does some of this, but throws away the result.
  149. - ldver=`$LD --version 2>/dev/null | head -1 | \
  150. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  151. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  152. glibcxx_gnu_ld_version=`echo $ldver | \
  153. @@ -81537,7 +81537,7 @@
  154. # Start by getting the version number. I think the libtool test already
  155. # does some of this, but throws away the result.
  156. - ldver=`$LD --version 2>/dev/null | head -1 | \
  157. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  158. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  159. glibcxx_gnu_ld_version=`echo $ldver | \
  160. @@ -84550,7 +84550,7 @@
  161. # Start by getting the version number. I think the libtool test already
  162. # does some of this, but throws away the result.
  163. - ldver=`$LD --version 2>/dev/null | head -1 | \
  164. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  165. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  166. glibcxx_gnu_ld_version=`echo $ldver | \
  167. @@ -86748,7 +86748,7 @@
  168. # Start by getting the version number. I think the libtool test already
  169. # does some of this, but throws away the result.
  170. - ldver=`$LD --version 2>/dev/null | head -1 | \
  171. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  172. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  173. glibcxx_gnu_ld_version=`echo $ldver | \
  174. @@ -88995,7 +88995,7 @@
  175. # Start by getting the version number. I think the libtool test already
  176. # does some of this, but throws away the result.
  177. - ldver=`$LD --version 2>/dev/null | head -1 | \
  178. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  179. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  180. glibcxx_gnu_ld_version=`echo $ldver | \
  181. @@ -91603,7 +91603,7 @@
  182. # Start by getting the version number. I think the libtool test already
  183. # does some of this, but throws away the result.
  184. - ldver=`$LD --version 2>/dev/null | head -1 | \
  185. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  186. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  187. glibcxx_gnu_ld_version=`echo $ldver | \
  188. @@ -95660,7 +95660,7 @@
  189. # Start by getting the version number. I think the libtool test already
  190. # does some of this, but throws away the result.
  191. - ldver=`$LD --version 2>/dev/null | head -1 | \
  192. + ldver=`$LD --version 2>/dev/null | head -n 1 | \
  193. sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'`
  194. glibcxx_gnu_ld_version=`echo $ldver | \
  195. --- ./ChangeLog.orig 2005-03-14 02:37:04.000000000 +0100
  196. +++ ./ChangeLog 2005-03-25 19:25:09.070691160 +0100
  197. @@ -10853,7 +10853,7 @@
  198. to i386-sco3.2v4. Set TARGETS and CFLAGS for i386-sco3.2v4.
  199. (all-cygnus, native, build-cygnus): Make
  200. $(canonhost)-stamp-3stage-done, not $(host)....
  201. - * test-build.mk (stamp-3stage-compared): Use tail +10c for
  202. + * test-build.mk (stamp-3stage-compared): Use tail -n +10c for
  203. i386-sco3.2v4. Added else true to if command.
  204. Mon Dec 28 12:08:56 1992 Ken Raeburn (raeburn@cygnus.com)
  205. --- ./configure.orig 2005-02-23 11:12:44.000000000 +0100
  206. +++ ./configure 2005-03-25 19:25:09.490627320 +0100
  207. @@ -2158,7 +2158,7 @@
  208. else
  209. echo abfoo >t1
  210. echo cdfoo >t2
  211. - gcc_cv_prog_cmp_skip='tail +16c $$f1 > tmp-foo1; tail +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
  212. + gcc_cv_prog_cmp_skip='tail -n +16c $$f1 > tmp-foo1; tail -n +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
  213. if cmp t1 t2 2 2 > /dev/null 2>&1; then
  214. if cmp t1 t2 1 1 > /dev/null 2>&1; then
  215. :
  216. --- ./ltcf-c.sh.orig 2004-10-02 18:33:06.000000000 +0200
  217. +++ ./ltcf-c.sh 2005-03-25 19:25:09.537620176 +0100
  218. @@ -153,7 +153,7 @@
  219. # If the export-symbols file already is a .def file (1st line
  220. # is EXPORTS), use it as is.
  221. # If DATA tags from a recent dlltool are present, honour them!
  222. - archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
  223. + archive_expsym_cmds='if test "x`head -n 1 $export_symbols`" = xEXPORTS; then
  224. cp $export_symbols $output_objdir/$soname-def;
  225. else
  226. echo EXPORTS > $output_objdir/$soname-def;
  227. --- ./ltcf-gcj.sh.orig 2004-04-27 08:14:30.000000000 +0200
  228. +++ ./ltcf-gcj.sh 2005-03-25 19:25:09.554617592 +0100
  229. @@ -156,7 +156,7 @@
  230. # If the export-symbols file already is a .def file (1st line
  231. # is EXPORTS), use it as is.
  232. # If DATA tags from a recent dlltool are present, honour them!
  233. - archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
  234. + archive_expsym_cmds='if test "x`head -n 1 $export_symbols`" = xEXPORTS; then
  235. cp $export_symbols $output_objdir/$soname-def;
  236. else
  237. echo EXPORTS > $output_objdir/$soname-def;