I want to create a macro for which a directory path will be given. The macro in-turn has to run another macro for all the files in the directory. Is that possible in gdb ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I assume that the macro you want to run is a gdb macro. To solve this, I suggest you use the Python support in gdb to encompass this. Put the following in
forallindir.pyThen in gdb to
source forallindir.pyand it should work. For example, define a test macro likeand
forallindir /tmp/xx testitwith two sample files in that directory will give usHope that helps.