From: pere.noel@... (=?ISO-8859-1?Q?Une_b=E9vue?=) Date: 2006-08-14T23:20:11+09:00 Subject: Re: [MacOS X Ruby-ext] errors in include "CFURL.h" Daniel Harple wrote: > Try linking against the framework using the -framework flag. > > $LDFLAGS << " -framework CoreFoundation". fine thanks, it's ok now for the links, however i get a bus error at runtime : /Users/yvon/work/Ruby/Native/C/raliasfile_test.rb:8: [BUG] Bus Error ruby 1.8.4 (2005-12-24) [powerpc-darwin8.7.0] From C => alias_path : /Users/yvon/work/Ruby/Native/C/doc/Introduction_ANSI_C_html the line 8 of raliasfile_test.rb being simply : a=RAliasFile.new("/Users/yvon/work/Ruby/Native/C/doc/Introduction_ANSI_C _html") (just after "require 'osx/ralias/raliasfile'") and on the C side : VALUE m_raliasfile_init(VALUE self, VALUE alias_path) { printf("From C => alias_path : %s\n", StringValuePtr(alias_path)); rb_iv_set(self, "@alias_path", alias_path); Boolean NO=(Boolean)Qfalse; CFURLRef url = CFURLCreateWithFileSystemPath(kCFAllocatorDefault, (CFStringRef)alias_path, 0, NO); if (url != NULL) { printf("From C => url != NULL\n"); } return self; } from the printf(...) i know the error is certaiinly due to this line : CFURLRef url = CFURLCreateWithFileSystemPath(kCFAllocatorDefault, (CFStringRef)alias_path, 0, NO); -- une b�vue