-
Notifications
You must be signed in to change notification settings - Fork 993
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Command that fetches sources for debugging #4289
Comments
Hi @doronAtuar! Thanks for asking. We have the Which debugger/oss are you trying to use? Linux gdb, lldb, Windows... |
I'm using gdb on Linux but I think my use case is alo valid for lldb. I'm compiling my Debug version on one machine. In-order to get source shown on gdb at the target machine I need to have the sources at the same path as the compilation machine.
So yes, It's better if they are at the cache folder.
Once they are there you don't need to do anything. gdb will find them and load them.
I'm not sure I understand the question correctly. The whole process can be achieved without Conan by:
The problem is that it may require extra installations, tokens for git server, cloning the right tag. I've already managed to do all that with the |
Thanks for the answer, you explained exactly what I need.
It more or less worked, but I had some issues I don't exactly recall. Also, I can remember that I wasn't able to do it with llvm because the ini file doesn't work like that and also I neither made it work in Windows with visual studio, where the pdbs are necessary. So, we don't have yet a way to only download the sources but I add this issue to a new "debugging" project so we can have the requirement and use case present when we develop the solution. |
An important thing to recall here is the difference between the "initial" source files and the "build" source files that are the ones that we need to debug. This is the scenario:
So the open question would be:
|
Hi @memsharded, But I'm sure the use-case exists out there. You could make users that want debug sources to build the package on the target machine. |
We have a similar need. I would have a What we would need from Conan is a list of source directories for a GDB source path. This feature could also be part of an IDE integration. In the Java world your application is defined by a configuration file that says which packages the application uses (a .pom file defines the .jar files that are used). The source for your application is the source of the current app plus the source from the .jar files. When you navigate to a class that is in a .jar file it pulls the source from the local package (Maven) cache. It's a seamless experience that is very productive. |
I just wanted to add to this conversation by saying that this is a feature I would highly like to see also. In my use case, I am using an environment and IDE that is provided to us by a third party vendor we don't have control over, and in order to debug code it requires source code from each dependency. If there was a Conan command that I could run, something like |
Conan 2.0 beta9 is finally getting a new way of getting sources of all dependencies: #13003 This will allow forcing the So I am closing this ticket as implemented for 2.0b9, please try when released, thanks! |
I have an executable built with packages in Debug configuration.
I want to debug the exe on a remote machine.
I want to have sources so I can have a better debugging experience.
Is it possible to install a package's sources only?
I know that
conan install <package-name> -s build_type=Debug --build
fetches the code but also builds it.The text was updated successfully, but these errors were encountered: