Commit Graph

470 Commits

Author SHA1 Message Date
joerg fcd549e0e4 Retire old crtbegin/crtend implementation. It is not compatible with the
expectations of modern C++
2010-08-07 18:06:59 +00:00
joerg 01bc9d5012 Switch i386 and x86_64 to the new CRT layout. The crt0.c body is shared
between all platforms and a small assembler stub in crt0.S is used for
setting up the proper stack and whatever else MD needs.

Extract crti.S and crtn. from the old dot_init.h files. Prepare other
platforms that use the 6-argument form of __(_)start for this.

Rewrite the crtbegin and crtend modules in assembler to make them
compiler independent. Document the interface in README.
2010-08-07 18:01:32 +00:00
mrg 4f893703d8 delete all the a.out csu code. 2010-07-05 21:27:55 +00:00
matt 1e301281a1 Merge from matt-nb5-mips64 2009-12-14 01:00:46 +00:00
mrg 6b59d31236 move the include for <bsd.own.mk> down a little. 2009-12-13 08:52:38 +00:00
mrg cba14cb13e look for ${CSU_MACHINE_ARCH}_elf directory first. 2009-12-13 08:03:44 +00:00
skrll 7a915839ac Make lib/csu compile. XXX somewhat bogus. 2009-11-09 14:34:42 +00:00
christos ad57574aad strip .ident, if MKSTRIPIDENT. From Adam Ciarci 2009-02-18 15:21:52 +00:00
gmcgarry 3c9a95916d Wrap compiler-specific flags with HAVE_GCC and HAVE_PCC as necessary. Add a few flags for PCC. 2008-08-29 00:02:21 +00:00
lukem ae07e87382 Enable MAKEVERBOSE support. 2008-07-21 15:34:58 +00:00
gmcgarry 38541e9dad Remove old GCC bug work-around which relied on GCC extension. 2008-06-21 00:52:52 +00:00
mrg c2b95373bf remove clause #3 from my license where there are no other
copyright holders involved.
2008-05-29 14:51:25 +00:00
martin 5d1469bd77 Backout previous: the license sweep touched these files in error, so
restore the old license.
2008-05-10 15:31:03 +00:00
martin 3028e483e4 Convert to new 2 clause license 2008-04-29 06:53:00 +00:00
martin ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
rearnsha 00f0061ae9 ARM/Thumb interworking support 2008-03-15 10:46:24 +00:00
simonb ccab3b34ce Remove support for NetBSD/pc532. 2008-01-10 13:40:36 +00:00
skrll 587600728d Fix things so that crti.o doesn't contain a completely bogus unwind entry
that covers far too much and confuses gdb.

