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.

643 lines
25 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/mnemoc/uclibc/patches/binutils-10-uclibc_arch_target.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. diff -udNr binutils-2.14.90.0.7.orig/bfd/config.bfd binutils-2.14.90.0.7/bfd/config.bfd
  20. --- binutils-2.14.90.0.7.orig/bfd/config.bfd 2004-02-07 10:54:27.000000000 -0300
  21. +++ binutils-2.14.90.0.7/bfd/config.bfd 2004-02-07 11:30:19.000000000 -0300
  22. @@ -121,7 +121,7 @@
  23. targ_defvec=ecoffalpha_little_vec
  24. targ_selvecs=bfd_elf64_alpha_vec
  25. ;;
  26. - alpha*-*-linux-gnu* | alpha*-*-elf*)
  27. + alpha*-*-linux-gnu* | alpha*-*-linux-uclibc* | alpha*-*-elf*)
  28. targ_defvec=bfd_elf64_alpha_vec
  29. targ_selvecs=ecoffalpha_little_vec
  30. ;;
  31. @@ -131,7 +131,8 @@
  32. alpha*-*-*)
  33. targ_defvec=ecoffalpha_little_vec
  34. ;;
  35. - ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu)
  36. + ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | \
  37. + ia64*-*-linux-uclibc* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu)
  38. targ_defvec=bfd_elf64_ia64_little_vec
  39. targ_selvecs="bfd_elf64_ia64_big_vec bfd_efi_app_ia64_vec"
  40. ;;
  41. @@ -214,7 +215,7 @@
  42. targ_defvec=bfd_elf32_littlearm_vec
  43. targ_selvecs=bfd_elf32_bigarm_vec
  44. ;;
  45. - armeb-*-elf | arm*b-*-linux-gnu*)
  46. + armeb-*-elf | arm*b-*-linux-gnu* | arm*b-*-linux-uclibc*)
  47. targ_defvec=bfd_elf32_bigarm_vec
  48. targ_selvecs=bfd_elf32_littlearm_vec
  49. ;;
  50. @@ -222,7 +223,8 @@
  51. targ_defvec=bfd_elf32_littlearm_vec
  52. targ_selvecs=bfd_elf32_bigarm_vec
  53. ;;
  54. - arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | arm*-*-uclinux* | arm-*-kfreebsd*-gnu)
  55. + arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-linux-uclibc* | \
  56. + arm*-*-conix* | arm*-*-uclinux* | arm-*-kfreebsd*-gnu)
  57. targ_defvec=bfd_elf32_littlearm_vec
  58. targ_selvecs=bfd_elf32_bigarm_vec
  59. ;;
  60. @@ -355,7 +357,7 @@
  61. ;;
  62. #ifdef BFD64
  63. - hppa*64*-*-linux-gnu*)
  64. + hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*)
  65. targ_defvec=bfd_elf64_hppa_linux_vec
  66. targ_selvecs=bfd_elf64_hppa_vec
  67. ;;
  68. @@ -366,7 +368,7 @@
  69. ;;
  70. #endif
  71. - hppa*-*-linux-gnu* | hppa*-*-netbsd*)
  72. + hppa*-*-linux-gnu* | hppa*-*-linux-uclibc* | hppa*-*-netbsd*)
  73. targ_defvec=bfd_elf32_hppa_linux_vec
  74. targ_selvecs=bfd_elf32_hppa_vec
  75. ;;
  76. @@ -488,7 +490,7 @@
  77. targ_selvecs=bfd_elf32_i386_vec
  78. targ_underscore=yes
  79. ;;
  80. - i[3-7]86-*-linux-gnu*)
  81. + i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*)
  82. targ_defvec=bfd_elf32_i386_vec
  83. targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec"
  84. targ64_selvecs=bfd_elf64_x86_64_vec
  85. @@ -502,7 +504,7 @@
  86. targ_defvec=bfd_elf64_x86_64_vec
  87. targ_selvecs="bfd_elf32_i386_vec i386netbsd_vec i386coff_vec bfd_efi_app_ia32_vec"
  88. ;;
  89. - x86_64-*-linux-gnu*)
  90. + x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*)
  91. targ_defvec=bfd_elf64_x86_64_vec
  92. targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec"
  93. ;;
  94. @@ -662,7 +664,7 @@
  95. targ_selvecs=bfd_elf32_m68k_vec
  96. targ_underscore=yes
  97. ;;
  98. - m68*-*-linux-gnu*)
  99. + m68*-*-linux-gnu* | m68*-*-linux-uclibc*)
  100. targ_defvec=bfd_elf32_m68k_vec
  101. targ_selvecs=m68klinux_vec
  102. ;;
  103. @@ -929,7 +931,8 @@
  104. ;;
  105. #endif
  106. powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \
  107. - powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-rtems* | \
  108. + powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-linux-uclibc* | \
  109. + powerpc-*-rtems* | \
  110. powerpc-*-chorus* | powerpc-*-vxworks* | powerpc-*-windiss*)
  111. targ_defvec=bfd_elf32_powerpc_vec
  112. targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec"
  113. @@ -961,8 +964,8 @@
  114. targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec"
  115. ;;
  116. powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \
  117. - powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-vxworks* |\
  118. - powerpcle-*-rtems*)
  119. + powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-linux-uclibc* |\
  120. + powerpcle-*-vxworks* | powerpcle-*-rtems*)
  121. targ_defvec=bfd_elf32_powerpcle_vec
  122. targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec"
  123. targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec"
  124. @@ -1110,7 +1113,7 @@
  125. targ_selvecs="bfd_elf32_sparc_vec sunos_big_vec"
  126. targ_underscore=yes
  127. ;;
  128. - sparc-*-linux-gnu*)
  129. + sparc-*-linux-gnu* | sparc-*-linux-uclibc*)
  130. targ_defvec=bfd_elf32_sparc_vec
  131. targ_selvecs="sparclinux_vec bfd_elf64_sparc_vec sunos_big_vec"
  132. ;;
  133. @@ -1157,7 +1160,7 @@
  134. targ_defvec=sunos_big_vec
  135. targ_underscore=yes
  136. ;;
  137. - sparc64-*-linux-gnu*)
  138. + sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*)
  139. targ_defvec=bfd_elf64_sparc_vec
  140. targ_selvecs="bfd_elf32_sparc_vec sparclinux_vec sunos_big_vec"
  141. ;;
  142. diff -udNr binutils-2.14.90.0.7.orig/bfd/configure binutils-2.14.90.0.7/bfd/configure
  143. --- binutils-2.14.90.0.7.orig/bfd/configure 2004-02-07 10:54:27.000000000 -0300
  144. +++ binutils-2.14.90.0.7/bfd/configure 2004-02-07 11:19:58.000000000 -0300
  145. @@ -1699,6 +1699,11 @@
  146. lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
  147. ;;
  148. +linux-uclibc*)
  149. + lt_cv_deplibs_check_method=pass_all
  150. + lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
  151. + ;;
  152. +
  153. netbsd*)
  154. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  155. lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
  156. @@ -5278,7 +5283,7 @@
  157. alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
  158. COREFILE=''
  159. ;;
  160. - alpha*-*-linux-gnu*)
  161. + alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*)
  162. COREFILE=trad-core.lo
  163. TRAD_HEADER='"hosts/alphalinux.h"'
  164. ;;
  165. @@ -5338,7 +5343,7 @@
  166. COREFILE=trad-core.lo
  167. TRAD_HEADER='"hosts/i386mach3.h"'
  168. ;;
  169. - i[3-7]86-*-linux-gnu*)
  170. + i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*)
  171. COREFILE=trad-core.lo
  172. TRAD_HEADER='"hosts/i386linux.h"'
  173. ;;
  174. @@ -5388,7 +5393,7 @@
  175. COREFILE=trad-core.lo
  176. TRAD_HEADER='"hosts/hp300bsd.h"'
  177. ;;
  178. - m68*-*-linux-gnu*)
  179. + m68*-*-linux-gnu* | m68*-*-linux-uclibc*)
  180. COREFILE=trad-core.lo
  181. TRAD_HEADER='"hosts/m68klinux.h"'
  182. ;;
  183. diff -udNr binutils-2.14.90.0.7.orig/bfd/configure.in binutils-2.14.90.0.7/bfd/configure.in
  184. --- binutils-2.14.90.0.7.orig/bfd/configure.in 2004-02-07 10:54:27.000000000 -0300
  185. +++ binutils-2.14.90.0.7/bfd/configure.in 2004-02-07 11:19:55.000000000 -0300
  186. @@ -178,7 +178,7 @@
  187. alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
  188. COREFILE=''
  189. ;;
  190. - alpha*-*-linux-gnu*)
  191. + alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*)
  192. COREFILE=trad-core.lo
  193. TRAD_HEADER='"hosts/alphalinux.h"'
  194. ;;
  195. @@ -259,7 +259,7 @@
  196. TRAD_HEADER='"hosts/i386mach3.h"'
  197. ;;
  198. changequote(,)dnl
  199. - i[3-7]86-*-linux-gnu*)
  200. + i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*)
  201. changequote([,])dnl
  202. COREFILE=trad-core.lo
  203. TRAD_HEADER='"hosts/i386linux.h"'
  204. @@ -312,7 +312,7 @@
  205. COREFILE=trad-core.lo
  206. TRAD_HEADER='"hosts/hp300bsd.h"'
  207. ;;
  208. - m68*-*-linux-gnu*)
  209. + m68*-*-linux-gnu* | m68*-*-linux-uclibc*)
  210. COREFILE=trad-core.lo
  211. TRAD_HEADER='"hosts/m68klinux.h"'
  212. ;;
  213. diff -udNr binutils-2.14.90.0.7.orig/configure binutils-2.14.90.0.7/configure
  214. --- binutils-2.14.90.0.7.orig/configure 2004-02-07 10:54:30.000000000 -0300
  215. +++ binutils-2.14.90.0.7/configure 2004-02-07 10:58:38.000000000 -0300
  216. @@ -1276,6 +1276,18 @@
  217. i[3456789]86-*-freebsd* | i[3456789]86-*-kfreebsd*-gnu)
  218. noconfigdirs="$noconfigdirs target-newlib target-libgloss"
  219. ;;
  220. + i[3456789]86-*-linux-uclibc)
  221. + # This section makes it possible to build newlib natively on linux.
  222. + # If we are using a cross compiler then don't configure newlib.
  223. + if test x${is_cross_compiler} != xno ; then
  224. + noconfigdirs="$noconfigdirs target-newlib"
  225. + fi
  226. + noconfigdirs="$noconfigdirs target-libgloss"
  227. + # If we are not using a cross compiler, do configure newlib.
  228. + # Note however, that newlib will only be configured in this situation
  229. + # if the --with-newlib option has been given, because otherwise
  230. + # 'target-newlib' will appear in skipdirs.
  231. + ;;
  232. i[3456789]86-*-linux*)
  233. # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
  234. # not build java stuff by default.
  235. diff -udNr binutils-2.14.90.0.7.orig/configure.in binutils-2.14.90.0.7/configure.in
  236. --- binutils-2.14.90.0.7.orig/configure.in 2004-02-07 10:54:30.000000000 -0300
  237. +++ binutils-2.14.90.0.7/configure.in 2004-02-07 10:58:41.000000000 -0300
  238. @@ -515,6 +515,19 @@
  239. i[[3456789]]86-*-freebsd* | i[[3456789]]86-*-kfreebsd*-gnu)
  240. noconfigdirs="$noconfigdirs target-newlib target-libgloss"
  241. ;;
  242. + i[3456789]86-*-linux-uclibc)
  243. + # This section makes it possible to build newlib natively on linux.
  244. + # If we are using a cross compiler then don't configure newlib.
  245. + if test x${is_cross_compiler} != xno ; then
  246. + noconfigdirs="$noconfigdirs target-newlib"
  247. + fi
  248. + noconfigdirs="$noconfigdirs target-libgloss"
  249. + build_modules=
  250. + # If we are not using a cross compiler, do configure newlib.
  251. + # Note however, that newlib will only be configured in this situation
  252. + # if the --with-newlib option has been given, because otherwise
  253. + # 'target-newlib' will appear in skipdirs.
  254. + ;;
  255. i[[3456789]]86-*-linux*)
  256. # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
  257. # not build java stuff by default.
  258. diff -udNr binutils-2.14.90.0.7.orig/demangler/configure binutils-2.14.90.0.7/demangler/configure
  259. --- binutils-2.14.90.0.7.orig/demangler/configure 2004-02-07 10:54:30.000000000 -0300
  260. +++ binutils-2.14.90.0.7/demangler/configure 2004-02-07 11:19:22.000000000 -0300
  261. @@ -1380,6 +1380,11 @@
  262. lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
  263. ;;
  264. +linux-uclibc*)
  265. + lt_cv_deplibs_check_method=pass_all
  266. + lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
  267. + ;;
  268. +
  269. netbsd*)
  270. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  271. lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
  272. diff -udNr binutils-2.14.90.0.7.orig/gas/configure binutils-2.14.90.0.7/gas/configure
  273. --- binutils-2.14.90.0.7.orig/gas/configure 2004-02-07 10:54:27.000000000 -0300
  274. +++ binutils-2.14.90.0.7/gas/configure 2004-02-07 11:12:45.000000000 -0300
  275. @@ -3215,6 +3215,11 @@
  276. lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
  277. ;;
  278. +linux-uclibc*)
  279. + lt_cv_deplibs_check_method=pass_all
  280. + lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
  281. + ;;
  282. +
  283. netbsd*)
  284. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  285. lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
  286. @@ -4028,6 +4033,7 @@
  287. alpha*-*-osf*) fmt=ecoff ;;
  288. alpha*-*-linuxecoff*) fmt=ecoff ;;
  289. alpha*-*-linux-gnu*) fmt=elf em=linux ;;
  290. + alpha*-*-linux-uclibc*) fmt=elf em=linux ;;
  291. alpha*-*-netbsd*) fmt=elf em=nbsd ;;
  292. alpha*-*-openbsd*) fmt=elf em=obsd ;;
  293. @@ -4044,6 +4050,7 @@
  294. arm*-*-conix*) fmt=elf ;;
  295. arm-*-linux*aout*) fmt=aout em=linux ;;
  296. arm*-*-linux-gnu*) fmt=elf em=linux ;;
  297. + arm*-*-linux-uclibc*) fmt=elf em=linux ;;
  298. arm*-*-uclinux*) fmt=elf em=linux ;;
  299. arm-*-netbsdelf*) fmt=elf em=nbsd ;;
  300. arm-*-*n*bsd*) fmt=aout em=nbsd ;;
  301. @@ -4058,6 +4065,7 @@
  302. avr-*-*) fmt=elf ;;
  303. cris-*-linux-gnu*) fmt=multi bfd_gas=yes em=linux ;;
  304. + cris-*-linux-uclibc*) fmt=multi bfd_gas=yes em=linux ;;
  305. cris-*-*) fmt=multi bfd_gas=yes ;;
  306. d10v-*-*) fmt=elf ;;
  307. @@ -4114,7 +4122,9 @@
  308. i386-*-linux*oldld) fmt=aout em=linux ;;
  309. i386-*-linux*coff*) fmt=coff em=linux ;;
  310. i386-*-linux-gnu*) fmt=elf em=linux ;;
  311. + i386-*-linux-uclibc*) fmt=elf em=linux ;;
  312. x86_64-*-linux-gnu*) fmt=elf em=linux ;;
  313. + x86_64-*-linux-uclibc*) fmt=elf em=linux ;;
  314. i386-*-lynxos*) fmt=coff em=lynx ;;
  315. i386-*-sysv[45]*) fmt=elf ;;
  316. i386-*-solaris*) fmt=elf ;;
  317. @@ -4175,6 +4185,7 @@
  318. ia64-*-elf*) fmt=elf ;;
  319. ia64-*-aix*) fmt=elf em=ia64aix ;;
  320. ia64-*-linux-gnu*) fmt=elf em=linux ;;
  321. + ia64-*-linux-uclibc*) fmt=elf em=linux ;;
  322. ia64-*-hpux*) fmt=elf em=hpux ;;
  323. ia64-*-netbsd*) fmt=elf em=nbsd ;;
  324. @@ -4201,6 +4212,7 @@
  325. m68k-*-hpux*) fmt=hp300 em=hp300 ;;
  326. m68k-*-linux*aout*) fmt=aout em=linux ;;
  327. m68k-*-linux-gnu*) fmt=elf em=linux ;;
  328. + m68k-*-linux-uclibc*) fmt=elf em=linux ;;
  329. m68k-*-gnu*) fmt=elf ;;
  330. m68k-*-lynxos*) fmt=coff em=lynx ;;
  331. m68k-*-netbsdelf*) fmt=elf em=nbsd ;;
  332. @@ -4257,6 +4269,7 @@
  333. ppc-*-beos*) fmt=coff ;;
  334. ppc-*-*n*bsd* | ppc-*-elf*) fmt=elf ;;
  335. ppc-*-eabi* | ppc-*-sysv4*) fmt=elf ;;
  336. + ppc-*-linux-uclibc* | \
  337. ppc-*-linux-gnu*) fmt=elf em=linux
  338. case "$endian" in
  339. big) ;;
  340. @@ -4286,7 +4299,9 @@
  341. ppc-*-kaos*) fmt=elf ;;
  342. s390x-*-linux-gnu*) fmt=elf em=linux ;;
  343. + s390x-*-linux-uclibc*) fmt=elf em=linux ;;
  344. s390-*-linux-gnu*) fmt=elf em=linux ;;
  345. + s390-*-linux-uclibc*) fmt=elf em=linux ;;
  346. sh*-*-linux*) fmt=elf em=linux
  347. case ${cpu} in
  348. @@ -4319,6 +4334,7 @@
  349. sparc-*-coff) fmt=coff ;;
  350. sparc-*-linux*aout*) fmt=aout em=linux ;;
  351. sparc-*-linux-gnu*) fmt=elf em=linux ;;
  352. + sparc-*-linux-uclibc*) fmt=elf em=linux ;;
  353. sparc-*-lynxos*) fmt=coff em=lynx ;;
  354. sparc-fujitsu-none) fmt=aout ;;
  355. sparc-*-elf) fmt=elf ;;
  356. diff -udNr binutils-2.14.90.0.7.orig/gas/configure.in binutils-2.14.90.0.7/gas/configure.in
  357. --- binutils-2.14.90.0.7.orig/gas/configure.in 2004-02-07 10:54:27.000000000 -0300
  358. +++ binutils-2.14.90.0.7/gas/configure.in 2004-02-07 11:16:53.000000000 -0300
  359. @@ -192,6 +192,7 @@
  360. alpha*-*-osf*) fmt=ecoff ;;
  361. alpha*-*-linuxecoff*) fmt=ecoff ;;
  362. alpha*-*-linux-gnu*) fmt=elf em=linux ;;
  363. + alpha*-*-linux-uclibc*) fmt=elf em=linux ;;
  364. alpha*-*-netbsd*) fmt=elf em=nbsd ;;
  365. alpha*-*-openbsd*) fmt=elf em=obsd ;;
  366. @@ -208,6 +209,7 @@
  367. arm*-*-conix*) fmt=elf ;;
  368. arm-*-linux*aout*) fmt=aout em=linux ;;
  369. arm*-*-linux-gnu*) fmt=elf em=linux ;;
  370. + arm*-*-linux-uclibc*) fmt=elf em=linux ;;
  371. arm*-*-uclinux*) fmt=elf em=linux ;;
  372. arm-*-netbsdelf*) fmt=elf em=nbsd ;;
  373. arm-*-*n*bsd*) fmt=aout em=nbsd ;;
  374. @@ -222,6 +224,7 @@
  375. avr-*-*) fmt=elf ;;
  376. cris-*-linux-gnu*) fmt=multi bfd_gas=yes em=linux ;;
  377. + cris-*-linux-uclibc*) fmt=multi bfd_gas=yes em=linux ;;
  378. cris-*-*) fmt=multi bfd_gas=yes ;;
  379. d10v-*-*) fmt=elf ;;
  380. @@ -278,7 +281,9 @@
  381. i386-*-linux*oldld) fmt=aout em=linux ;;
  382. i386-*-linux*coff*) fmt=coff em=linux ;;
  383. i386-*-linux-gnu*) fmt=elf em=linux ;;
  384. + i386-*-linux-uclibc*) fmt=elf em=linux ;;
  385. x86_64-*-linux-gnu*) fmt=elf em=linux ;;
  386. + x86_64-*-linux-uclibc*) fmt=elf em=linux ;;
  387. i386-*-lynxos*) fmt=coff em=lynx ;;
  388. changequote(,)dnl
  389. i386-*-sysv[45]*) fmt=elf ;;
  390. @@ -332,6 +337,7 @@
  391. ia64-*-elf*) fmt=elf ;;
  392. ia64-*-aix*) fmt=elf em=ia64aix ;;
  393. ia64-*-linux-gnu*) fmt=elf em=linux ;;
  394. + ia64-*-linux-uclibc*) fmt=elf em=linux ;;
  395. ia64-*-hpux*) fmt=elf em=hpux ;;
  396. ia64-*-netbsd*) fmt=elf em=nbsd ;;
  397. @@ -358,6 +364,7 @@
  398. m68k-*-hpux*) fmt=hp300 em=hp300 ;;
  399. m68k-*-linux*aout*) fmt=aout em=linux ;;
  400. m68k-*-linux-gnu*) fmt=elf em=linux ;;
  401. + m68k-*-linux-uclibc*) fmt=elf em=linux ;;
  402. m68k-*-gnu*) fmt=elf ;;
  403. m68k-*-lynxos*) fmt=coff em=lynx ;;
  404. m68k-*-netbsdelf*) fmt=elf em=nbsd ;;
  405. @@ -412,6 +419,7 @@
  406. ppc-*-beos*) fmt=coff ;;
  407. ppc-*-*n*bsd* | ppc-*-elf*) fmt=elf ;;
  408. ppc-*-eabi* | ppc-*-sysv4*) fmt=elf ;;
  409. + ppc-*-linux-uclibc* | \
  410. ppc-*-linux-gnu*) fmt=elf em=linux
  411. case "$endian" in
  412. big) ;;
  413. @@ -434,7 +442,9 @@
  414. ppc-*-kaos*) fmt=elf ;;
  415. s390x-*-linux-gnu*) fmt=elf em=linux ;;
  416. + s390x-*-linux-uclibc*) fmt=elf em=linux ;;
  417. s390-*-linux-gnu*) fmt=elf em=linux ;;
  418. + s390-*-linux-uclibc*) fmt=elf em=linux ;;
  419. sh*-*-linux*) fmt=elf em=linux
  420. case ${cpu} in
  421. @@ -467,6 +477,7 @@
  422. sparc-*-coff) fmt=coff ;;
  423. sparc-*-linux*aout*) fmt=aout em=linux ;;
  424. sparc-*-linux-gnu*) fmt=elf em=linux ;;
  425. + sparc-*-linux-uclibc*) fmt=elf em=linux ;;
  426. sparc-*-lynxos*) fmt=coff em=lynx ;;
  427. sparc-fujitsu-none) fmt=aout ;;
  428. sparc-*-elf) fmt=elf ;;
  429. diff -udNr binutils-2.14.90.0.7.orig/ld/configure binutils-2.14.90.0.7/ld/configure
  430. --- binutils-2.14.90.0.7.orig/ld/configure 2004-02-07 10:54:26.000000000 -0300
  431. +++ binutils-2.14.90.0.7/ld/configure 2004-02-07 11:02:23.000000000 -0300
  432. @@ -1578,6 +1578,11 @@
  433. lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
  434. ;;
  435. +linux-uclibc*)
  436. + lt_cv_deplibs_check_method=pass_all
  437. + lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
  438. + ;;
  439. +
  440. netbsd*)
  441. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  442. lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
  443. diff -udNr binutils-2.14.90.0.7.orig/ld/configure.tgt binutils-2.14.90.0.7/ld/configure.tgt
  444. --- binutils-2.14.90.0.7.orig/ld/configure.tgt 2004-02-07 10:54:26.000000000 -0300
  445. +++ binutils-2.14.90.0.7/ld/configure.tgt 2004-02-07 11:02:19.000000000 -0300
  446. @@ -30,6 +30,7 @@
  447. targ_extra_emuls="criself crislinux"
  448. targ_extra_libpath=$targ_extra_emuls ;;
  449. cris-*-linux-gnu*) targ_emul=crislinux ;;
  450. +cris-*-linux-uclibc*) targ_emul=crislinux ;;
  451. cris-*-*) targ_emul=criself
  452. targ_extra_emuls="crisaout crislinux"
  453. targ_extra_libpath=$targ_extra_emuls ;;
  454. @@ -59,14 +60,16 @@
  455. tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/aout//'`
  456. tdir_sun4=sparc-sun-sunos4
  457. ;;
  458. -sparc64-*-linux-gnu*) targ_emul=elf64_sparc
  459. +sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) \
  460. + targ_emul=elf64_sparc
  461. targ_extra_emuls="elf32_sparc sparclinux sun4"
  462. targ_extra_libpath=elf32_sparc
  463. tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'`
  464. tdir_sparclinux=${tdir_elf32_sparc}aout
  465. tdir_sun4=sparc-sun-sunos4
  466. ;;
  467. -sparc*-*-linux-gnu*) targ_emul=elf32_sparc
  468. +sparc*-*-linux-gnu* | sparc*-*-linux-gnu*) \
  469. + targ_emul=elf32_sparc
  470. targ_extra_emuls="sparclinux elf64_sparc sun4"
  471. targ_extra_libpath=elf64_sparc
  472. tdir_sparclinux=${targ_alias}aout
  473. @@ -125,7 +128,7 @@
  474. m68*-ericsson-ose) targ_emul=sun3 ;;
  475. m68*-apple-aux*) targ_emul=m68kaux ;;
  476. *-tandem-none) targ_emul=st2000 ;;
  477. -i370-*-elf* | i370-*-linux-gnu*) targ_emul=elf32i370 ;;
  478. +i370-*-elf* | i370-*-linux-gnu* | i370-*-linux-uclibc*) targ_emul=elf32i370 ;;
  479. i[3-7]86-*-nto-qnx*) targ_emul=i386nto ;;
  480. i[3-7]86-*-vsta) targ_emul=vsta ;;
  481. i[3-7]86-go32-rtems*) targ_emul=i386go32 ;;
  482. @@ -149,14 +152,16 @@
  483. tdir_elf_i386=`echo ${targ_alias} | sed -e 's/aout//'`
  484. ;;
  485. i[3-7]86-*-linux*oldld) targ_emul=i386linux; targ_extra_emuls=elf_i386 ;;
  486. -i[3-7]86-*-linux-gnu*) targ_emul=elf_i386
  487. +i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) \
  488. + targ_emul=elf_i386
  489. targ_extra_emuls=i386linux
  490. if test x${want64} = xtrue; then
  491. targ_extra_emuls="$targ_extra_emuls elf_x86_64"
  492. fi
  493. tdir_i386linux=${targ_alias}aout
  494. ;;
  495. -x86_64-*-linux-gnu*) targ_emul=elf_x86_64
  496. +x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) \
  497. + targ_emul=elf_x86_64
  498. targ_extra_emuls="elf_i386 i386linux"
  499. targ_extra_libpath=elf_i386
  500. tdir_i386linux=`echo ${targ_alias}aout | sed -e 's/x86_64/i386/'`
  501. @@ -256,10 +261,13 @@
  502. arm9e-*-elf) targ_emul=armelf ;;
  503. arm-*-oabi) targ_emul=armelf_oabi ;;
  504. arm*b-*-linux-gnu*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;;
  505. +arm*b-*-linux-uclibc*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;;
  506. arm*-*-linux-gnu*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
  507. +arm*-*-linux-uclibc*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
  508. arm*-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
  509. arm*-*-conix*) targ_emul=armelf ;;
  510. -thumb-*-linux-gnu* | thumb-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
  511. +thumb-*-linux-gnu* | thumb-*-linux-uclibc* | thumb-*-uclinux*) \
  512. + targ_emul=armelf_linux; targ_extra_emuls=armelf ;;
  513. strongarm-*-coff) targ_emul=armcoff ;;
  514. strongarm-*-elf) targ_emul=armelf ;;
  515. strongarm-*-kaos*) targ_emul=armelf ;;
  516. @@ -360,7 +368,8 @@
  517. targ_extra_emuls=m68kelf
  518. tdir_m68kelf=`echo ${targ_alias} | sed -e 's/aout//'`
  519. ;;
  520. -m68k-*-linux-gnu*) targ_emul=m68kelf
  521. +m68k-*-linux-gnu* | m68k-*-linux-uclibc*) \
  522. + targ_emul=m68kelf
  523. targ_extra_emuls=m68klinux
  524. tdir_m68klinux=`echo ${targ_alias} | sed -e 's/linux/linuxaout/'`
  525. ;;
  526. @@ -376,9 +385,9 @@
  527. m68*-*-psos*) targ_emul=m68kpsos ;;
  528. m68*-*-rtemscoff*) targ_emul=m68kcoff ;;
  529. m68*-*-rtems*) targ_emul=m68kelf ;;
  530. -hppa*64*-*-linux-gnu*) targ_emul=hppa64linux ;;
  531. +hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) targ_emul=hppa64linux ;;
  532. hppa*64*-*) targ_emul=elf64hppa ;;
  533. -hppa*-*-linux-gnu*) targ_emul=hppalinux ;;
  534. +hppa*-*-linux-gnu* | hppa*-*-linux-uclibc*) targ_emul=hppalinux ;;
  535. hppa*-*-*elf*) targ_emul=hppaelf ;;
  536. hppa*-*-lites*) targ_emul=hppaelf ;;
  537. hppa*-*-netbsd*) targ_emul=hppanbsd ;;
  538. @@ -422,16 +431,20 @@
  539. mips*-*-rtems*) targ_emul=elf32ebmip ;;
  540. mips*el-*-vxworks*) targ_emul=elf32elmip ;;
  541. mips*-*-vxworks*) targ_emul=elf32ebmip ;;
  542. -mips64*el-*-linux-gnu*) targ_emul=elf32ltsmipn32
  543. +mips64*el-*-linux-gnu* | mips64*el-*-linux-uclibc*) \
  544. + targ_emul=elf32ltsmipn32
  545. targ_extra_emuls="elf32btsmipn32 elf32ltsmip elf32btsmip elf64ltsmip elf64btsmip"
  546. ;;
  547. -mips64*-*-linux-gnu*) targ_emul=elf32btsmipn32
  548. +mips64*-*-linux-gnu* | mips64*-*-linux-uclibc*) \
  549. + targ_emul=elf32btsmipn32
  550. targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip"
  551. ;;
  552. -mips*el-*-linux-gnu*) targ_emul=elf32ltsmip
  553. +mips*el-*-linux-gnu* | mips*el-*-linux-uclibc*) \
  554. + targ_emul=elf32ltsmip
  555. targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
  556. ;;
  557. -mips*-*-linux-gnu*) targ_emul=elf32btsmip
  558. +mips*-*-linux-gnu* | mips*-*-linux-uclibc*) \
  559. + targ_emul=elf32btsmip
  560. targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip"
  561. ;;
  562. mips*-*-lnews*) targ_emul=mipslnews ;;
  563. @@ -454,6 +467,10 @@
  564. alpha*-*-linux-gnu*) targ_emul=elf64alpha targ_extra_emuls=alpha
  565. tdir_alpha=`echo ${targ_alias} | sed -e 's/linux/linuxecoff/'`
  566. ;;
  567. +alpha*-*-linux-uclibc*) targ_emul=elf64alpha targ_extra_emuls=alpha
  568. + # The following needs to be checked...
  569. + tdir_alpha=`echo ${targ_alias} | sed -e 's/linux/linuxecoff/'`
  570. + ;;
  571. alpha*-*-osf*) targ_emul=alpha ;;
  572. alpha*-*-gnu*) targ_emul=elf64alpha ;;
  573. alpha*-*-netware*) targ_emul=alpha ;;
  574. diff -udNr binutils-2.14.90.0.7.orig/libtool.m4 binutils-2.14.90.0.7/libtool.m4
  575. --- binutils-2.14.90.0.7.orig/libtool.m4 2004-02-07 10:54:30.000000000 -0300
  576. +++ binutils-2.14.90.0.7/libtool.m4 2004-02-07 11:00:54.000000000 -0300
  577. @@ -645,6 +645,11 @@
  578. lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
  579. ;;
  580. +linux-uclibc*)
  581. + lt_cv_deplibs_check_method=pass_all
  582. + lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
  583. + ;;
  584. +
  585. netbsd*)
  586. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  587. [lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$']
  588. diff -udNr binutils-2.14.90.0.7.orig/ltconfig binutils-2.14.90.0.7/ltconfig
  589. --- binutils-2.14.90.0.7.orig/ltconfig 2004-02-07 10:54:30.000000000 -0300
  590. +++ binutils-2.14.90.0.7/ltconfig 2004-02-07 11:01:00.000000000 -0300
  591. @@ -603,6 +603,7 @@
  592. # Transform linux* to *-*-linux-gnu*, to support old configure scripts.
  593. case $host_os in
  594. linux-gnu*) ;;
  595. +linux-uclibc*) ;;
  596. linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
  597. esac
  598. @@ -1259,6 +1260,24 @@
  599. dynamic_linker='GNU/Linux ld.so'
  600. ;;
  601. +linux-uclibc*)
  602. + version_type=linux
  603. + need_lib_prefix=no
  604. + need_version=no
  605. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  606. + soname_spec='${libname}${release}.so$major'
  607. + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
  608. + shlibpath_var=LD_LIBRARY_PATH
  609. + shlibpath_overrides_runpath=no
  610. + # This implies no fast_install, which is unacceptable.
  611. + # Some rework will be needed to allow for fast_install
  612. + # before this can be enabled.
  613. + # Note: copied from linux-gnu, and may not be appropriate.
  614. + hardcode_into_libs=yes
  615. + # Assume using the uClibc dynamic linker.
  616. + dynamic_linker="uClibc ld.so"
  617. + ;;
  618. +
  619. netbsd*)
  620. need_lib_prefix=no
  621. need_version=no