* Added support for debugger handover. The current debugger need to send
a B_DEBUG_MESSAGE_HANDED_OVER message. The rest is completely
transparent to the new debugger. It simply calls install_team_debugger().
* Implemented _user_wait_for_debugger().
* Reworked a few bits to ensure that after a remove_team_debugger() or
after requesting a debugger handover the debugger doesn't get any more
messages.
* When the debugger is removed or dies, the debugged threads should now
cleanup their debug info and continue, instead of waiting at their
debug port forever.
All the new features are not tested. Will happen, when gdb will be
debugged.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11697 a95241bf-73f2-0310-859d-f6bbb57e9c96
(new `flags' parameter, flag B_WAIT_TILL_LOADED). This is the default
behaviour for load_image(), so it behaves like R5's implementation now,
i.e. errors while loading are reported to the caller.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11696 a95241bf-73f2-0310-859d-f6bbb57e9c96
* We no longer notify the debugger about a new image when it is registered,
but when it has been relocated.
* When the application image has been relocated, we notify the one who
initiated its loading.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11694 a95241bf-73f2-0310-859d-f6bbb57e9c96
(maybe this should better go into a private header?). If given the function
waits till the loader is done with loading and relocating the executable.
Otherwise it returns before the loader starts.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11690 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added _kern_image_relocated() and _kern_loading_app_failed(), which
are invoked by the loader to provide the kernel with more info.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11689 a95241bf-73f2-0310-859d-f6bbb57e9c96
it actually meant.
* Refactored the image initialization process (init_dependencies()) a bit.
topological_sort() is now more flexible.
* The image relocation is now done by relocate_dependencies(). The order
of relocating the images is the same as the initialization order, so
that the app image is the last to be relocated. After having relocated
an image the kernel is notified.
* The FATAL() macro has another parameter, an error code now, and calls
the new syscall _kern_loading_app_failed() instead of _kern_exit_team().
So the error can be reported to the team that called load_image().
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11688 a95241bf-73f2-0310-859d-f6bbb57e9c96
second time for already loaded libraries, when a library/add-on is
loaded.
* image_t features now both, a path and a name. The name is the DT_SONAME,
if present, the leaf name otherwise.
* Modified find_image() to compare both path and name, if necessary.
Added a type mask parameter to specify what image types one is
interested.
* Refactored open_container(). We now also support DT_RPATH, a dependency
search path list that can be specified for the dependencies of a shared
object.
* Extended [un]load_library() to support add-ons.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11685 a95241bf-73f2-0310-859d-f6bbb57e9c96
* When the target is a symlink, it is tried to be resolved before making
the decision what to do.
* If the (resolved) target is a file and the source is a file, we don't
fail anymore, if `-f' wasn't specified. We truncate the target file
instead and copy the source data into it.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11683 a95241bf-73f2-0310-859d-f6bbb57e9c96
Also removed team::user_env_base: environment variables are now changed on the app's heap.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11672 a95241bf-73f2-0310-859d-f6bbb57e9c96
malloc() currently cannot be used in initialize_before() in libroot.so,
and therefore a _after() call has been added for this.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11670 a95241bf-73f2-0310-859d-f6bbb57e9c96
made it thread-safe, although this is not required by POSIX.
Implemented unsetenv(), improved putenv().
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11668 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Implemented _user_wait_for_debugger().
* Reworked a few bits to ensure that after a remove_team_debugger() or
after requesting a debugger handover the debugger doesn't get any more
messages.
* When the debugger is removed or dies, the debugged threads should now
cleanup their debug info and continue, instead of waiting at their
debug port forever.
All the new features are not tested. Will happen, when gdb will be
debugged.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11664 a95241bf-73f2-0310-859d-f6bbb57e9c96
debugger. After successful reply to the message the debugger won't receive
any more messages from the debugged team. The mechanism is completely
transparent to the target debugger. It simply installs itself as debugger
for the team.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11662 a95241bf-73f2-0310-859d-f6bbb57e9c96
zooey agreed when discussing this (and we hope this don't break anything)
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11660 a95241bf-73f2-0310-859d-f6bbb57e9c96
added macros to use our standard posix call when possible instead of prefixed versions
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11651 a95241bf-73f2-0310-859d-f6bbb57e9c96