diff --git a/scripts/osx/debug.md b/scripts/osx/debug.md index 05c3e0820a077..ea75c2bfee544 100644 --- a/scripts/osx/debug.md +++ b/scripts/osx/debug.md @@ -1,27 +1,34 @@ # Debugging on OSX +We assume that all of the code is in a particular path: + +``` +FR_PATH=$(HOME)/ +``` + The program has to be signed: ```` +cd $(FR_PATH) codesign -s - -v -f --entitlements ./scripts/osx/debug.plist ./build/bin/local/radiusd ``` Start it up in Xcode with a full path to the executable: -`/PATH/build/bin/local/radiusd`. Usually done via `open +`$(FR_PATH)/build/bin/local/radiusd`. Usually done via `open ./build/bin/local` and then dragging the `radius` program to the file selector in Xcode. Set command-line arguments: ``` --fxx -l stdout -m -d /PATH/raddb -D /PATH/share +-fxx -l stdout -m -d $(FR_PATH)/raddb -D $(FR_PATH)/share ``` And environment variables. ``` -DYLD_FALLBACK_LIBRARY_PATH=/Users/alandekok/git/v3.2.x/build/lib/.libs> -FR_LIBRARY_PATH=/Users/alandekok/git/v3.2.x/build/lib/local/.libs +DYLD_FALLBACK_LIBRARY_PATH=$(FR_PATH)/build/lib/.libs> +FR_LIBRARY_PATH=$(FR_PATH)/build/lib/local/.libs ``` Pass signals in `lldb` directly to the program: