Giter Site home page Giter Site logo

trampoline's Introduction

Trampoline

Trampoline is a lldb module that loads .lldbinit files depending on current active target.

Motivation

Sometimes you might have breakpoints, watchpoints, or additional lldb commands in your .lldbinit that don't fit for your current executable or don't fit your current architecture. Trampoline will load additional .lldbinit files according to your current executable and architecture.

File name scheme

Trampoline will search for .lldbinit files named: [executable.lldb, executable-arch.lldb] per default within the same directory trampoline.py is in.

E.g. your executable is named example and you are running lldb on a x86_64 machine. Trampoline will search for example.lldb (used for architecture independent lldb commands) and example-x86_64.lldb (lldb commands that only work on that specific architecture) and load them if available.

Installation

Copy the trampoline.py file somewhere onto your machine and insert into your ~/.lldbinit file following line:

# ~/.lldbinit
command script import /path/to/your/trampoline.py

Search path

Per default, Trampoline is searching for *.lldb files within the directory where trampoline.py is located. To change the search path insert into your /.lldbinit file following line:

# ~/.lldbinit
script trampoline.lldb_files_search_path = '~/your/new/search/path/lldb'

Disable automatic *.lldb file loading

Currently there seems to be a bug within lldb which prevents Trampolines automatic execution on startup, if lldb is run via terminal, if executed in Xcode everything works as usual.
To temporarily bypass this unexpected behaviour you can disable automatically loading of .lldb files via

# ~/.lldbinit
script trampoline.disable_automatic_load = True

Commands

Commands avaiable after enabling Trampoline.

tr_load

To manually load *.lldb files during a lldb debug session, you can enter tr_load into your lldb command line interpreter, which loads the desired *.lldb files as described in File name scheme.

trampoline's People

Contributors

obayer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.