While here remove useless dave/restore of r4.
2007-12-02 13:55:38 +00:00
yamt c2ad33834a CLEANFILES=${OBJS} 2007-12-01 11:06:36 +00:00
yamt 82f3754f04 ___start: remove a stale comment. 2007-12-01 10:16:06 +00:00
skrll 6e57c35ead Remove an include that's not required. 2007-11-13 08:41:50 +00:00
dogcow b8d6c11ba4 <machine/profile.h> needs <sys/types.h>; why crt0.c needs <machine/profile.h>
(and only on amd64) is another question altogether.
2007-09-27 10:51:18 +00:00
skrll 795d937239 All platforms are MD_DO_NOT_NEED_FALLTHRU now so no need to keep it
conditional.
2007-05-15 16:51:37 +00:00
skrll c97173f648 MD_DO_NOT_NEED_FALLTHRU for amd64.
Thanks to Juan Romero Pardines for testing.
2007-05-15 16:48:13 +00:00
scw 5764a76889 Remove support for NetBSD/{,evb}sh5. 2007-04-08 09:35:21 +00:00
skrll bd529f8818 MD_DO_NOT_NEED_FALLTHRU for sh5. Compile tested only. 2007-03-31 21:12:37 +00:00
matt bbd7ce97e9 Didn't fix it completely. Now fixed. 2007-03-16 22:50:22 +00:00
matt 0cc8f96491 Use MD_DO_NOT_NEED_FALLTHRU 2007-03-16 22:20:50 +00:00
martin cc10b3e0c8 MD_DO_NOT_NEED_FALLTHRU - from Nick Hudson. 2007-01-02 14:32:34 +00:00
skrll 7e68cfaa21 powerpc MD_DO_NOT_NEED_FALLTHRU.
OK'ed by Matt Thomas.
2006-10-19 18:59:30 +00:00
skrll e99b876999 Alpha MD_DO_NOT_NEED_FALLTHRU
Ok'd by Matt Thomas.
2006-10-19 16:47:38 +00:00
martin 799bddf8fa MD_DO_NOT_NEED_FALLTHRU for sparc and sparc64, from Nick Hudson. 2006-10-19 08:37:46 +00:00
uwe e7b566fa33 Switch to MD_DO_NOT_NEED_FALLTHRU.
While here: Factor out .section/.previous wrapper into a separate macro.
Provide frame pointer.  Add the comment to MD_CALL_STATIC_FUNCTION to
explain why it needs semicolon and why we actually don't use that macro.
2006-10-17 01:10:26 +00:00
skrll b0b0343b24 ANSIfy 2006-09-15 05:29:44 +00:00
cherry 51b652e0e3 -DELFSIZE=64 for csu build 2006-09-14 23:55:54 +00:00
skrll 296c01bb4f MD_DO_NOT_NEED_FALLTHRU for hppa 2006-09-08 19:18:26 +00:00
skrll 61b77d1855 MD_DO_NOT_NEED_FALLTHRU for ARM. 2006-09-08 07:29:19 +00:00
skrll 44521a9e2e Implement MD_DO_NOT_NEED_FALLTHRU for i386.
Reviewed by christos.
2006-08-25 12:44:19 +00:00
skrll bc3a3e7751 Tidy up for MD_DO_NOT_NEED_FALLTHRU.
Discussed with cherry.
2006-07-18 21:18:23 +00:00
ross 7e22c74b0c Nothing from <machine/asm.h> is even used here, so don't include it.
This was the only place in the system where asm.h contents were seen
by the compiler and hence the only reason why asm.h had to conform
to C syntax. This previously limited asm.h to a cpp constructs and
comments.
2006-07-07 19:57:29 +00:00
ross ce3a138bcc add missing .globl's in new direct fallthru .init .fini 2006-07-06 22:31:55 +00:00
ross d0531274ae Conform to new world order where .init/.fini fallthru code
assembly appears directly inside _init().
2006-07-05 18:03:00 +00:00
cherry b8ee9baf67 First round at ia64 csu 2006-07-02 17:15:22 +00:00
ross 28dc42c889 fix comment 2006-07-01 01:39:17 +00:00
ross bbf630ab7c powerpc64 assembly for .init / .fini 2006-06-30 22:49:50 +00:00
simonb 842e180144 Remove the call to init_fallthru/fini_fallthru and call _init/_fini
directly for MIPS.  Making these global to keep gcc4 happy broke gcc3.
Shaves a few instructions off this path as well.

Other arches to follow with similar changes.

With much help from Nick Hudson.
2006-06-30 09:00:46 +00:00
mrg e487cf62f5 add a .globl to MD_SECTION_PROLOGUE so that the symbol is exported.
this fixes build problems with GCC4 (which will use smaller/faster call
methods for local/static functions) and is the right thing anyway.
2006-06-12 22:05:49 +00:00
mrg db19e89e04 remove support for building (with) GCC 2.95. also:
- always install <stdbool.h>
- don't generate a fake one for vax / gettext.
2006-06-02 22:16:18 +00:00
christos 351fa65664 Instead of using -I- -I${.CURDIR} and #include "dot_init.h", use:
-I${.CURDIR} and #include <dot_init.h>, since -I- is obsoleted in gcc-4,
and it is too confusing anyway.
2006-05-19 19:11:12 +00:00
christos 96473fa808 change __weak_extern to __weak_reference so that gcc4 works. 2006-05-18 17:54:19 +00:00