Commit Graph

6 Commits

Author SHA1 Message Date
John Baldwin
9ebe945bd7 Add C startup code tests for PIE binaries.
- Force dynamic to be a non-PIE binary.

- Add a dynamicpie test which uses a PIE binary.

Reviewed by:	andrew
Obtained from:	CheriBSD
MFC after:	2 weeks
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D27127
2020-11-10 19:09:35 +00:00
Ed Maste
6871d48825 Add explicit csu test dependency
lib/csu/tests/dynamiclib requires libh_csu.so be built first.  I'm not
sure this is the most correct/best way to address this but it solves
the issue in my testing.

PR:		233734
Sponsored by:	The FreeBSD Foundation
2019-01-04 18:35:25 +00:00
Andrew Turner
266900be14 Re-enable the dynamiclib tests. These should be fixed by r340910. 2018-11-24 18:25:00 +00:00
Andrew Turner
ab1e0d2410 Disable the dynamiclib test until a failure can be debugged 2018-11-24 16:05:40 +00:00
Andrew Turner
6ec0ee844c Run the csu tests on a DSO. This builds the tests into a shared library,
then runs these from the base test programs. With this we can check
crtbeginS.o and crtendS.o are working as expected.

MFC with:	r339738
Sponsored by:	DARPA, AFRL
2018-10-30 09:43:26 +00:00
Andrew Turner
31d62a73c2 Implement a BSD licensed crtbegin/crtend
These are needed for .ctors/.dtors and .jcr handling. The former needs
all the function pointers to be called in the correct order from the
.init/.fini section. The latter just needs to call a gcj specific function
if it exists with a pointer to the start of the .jcr section.

This is currently disabled until __dso_handle support is added.

Reviewed by:	emaste
MFC after:	1 month
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D17587
2018-10-25 17:39:41 +00:00