The NSLog call should be no big deal since it is provided by the Cocoa frameworks and is inherent to Objective C.
The mpicc compiler may be a different thing. It may not recognize that it supposed to be calling gcc to compile in Objective-C mode and not in pure ISO C-99. I will have look up in my notes to recall the instructions necessary to make regular gcc or clang to compile properly with MPI.
The extension is fine, so I would think that gcc should go into Objective-C mode. I think MacResearch has an example on their site that could help.
Daniel D. Beatty
Computer Scientist, 474300D
Detonation Sciences Branch
On detail for Land Range Data Systems Branch
At Exodus: (760)939-4040 MTTh 0800 to 1800
At Pearson: (760)939-7097 WF 0800 to 1600
From: users-bounces_at_[hidden] [mailto:users-bounces_at_[hidden]] On Behalf Of Ralph Castain
Sent: Monday, September 19, 2011 5:35
To: Open MPI Users
Subject: Re: [OMPI users] Open MPI and Objective C
Nothing to do with us - you call a function "NSLog" that Objective C doesn't recognize. That isn't an MPI function.
On Sep 18, 2011, at 8:20 PM, Scott Wilcox wrote:
I have been asked to convert some C++ code using Open MPI to Objective C and I am having problems getting a simple Obj C program to compile. I have searched through the FAQs and have not found anything specific. Is it an incorrect assumption that the C interfaces work with Obj C, or am I missing something?
Thanks in advance for your help!
open MPI version: 1.4.3
int main (int argc, char** argv)
// Variable Declaration
// Initializing Message Passing Interface
NSLog(@"Executing open MPI Objective C");
UNC ONLY: SAW>mpicc main.m -o test
"___CFConstantStringClassReference", referenced from:
cfstring=Executing open MPI Objective C in ccj1AlL9.o
"_NSLog", referenced from:
_main in ccj1AlL9.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
users mailing list
- application/x-pkcs7-signature attachment: smime.p7s