Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Commit

Permalink
Initial commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
vargaz committed Jan 10, 2017
0 parents commit ed7ee55
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 0 deletions.
41 changes: 41 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@

Introduction
============

This repository contains osx binaries for the mono lldb repository at:

https://github.com/vargaz/lldb

Usage
=====

The lldb binary is in Release/lldb.

In addition to normal usage, this version supports debugging of JIT code generated by the mono runtime. Run the runtime using the MONO_LLDB env variable to enable this functionality:

MONO_LLDB=1 lldb --args <mono executable> --debug <app>

Fuctionality is currently limited to stack traces and file/line numbers. The --debug argument is required to get file/line numbers.

Its also possible to attach to runtime processes started with MONO_LLDB=1.

MONO_LLDB=1 <mono executable> --debug <app>

In another window do:

lldb -p `pgrep mono`

Recreating the binaries
=======================

1. Clone the repository above
2. Build it using:

xcodebuild build -workspace lldb.xcworkspace -scheme lldb-tool -configuration Release

3. Copy the binaries by running

./create-binaries.sh <lldb source dir>

4. Create a release

32 changes: 32 additions & 0 deletions create-binaries.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/bin/bash

lldb_srcdir=$1

if [ "$lldb_srcdir" == "" ]; then
echo "Usage: create-binaries.sh <llvm source dir>"
exit 1
fi

if [ `uname` != "Darwin" ]; then
echo "This script only works on osx."
exit 1
fi

build_root=`xcodebuild -showBuildSettings -workspace $lldb_srcdir/lldb.xcworkspace -scheme lldb-tool | grep BUILD_ROOT | cut -d '=' -f 2`
if [ "$build_root" == "" ]; then
echo "Unable to determine build dir."
exit 1
fi

echo "LLDB build dir: $build_root"
echo "Target dir: $PWD/Release"

cp -r $build_root/Release .

# Delete files we don't need
rm Release/liblldb-core.a
rm -rf Release/lldb-argdumper Release/lldb-server Release/lldb-argdumper.dSYM Release/debugserver.dSYM
rm -rf Release/LLDB.framework/Resources/lldb-server
rm -rf Release/LLDB.framework/Versions/{Current,A}

du -sk Release

0 comments on commit ed7ee55

Please sign in to comment.