Re: console.app messages in OSX 10.8


Forums > Dev > console.app messages in OSX 10.8
November 23, 2012 | 3:24 pm

Thanks guys. Arg, that’s what I was afraid of. Why does Apple do this? Why is the world the way it is?

Unfortunately NSLog() or cpost() won’t work for me. I’m building loadable libs, and all symbols need to be resolved before ld is happy. Since cpost() pre-exists in the environment into which I will be loading my lib, well…

And I’m not using obj-C or Xcode directly (good ole makefile-land for me!), so NSLog() won’t work. I tried all of these:

printf("applen");
fprintf(stderr, "isn");
FILE *fd = fopen("/dev/console", "w+");
fprintf(fd, "annoying");

but none worked. So there is no way to print from C-land int the Console.app using standard printing tools? Or is anyone aware of a flag I can set when putting together my lib to keep cpost() unresolved for the time being?

brad

http://music.columbia.edu/~brad