A C standard library for sh3eb-elf.
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.

src-release 11KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318
  1. # Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
  2. # 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation
  3. #
  4. # This file is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2 of the License, or
  7. # (at your option) any later version.
  8. #
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program; if not, write to the Free Software
  16. # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  17. #
  18. # This Makefile contains release scripts for gdb, binutils, and other
  19. # packages which live in src. It used to be part of the top level Makefile,
  20. # but that turned out to be very messy and hard to maintain.
  21. # This stuff really ought to be cleaned up and turned into something other
  22. # than a Makefile. As it is it's heavily recursive.
  23. # This is the name of this script (!). Needed due to horrible recursion.
  24. SELF = src-release
  25. SHELL = /bin/sh
  26. BZIPPROG = bzip2
  27. MD5PROG = md5sum
  28. # (Default to avoid splitting info files by setting the threshold high.)
  29. MAKEINFOFLAGS = --split-size=5000000
  30. # pwd command to use. Allow user to override default by setting PWDCMD in
  31. # the environment to account for automounters. The make variable must not
  32. # be called PWDCMD, otherwise the value set here is passed to make
  33. # subprocesses and overrides the setting from the user's environment.
  34. PWD = $${PWDCMD-pwd}
  35. #
  36. # Support for building net releases
  37. # Files in devo used in any net release.
  38. DEVO_SUPPORT= README Makefile.in configure configure.ac \
  39. config.guess config.sub config move-if-change \
  40. COPYING COPYING.LIB install-sh config-ml.in symlink-tree \
  41. mkinstalldirs ltmain.sh missing ylwrap \
  42. libtool.m4 ltsugar.m4 ltversion.m4 ltoptions.m4 \
  43. Makefile.def Makefile.tpl src-release config.rpath \
  44. ChangeLog MAINTAINERS README-maintainer-mode \
  45. lt~obsolete.m4 ltgcc.m4 depcomp mkdep compile \
  46. COPYING3 COPYING3.LIB
  47. # Files in devo/etc used in any net release.
  48. ETC_SUPPORT= Makefile.in configure configure.in standards.texi \
  49. make-stds.texi standards.info* configure.texi configure.info* \
  50. ChangeLog configbuild.* configdev.* fdl.texi texi2pod.pl gnu-oids.texi
  51. # When you use `make setup-dirs' or `make taz' you should always redefine
  52. # this macro.
  53. SUPPORT_FILES = list-of-support-files-for-tool-in-question
  54. # NOTE: No double quotes in the below. It is used within shell script
  55. # as VER="$(VER)"
  56. VER = ` if grep 'AM_INIT_AUTOMAKE.*BFD_VERSION' $(TOOL)/configure.in >/dev/null 2>&1; then \
  57. bfd/configure --version | sed -n -e '1s,.* ,,p'; \
  58. elif grep AM_INIT_AUTOMAKE $(TOOL)/configure.in >/dev/null 2>&1; then \
  59. sed < $(TOOL)/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'; \
  60. elif test -f $(TOOL)/common/create-version.sh; then \
  61. $(TOOL)/common/create-version.sh $(TOOL) \
  62. 'dummy-host' 'dummy-target' \
  63. VER.tmp; \
  64. cat VER.tmp | grep 'version\[\]' | sed 's/.*"\([^"]*\)".*/\1/' | sed 's/-cvs$$//'; \
  65. rm -f VER.tmp; \
  66. elif test -f $(TOOL)/version.in; then \
  67. head -1 $(TOOL)/version.in; \
  68. elif grep VERSION $(TOOL)/Makefile.in > /dev/null 2>&1; then \
  69. sed < $(TOOL)/Makefile.in -n 's/^VERSION *= *//p'; \
  70. else \
  71. echo VERSION; \
  72. fi`
  73. PACKAGE = $(TOOL)
  74. .PHONY: taz
  75. taz: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
  76. $(MAKE) -f $(SELF) do-proto-toplev \
  77. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  78. MD5PROG="$(MD5PROG)" \
  79. SUPPORT_FILES="$(SUPPORT_FILES)"
  80. $(MAKE) -f $(SELF) do-md5sum \
  81. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  82. MD5PROG="$(MD5PROG)" \
  83. SUPPORT_FILES="$(SUPPORT_FILES)"
  84. $(MAKE) -f $(SELF) do-tar \
  85. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  86. MD5PROG="$(MD5PROG)" \
  87. SUPPORT_FILES="$(SUPPORT_FILES)"
  88. $(MAKE) -f $(SELF) do-bz2 \
  89. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  90. MD5PROG="$(MD5PROG)" \
  91. SUPPORT_FILES="$(SUPPORT_FILES)"
  92. .PHONY: gdb-tar
  93. gdb-tar: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
  94. $(MAKE) -f $(SELF) do-proto-toplev \
  95. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  96. MD5PROG="$(MD5PROG)" \
  97. SUPPORT_FILES="$(SUPPORT_FILES)"
  98. $(MAKE) -f $(SELF) do-md5sum \
  99. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  100. MD5PROG="$(MD5PROG)" \
  101. SUPPORT_FILES="$(SUPPORT_FILES)"
  102. $(MAKE) -f $(SELF) do-djunpack \
  103. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  104. MD5PROG="$(MD5PROG)" \
  105. SUPPORT_FILES="$(SUPPORT_FILES)"
  106. $(MAKE) -f $(SELF) do-tar \
  107. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  108. MD5PROG="$(MD5PROG)" \
  109. SUPPORT_FILES="$(SUPPORT_FILES)"
  110. .PHONY: gdb-taz
  111. gdb-taz: gdb-tar $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
  112. $(MAKE) -f $(SELF) gdb-tar \
  113. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  114. MD5PROG="$(MD5PROG)" \
  115. SUPPORT_FILES="$(SUPPORT_FILES)"
  116. $(MAKE) -f $(SELF) do-bz2 \
  117. TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
  118. MD5PROG="$(MD5PROG)" \
  119. SUPPORT_FILES="$(SUPPORT_FILES)"
  120. .PHONY: do-proto-toplev
  121. do-proto-toplev: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
  122. echo "==> Making $(PACKAGE)-$(VER)/"
  123. # Take out texinfo from a few places.
  124. sed -e '/^all\.normal: /s/\all-texinfo //' \
  125. -e '/^ install-texinfo /d' \
  126. <Makefile.in >tmp
  127. mv -f tmp Makefile.in
  128. #
  129. ./configure i686-pc-linux-gnu
  130. $(MAKE) configure-host configure-target \
  131. ALL_GCC="" ALL_GCC_C="" ALL_GCC_CXX="" \
  132. CC_FOR_TARGET="$(CC)" CXX_FOR_TARGET="$(CXX)"
  133. # Make links, and run "make diststuff" or "make info" when needed.
  134. rm -rf proto-toplev ; mkdir proto-toplev
  135. set -e ; dirs="$(DEVO_SUPPORT) $(SUPPORT_FILES) $(TOOL)" ; \
  136. for d in $$dirs ; do \
  137. if [ -d $$d ]; then \
  138. if [ ! -f $$d/Makefile ] ; then true ; \
  139. elif grep '^diststuff:' $$d/Makefile >/dev/null ; then \
  140. (cd $$d ; $(MAKE) MAKEINFOFLAGS="$(MAKEINFOFLAGS)" \
  141. diststuff ) || exit 1 ; \
  142. elif grep '^info:' $$d/Makefile >/dev/null ; then \
  143. (cd $$d ; $(MAKE) MAKEINFOFLAGS="$(MAKEINFOFLAGS)" \
  144. info ) || exit 1 ; \
  145. fi ; \
  146. if [ -d $$d/proto-$$d.dir ]; then \
  147. ln -s ../$$d/proto-$$d.dir proto-toplev/$$d ; \
  148. else \
  149. ln -s ../$$d proto-toplev/$$d ; \
  150. fi ; \
  151. else \
  152. if (echo x$$d | grep / >/dev/null); then \
  153. mkdir -p proto-toplev/`dirname $$d` ; \
  154. x=`dirname $$d` ; \
  155. ln -s ../`echo $$x/ | sed -e 's,[^/]*/,../,g'`$$d proto-toplev/$$d ; \
  156. else \
  157. ln -s ../$$d proto-toplev/$$d ; \
  158. fi ; \
  159. fi ; \
  160. done
  161. cd etc && $(MAKE) MAKEINFOFLAGS="$(MAKEINFOFLAGS)" info
  162. $(MAKE) distclean
  163. # Kludge for pr gdb/857. intl/Makefile.in lacks a couple
  164. # of files in the distclean rule. Zack W is planning to make
  165. # the gcc version of intl/ the master version and then push
  166. # that version to src soon. See:
  167. # http://sources.redhat.com/ml/binutils/2003-07/msg00032.html
  168. # After the src version of intl/ is upgraded, we can look at
  169. # moving this logic into intl/Makefile.in distclean rule
  170. # if it is still needed. -- chastain 2003-09-12
  171. rm -f intl/config.cache
  172. rm -f intl/config.status
  173. rm -f intl/config.h
  174. rm -f intl/stamp-h
  175. #
  176. mkdir proto-toplev/etc
  177. (cd proto-toplev/etc; \
  178. for i in $(ETC_SUPPORT); do \
  179. ln -s ../../etc/$$i . ; \
  180. done)
  181. #
  182. # Take out texinfo from configurable dirs
  183. rm proto-toplev/configure.ac
  184. sed -e '/^host_tools=/s/texinfo //' \
  185. <configure.ac >proto-toplev/configure.ac
  186. #
  187. mkdir proto-toplev/texinfo
  188. ln -s ../../texinfo/texinfo.tex proto-toplev/texinfo/
  189. if test -r texinfo/util/tex3patch ; then \
  190. mkdir proto-toplev/texinfo/util && \
  191. ln -s ../../../texinfo/util/tex3patch proto-toplev/texinfo/util ; \
  192. else true; fi
  193. chmod -R og=u . || chmod og=u `find . -print`
  194. #
  195. # Create .gmo files from .po files.
  196. for f in `find . -name '*.po' -type f -print`; do \
  197. msgfmt -o `echo $$f | sed -e 's/\.po$$/.gmo/'` $$f ; \
  198. done
  199. #
  200. -rm -f $(PACKAGE)-$(VER)
  201. ln -s proto-toplev $(PACKAGE)-$(VER)
  202. CVS_NAMES= \( -name CVS -o -name '.cvsignore' \)
  203. .PHONY: do-tar
  204. do-tar:
  205. echo "==> Making $(PACKAGE)-$(VER).tar"
  206. -rm -f $(PACKAGE)-$(VER).tar
  207. find $(PACKAGE)-$(VER) -follow $(CVS_NAMES) -prune \
  208. -o -type f -print \
  209. | tar cTfh - $(PACKAGE)-$(VER).tar
  210. .PHONY: do-bz2
  211. do-bz2:
  212. echo "==> Bzipping $(PACKAGE)-$(VER).tar.bz2"
  213. -rm -f $(PACKAGE)-$(VER).tar.bz2
  214. $(BZIPPROG) -v -9 $(PACKAGE)-$(VER).tar
  215. .PHONY: do-md5sum
  216. do-md5sum:
  217. echo "==> Adding md5 checksum to top-level directory"
  218. cd proto-toplev && find * -follow $(CVS_NAMES) -prune \
  219. -o -type f -print \
  220. | xargs $(MD5PROG) > ../md5.new
  221. -rm -f proto-toplev/md5.sum
  222. mv md5.new proto-toplev/md5.sum
  223. .PHONY: do-djunpack
  224. do-djunpack:
  225. echo "==> Adding updated djunpack.bat to top-level directory"
  226. echo - 's /gdb-[0-9\.]*/$(PACKAGE)-'"$(VER)"'/'
  227. sed < djunpack.bat > djunpack.new \
  228. -e 's/gdb-[0-9][0-9\.]*/$(PACKAGE)-'"$(VER)"'/'
  229. -rm -f proto-toplev/djunpack.bat
  230. mv djunpack.new proto-toplev/djunpack.bat
  231. TEXINFO_SUPPORT= texinfo/texinfo.tex
  232. DIST_SUPPORT= $(DEVO_SUPPORT) $(TEXINFO_SUPPORT)
  233. .PHONY: gas.tar.bz2
  234. GAS_SUPPORT_DIRS= bfd include libiberty opcodes intl setup.com makefile.vms mkdep
  235. gas.tar.bz2: $(DIST_SUPPORT) $(GAS_SUPPORT_DIRS) gas
  236. $(MAKE) -f $(SELF) taz TOOL=gas \
  237. MD5PROG="$(MD5PROG)" \
  238. SUPPORT_FILES="$(GAS_SUPPORT_DIRS)"
  239. # The FSF "binutils" release includes gprof and ld.
  240. .PHONY: binutils.tar.bz2
  241. BINUTILS_SUPPORT_DIRS= bfd gas include libiberty opcodes ld elfcpp gold gprof intl setup.com makefile.vms cpu
  242. binutils.tar.bz2: $(DIST_SUPPORT) $(BINUTILS_SUPPORT_DIRS) binutils
  243. $(MAKE) -f $(SELF) taz TOOL=binutils \
  244. MD5PROG="$(MD5PROG)" \
  245. SUPPORT_FILES="$(BINUTILS_SUPPORT_DIRS)"
  246. .PHONY: gas+binutils.tar.bz2
  247. GASB_SUPPORT_DIRS= $(GAS_SUPPORT_DIRS) binutils ld gprof
  248. gas+binutils.tar.bz2: $(DIST_SUPPORT) $(GASB_SUPPORT_DIRS) gas
  249. $(MAKE) -f $(SELF) taz TOOL=gas \
  250. MD5PROG="$(MD5PROG)" \
  251. SUPPORT_FILES="$(GASB_SUPPORT_DIRS)"
  252. GNATS_SUPPORT_DIRS=include libiberty send-pr
  253. gnats.tar.bz2: $(DIST_SUPPORT) $(GNATS_SUPPORT_DIRS) gnats
  254. $(MAKE) -f $(SELF) taz TOOL=gnats \
  255. MD5PROG="$(MD5PROG)" \
  256. SUPPORT_FILES="$(GNATS_SUPPORT_DIRS)"
  257. .PHONY: gdb.tar.bz2
  258. GDB_SUPPORT_DIRS= bfd include libiberty opcodes readline sim intl libdecnumber cpu
  259. gdb.tar.bz2: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
  260. $(MAKE) -f $(SELF) gdb-taz TOOL=gdb \
  261. MD5PROG="$(MD5PROG)" \
  262. SUPPORT_FILES="$(GDB_SUPPORT_DIRS)"
  263. .PHONY: gdb.tar
  264. gdb.tar: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
  265. $(MAKE) -f $(SELF) gdb-tar TOOL=gdb \
  266. MD5PROG="$(MD5PROG)" \
  267. SUPPORT_FILES="$(GDB_SUPPORT_DIRS)"
  268. # Corresponding to the CVS "sim" module.
  269. .PHONY: sim.tar.bz2
  270. SIM_SUPPORT_DIRS= bfd opcodes libiberty include intl gdb/version.in makefile.vms
  271. sim.tar.bz2: $(DIST_SUPPORT) $(SIM_SUPPORT_DIRS) sim
  272. $(MAKE) -f $(SELF) taz TOOL=sim \
  273. MD5PROG="$(MD5PROG)" \
  274. SUPPORT_FILES="$(SIM_SUPPORT_DIRS)"
  275. .PHONY: insight.tar.bz2
  276. INSIGHT_SUPPORT_DIRS= $(GDB_SUPPORT_DIRS) tcl tk itcl libgui
  277. insight.tar.bz2: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
  278. $(MAKE) -f $(SELF) gdb-taz TOOL=gdb PACKAGE=insight \
  279. MD5PROG="$(MD5PROG)" \
  280. SUPPORT_FILES="$(INSIGHT_SUPPORT_DIRS)"
  281. .PHONY: insight.tar
  282. insight.tar: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
  283. $(MAKE) -f $(SELF) gdb-tar TOOL=gdb PACKAGE=insight \
  284. MD5PROG="$(MD5PROG)" \
  285. SUPPORT_FILES="$(INSIGHT_SUPPORT_DIRS)"
  286. .NOEXPORT:
  287. MAKEOVERRIDES=