2006-03-28 13:23:10 -05:00
|
|
|
#include <stdio.h>
|
2006-03-03 12:58:48 -05:00
|
|
|
|
2010-08-17 16:11:33 -04:00
|
|
|
#include <CoreFoundation/CoreFoundation.h>
|
2008-09-02 11:07:04 -04:00
|
|
|
|
2006-03-28 13:23:10 -05:00
|
|
|
extern int foo(char* exec);
|
|
|
|
|
|
|
|
int main(int argc, char* argv[])
|
2005-07-13 15:43:40 -04:00
|
|
|
{
|
2006-03-28 13:23:10 -05:00
|
|
|
printf("Started with: %d arguments\n", argc);
|
2008-09-02 11:07:04 -04:00
|
|
|
|
2010-08-17 16:11:33 -04:00
|
|
|
// Call a CoreFoundation function... but pull in the link dependency on "-framework
|
|
|
|
// CoreFoundation" via CMake's dependency chaining mechanism. This code exists to
|
2008-09-02 11:07:04 -04:00
|
|
|
// verify that the chaining mechanism works with "-framework blah" style
|
|
|
|
// link dependencies.
|
|
|
|
//
|
|
|
|
CFBundleRef br = CFBundleGetMainBundle();
|
|
|
|
(void) br;
|
|
|
|
|
2006-03-28 13:23:10 -05:00
|
|
|
return foo(argv[0]);
|
2005-07-13 15:43:40 -04:00
|
|
|
}
|