• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Calling Cocoa APIs from a command line application
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Calling Cocoa APIs from a command line application


  • Subject: Re: Calling Cocoa APIs from a command line application
  • From: Dave Keck <email@hidden>
  • Date: Sat, 13 Sep 2003 14:54:22 -0400

On 9/13/03 1:22 PM, Scott Anguish wrote:
On Saturday, September 13, 2003, at 1:00 PM, John Siracusa wrote:
I want to call an NSWorkspace method from a simple command-line script. I
naively thought this would work:


I think there might be an easier way to do this. Maybe AppleScript,
which you can fire off from a script trivally. You want the Finder to
notice, right?

Yeah, but I want to do it from within a "normal" Unix C/C++ program.

new.m:5: cannot find interface declaration for `NSConstantString'

Did you link against AppKit as well?

I'm doing all this from the command line, not from within Project Builder.
What's the incantation for linking against AppKit?

gcc -framework "Foundation" -framework "AppKit" main.m

Take a look at what PB does ;-)

- - -

Dave Keck
If I were smart I'd own a company to tell you the the name of.
"Contrariwise," continued Tweedledee, "if it was so, it might be; and if it were so, it would be; but as it isn't, it ain't. That's logic."
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
  • Follow-Ups:
    • Re: Calling Cocoa APIs from a command line application
      • From: John Siracusa <email@hidden>
References: 
 >Re: Calling Cocoa APIs from a command line application (From: John Siracusa <email@hidden>)

  • Prev by Date: Re: Calling Cocoa APIs from a command line application
  • Next by Date: Re: Calling Cocoa APIs from a command line application
  • Previous by thread: Re: Calling Cocoa APIs from a command line application
  • Next by thread: Re: Calling Cocoa APIs from a command line application
  • Index(es):
    • Date
    • Thread