diff options
Diffstat (limited to 'libexec')
-rw-r--r-- | libexec/Makefile | 2 | ||||
-rw-r--r-- | libexec/atf/atf-check/Makefile | 1 | ||||
-rw-r--r-- | libexec/ftpd/Makefile | 2 | ||||
-rw-r--r-- | libexec/rlogind/Makefile | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/Makefile | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/Symbol.map | 1 | ||||
-rw-r--r-- | libexec/rtld-elf/rtld.c | 17 | ||||
-rw-r--r-- | libexec/tcpd/Makefile | 2 | ||||
-rw-r--r-- | libexec/telnetd/Makefile | 2 |
9 files changed, 24 insertions, 7 deletions
diff --git a/libexec/Makefile b/libexec/Makefile index e087a8a..8a32694 100644 --- a/libexec/Makefile +++ b/libexec/Makefile @@ -1,7 +1,7 @@ # @(#)Makefile 8.1 (Berkeley) 6/4/93 # $FreeBSD$ -.include <bsd.own.mk> +.include <src.opts.mk> SUBDIR= ${_atf} \ ${_atrun} \ diff --git a/libexec/atf/atf-check/Makefile b/libexec/atf/atf-check/Makefile index 0cfa863..093de06 100644 --- a/libexec/atf/atf-check/Makefile +++ b/libexec/atf/atf-check/Makefile @@ -25,6 +25,7 @@ # # $FreeBSD$ +.include <src.opts.mk> .include <bsd.init.mk> ATF= ${.CURDIR:H:H:H}/contrib/atf diff --git a/libexec/ftpd/Makefile b/libexec/ftpd/Makefile index e415407f..0c7c982 100644 --- a/libexec/ftpd/Makefile +++ b/libexec/ftpd/Makefile @@ -1,7 +1,7 @@ # @(#)Makefile 8.2 (Berkeley) 4/4/94 # $FreeBSD$ -.include <bsd.own.mk> +.include <src.opts.mk> PROG= ftpd MAN= ftpd.8 ftpchroot.5 diff --git a/libexec/rlogind/Makefile b/libexec/rlogind/Makefile index 9807dc8..de0fb20 100644 --- a/libexec/rlogind/Makefile +++ b/libexec/rlogind/Makefile @@ -1,7 +1,7 @@ # @(#)Makefile 8.1 (Berkeley) 6/4/93 # $FreeBSD$ -.include <bsd.own.mk> +.include <src.opts.mk> PROG= rlogind MAN= rlogind.8 diff --git a/libexec/rtld-elf/Makefile b/libexec/rtld-elf/Makefile index 2a0953c..21e2219 100644 --- a/libexec/rtld-elf/Makefile +++ b/libexec/rtld-elf/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -.include <bsd.own.mk> +.include <src.opts.mk> MK_SSP= no PROG?= ld-elf.so.1 diff --git a/libexec/rtld-elf/Symbol.map b/libexec/rtld-elf/Symbol.map index 9ad6251..5ea7d7e 100644 --- a/libexec/rtld-elf/Symbol.map +++ b/libexec/rtld-elf/Symbol.map @@ -30,4 +30,5 @@ FBSDprivate_1.0 { _rtld_atfork_post; _rtld_addr_phdr; _rtld_get_stack_prot; + _r_debug_postinit; }; diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c index f96b8e7..443767d 100644 --- a/libexec/rtld-elf/rtld.c +++ b/libexec/rtld-elf/rtld.c @@ -162,6 +162,7 @@ static bool matched_symbol(SymLook *, const Obj_Entry *, Sym_Match_Result *, const unsigned long); void r_debug_state(struct r_debug *, struct link_map *) __noinline; +void _r_debug_postinit(struct link_map *) __noinline; /* * Data declarations. @@ -637,6 +638,7 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_proc, Obj_Entry **objp) if (obj_main->crt_no_init) preinit_main(); objlist_call_init(&initlist, &lockstate); + _r_debug_postinit(&obj_main->linkmap); objlist_clear(&initlist); dbg("loading filtees"); for (obj = obj_list->next; obj != NULL; obj = obj->next) { @@ -3549,7 +3551,20 @@ r_debug_state(struct r_debug* rd, struct link_map *m) * even when marked __noinline. However, gdb depends on those * calls being made. */ - __asm __volatile("" : : : "memory"); + __compiler_membar(); +} + +/* + * A function called after init routines have completed. This can be used to + * break before a program's entry routine is called, and can be used when + * main is not available in the symbol table. + */ +void +_r_debug_postinit(struct link_map *m) +{ + + /* See r_debug_state(). */ + __compiler_membar(); } /* diff --git a/libexec/tcpd/Makefile b/libexec/tcpd/Makefile index e707a4e..f3fbf29 100644 --- a/libexec/tcpd/Makefile +++ b/libexec/tcpd/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -.include <bsd.own.mk> +.include <src.opts.mk> .PATH: ${.CURDIR}/../../contrib/tcp_wrappers diff --git a/libexec/telnetd/Makefile b/libexec/telnetd/Makefile index dcc3398..99f023f 100644 --- a/libexec/telnetd/Makefile +++ b/libexec/telnetd/Makefile @@ -3,7 +3,7 @@ # Do not define -DKLUDGELINEMODE, as it does not interact well with many # telnet implementations. -.include <bsd.own.mk> +.include <src.opts.mk> TELNETDIR= ${.CURDIR}/../../contrib/telnet .PATH: ${TELNETDIR}/telnetd |