[Lldb-commits] [PATCH] D15152: Change Platform::LoadImage to copy the file to the remote platform
Greg Clayton via lldb-commits
lldb-commits at lists.llvm.org
Wed Dec 2 10:14:49 PST 2015
clayborg requested changes to this revision.
clayborg added a comment.
This revision now requires changes to proceed.
"process load" should probably be changed to have an options that allows us to specify where the shared library needs to be installed:
(lldb) process load --install-path=/usr/lib ~/build/libfoo.so
Then we should add a new argument to LoadImage:
uint32_t
Platform::LoadImage(lldb_private::Process* process, const FileSpec& local_image_spec, const FileSpec& install_image_spec, Error& error)
This extra install_image_spec can be empty and if it is, we do what you did in the above patch, else we use the "install_image_spec" to copy the shared library to this location first, then load it from the install location.
This means we might want to change the Platform::LoadImage() to do more stuff up in Platform.cpp (like install the image using the virtual platform functions to install the shared library), and then change all current Platform subclasses that override LoadImage() over to DoLoadImage() and have the platform subclasses just do the actual "dlopen()" call on a specified file. Right now we are duplicating some code between LoadImage methods.
http://reviews.llvm.org/D15152
More information about the lldb-commits
mailing list