タグ

関連タグで絞り込む (1)

タグの絞り込みを解除

macとgdbに関するembeddedのブックマーク (2)

  • Debugging and stack traces on Mac OS X Lion

    Mac OS X 10.7 Lion (really, Xcode 4) has changed the way that the system linker works in a way which makes debugging and interpreting stack traces difficult-to-impossible without special action. From man ld, Options when creating a main executable -pie This makes a special kind of main executable that is position independent (PIE).  On Mac OS X 10.5 and later, the OS the OS will load a PIE at a ra

    embedded
    embedded 2011/08/20
    MacのLionではデフォルトでPIE(Position Independent Executable)としてリンクするようになった。そのため既存のデバッガが動かない。回避するにはld に -no_pieをつける。gccからは-Wl,-no_pie
  • Macでgdbにプロセスの制御権を与える - handlename's blog

    前回の記事で出ていたエラーメッセージについて、解決したので。 darwinでgdbを使って デバッグする = プロセスを制御する ためには権限が必要なんだそうです。 Building GDB for Darwin - GDB Wiki なので、gdbを実行するときに $ sudo gdb hogehogeとすればデバッグはできるのですが、わざわざ管理者権限でデバッグするのは嫌><!ということで、証明書をつくってプロセスの制御を許可する、というのがスマートな方法らしいです(ということがまんま上記のページに書いてあります:p) せっかくなので証明書のつくりかたと登録の方法をSS入りで。 証明書の作成 キーチェーンアクセスでつくります。 キーチェーンを起動して、 キーチェーンアクセス > 証明書アシスタント > 証明書を作成...を選択。 名前: gdb-cert (わかればなんでもいい) 固有

    Macでgdbにプロセスの制御権を与える - handlename's blog
  • 1