Can't build GrowlTcl extension as universal binary
Posted: Thu Nov 30, 2006 3:48 am
I'm having trouble building Growl's Tcl bindings as a universal binary.
Here are the steps I've taken:
1. Downloaded the source code for Growl 0.7.4.
2. cd to Bindings/tcl.
3. Edit the makefile to add -arch args to the CFLAGS. (CFLAGS = -Wall -DUSE_TCL_STUBS -arch ppc -arch i386)
4. Run make.
(Running Xcode 2.4.1 on OS X 10.4.8, iBook G3)
This is the output:
gcc -Wall -DUSE_TCL_STUBS -arch ppc -arch i386 -c -o GrowlApplicationBridge.o GrowlApplicationBridge.m
GrowlApplicationBridge.m:14:27: error: NSURLAdditions.h: No such file or directory
GrowlApplicationBridge.m:15:29: error: CFGrowlAdditions.h: No such file or directory
GrowlApplicationBridge.m:16:33: error: GrowlDefinesInternal.h: No such file or directory
GrowlApplicationBridge.m:17:26: error: GrowlPathUtil.h: No such file or directory
GrowlApplicationBridge.m:18:25: error: GrowlPathway.h: No such file or directory
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge notifyWithDictionary:]':
GrowlApplicationBridge.m:237: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:237: error: (Each undeclared identifier is reported only once
GrowlApplicationBridge.m:237: error: for each function it appears in.)
GrowlApplicationBridge.m:239: error: 'icon' undeclared (first use in this function)
GrowlApplicationBridge.m:256: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:257: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:258: warning: no '-postNotificationWithDictionary:' method found
GrowlApplicationBridge.m:258: warning: (Messages without a matching method signature
GrowlApplicationBridge.m:258: warning: will be assumed to return 'id' and accept
GrowlApplicationBridge.m:258: warning: '...' as arguments.)
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge isGrowlInstalled]':
GrowlApplicationBridge.m:298: error: 'GrowlPathUtil' undeclared (first use in this function)
GrowlApplicationBridge.m:299: warning: control reaches end of non-void function
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge registrationDictionaryByFillingInDictionary:restrictToKeys:]':
GrowlApplicationBridge.m:405: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:406: error: parse error before ')' token
GrowlApplicationBridge.m:416: error: 'GROWL_APP_LOCATION' undeclared (first use in this function)
GrowlApplicationBridge.m:418: warning: implicit declaration of function 'copyCurrentProcessURL'
GrowlApplicationBridge.m:418: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:420: warning: 'NSURL' may not respond to '-dockDescription'
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _applicationIconDataForGrowlSearchingRegistrationDictionary:]':
GrowlApplicationBridge.m:476: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:477: warning: implicit declaration of function 'copyIconDataForURL'
GrowlApplicationBridge.m:477: warning: invalid receiver type 'int'
GrowlApplicationBridge.m:14:27: error: NSURLAdditions.h: No such file or directory
GrowlApplicationBridge.m:15:29: error: CFGrowlAdditions.h: No such file or directory
GrowlApplicationBridge.m:16:33: error: GrowlDefinesInternal.h: No such file or directory
GrowlApplicationBridge.m:17:26: error: GrowlPathUtil.h: No such file or directory
GrowlApplicationBridge.m:18:25: error: GrowlPathway.h: No such file or directory
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _launchGrowlIfInstalledWithRegistrationDictionary:]':
GrowlApplicationBridge.m:606: error: 'GrowlPathUtil' undeclared (first use in this function)
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge notifyWithDictionary:]':
GrowlApplicationBridge.m:237: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:237: error: (Each undeclared identifier is reported only once
GrowlApplicationBridge.m:237: error: for each function it appears in.)
GrowlApplicationBridge.m:239: error: 'icon' undeclared (first use in this function)
GrowlApplicationBridge.m:256: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:257: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:258: warning: no '-postNotificationWithDictionary:' method found
GrowlApplicationBridge.m:258: warning: (Messages without a matching method signature
GrowlApplicationBridge.m:258: warning: will be assumed to return 'id' and accept
GrowlApplicationBridge.m:258: warning: '...' as arguments.)
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge isGrowlInstalled]':
GrowlApplicationBridge.m:298: error: 'GrowlPathUtil' undeclared (first use in this function)
GrowlApplicationBridge.m:299: warning: control reaches end of non-void function
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge registrationDictionaryByFillingInDictionary:restrictToKeys:]':
GrowlApplicationBridge.m:405: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:406: error: parse error before ')' token
GrowlApplicationBridge.m:416: error: 'GROWL_APP_LOCATION' undeclared (first use in this function)
GrowlApplicationBridge.m:418: warning: implicit declaration of function 'copyCurrentProcessURL'
GrowlApplicationBridge.m:418: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:420: warning: 'NSURL' may not respond to '-dockDescription'
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _applicationIconDataForGrowlSearchingRegistrationDictionary:]':
GrowlApplicationBridge.m:476: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:477: warning: implicit declaration of function 'copyIconDataForURL'
GrowlApplicationBridge.m:477: warning: invalid receiver type 'int'
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _launchGrowlIfInstalledWithRegistrationDictionary:]':
GrowlApplicationBridge.m:606: error: 'GrowlPathUtil' undeclared (first use in this function)
lipo: can't figure out the architecture type of: /var/tmp//ccmkpRnQ.out
make: *** [GrowlApplicationBridge.o] Error 1
I have no idea what's going on here. Do I need to build the Growl frameworks before I build the bindings? I didn't think that was the case, because I *did* successfully build the same extension from Growl 0.6.2, but that won't run on MacTel (even though it built as a UB and lipo says there is i386 bits there as well).
The one odd thing here is that in the source code tree, GrowlApplicationBridge.h, GrowlApplicationBridge.m, and GrowlDefines.h are symlinked--not actually present in the Bindings/tcl directory. Not sure if that makes a difference or not.
Here are the steps I've taken:
1. Downloaded the source code for Growl 0.7.4.
2. cd to Bindings/tcl.
3. Edit the makefile to add -arch args to the CFLAGS. (CFLAGS = -Wall -DUSE_TCL_STUBS -arch ppc -arch i386)
4. Run make.
(Running Xcode 2.4.1 on OS X 10.4.8, iBook G3)
This is the output:
gcc -Wall -DUSE_TCL_STUBS -arch ppc -arch i386 -c -o GrowlApplicationBridge.o GrowlApplicationBridge.m
GrowlApplicationBridge.m:14:27: error: NSURLAdditions.h: No such file or directory
GrowlApplicationBridge.m:15:29: error: CFGrowlAdditions.h: No such file or directory
GrowlApplicationBridge.m:16:33: error: GrowlDefinesInternal.h: No such file or directory
GrowlApplicationBridge.m:17:26: error: GrowlPathUtil.h: No such file or directory
GrowlApplicationBridge.m:18:25: error: GrowlPathway.h: No such file or directory
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge notifyWithDictionary:]':
GrowlApplicationBridge.m:237: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:237: error: (Each undeclared identifier is reported only once
GrowlApplicationBridge.m:237: error: for each function it appears in.)
GrowlApplicationBridge.m:239: error: 'icon' undeclared (first use in this function)
GrowlApplicationBridge.m:256: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:257: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:258: warning: no '-postNotificationWithDictionary:' method found
GrowlApplicationBridge.m:258: warning: (Messages without a matching method signature
GrowlApplicationBridge.m:258: warning: will be assumed to return 'id' and accept
GrowlApplicationBridge.m:258: warning: '...' as arguments.)
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge isGrowlInstalled]':
GrowlApplicationBridge.m:298: error: 'GrowlPathUtil' undeclared (first use in this function)
GrowlApplicationBridge.m:299: warning: control reaches end of non-void function
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge registrationDictionaryByFillingInDictionary:restrictToKeys:]':
GrowlApplicationBridge.m:405: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:406: error: parse error before ')' token
GrowlApplicationBridge.m:416: error: 'GROWL_APP_LOCATION' undeclared (first use in this function)
GrowlApplicationBridge.m:418: warning: implicit declaration of function 'copyCurrentProcessURL'
GrowlApplicationBridge.m:418: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:420: warning: 'NSURL' may not respond to '-dockDescription'
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _applicationIconDataForGrowlSearchingRegistrationDictionary:]':
GrowlApplicationBridge.m:476: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:477: warning: implicit declaration of function 'copyIconDataForURL'
GrowlApplicationBridge.m:477: warning: invalid receiver type 'int'
GrowlApplicationBridge.m:14:27: error: NSURLAdditions.h: No such file or directory
GrowlApplicationBridge.m:15:29: error: CFGrowlAdditions.h: No such file or directory
GrowlApplicationBridge.m:16:33: error: GrowlDefinesInternal.h: No such file or directory
GrowlApplicationBridge.m:17:26: error: GrowlPathUtil.h: No such file or directory
GrowlApplicationBridge.m:18:25: error: GrowlPathway.h: No such file or directory
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _launchGrowlIfInstalledWithRegistrationDictionary:]':
GrowlApplicationBridge.m:606: error: 'GrowlPathUtil' undeclared (first use in this function)
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge notifyWithDictionary:]':
GrowlApplicationBridge.m:237: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:237: error: (Each undeclared identifier is reported only once
GrowlApplicationBridge.m:237: error: for each function it appears in.)
GrowlApplicationBridge.m:239: error: 'icon' undeclared (first use in this function)
GrowlApplicationBridge.m:256: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:257: error: cannot find protocol declaration for 'GrowlNotificationProtocol'
GrowlApplicationBridge.m:258: warning: no '-postNotificationWithDictionary:' method found
GrowlApplicationBridge.m:258: warning: (Messages without a matching method signature
GrowlApplicationBridge.m:258: warning: will be assumed to return 'id' and accept
GrowlApplicationBridge.m:258: warning: '...' as arguments.)
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge isGrowlInstalled]':
GrowlApplicationBridge.m:298: error: 'GrowlPathUtil' undeclared (first use in this function)
GrowlApplicationBridge.m:299: warning: control reaches end of non-void function
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge registrationDictionaryByFillingInDictionary:restrictToKeys:]':
GrowlApplicationBridge.m:405: error: 'NSImage' undeclared (first use in this function)
GrowlApplicationBridge.m:406: error: parse error before ')' token
GrowlApplicationBridge.m:416: error: 'GROWL_APP_LOCATION' undeclared (first use in this function)
GrowlApplicationBridge.m:418: warning: implicit declaration of function 'copyCurrentProcessURL'
GrowlApplicationBridge.m:418: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:420: warning: 'NSURL' may not respond to '-dockDescription'
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _applicationIconDataForGrowlSearchingRegistrationDictionary:]':
GrowlApplicationBridge.m:476: warning: initialization makes pointer from integer without a cast
GrowlApplicationBridge.m:477: warning: implicit declaration of function 'copyIconDataForURL'
GrowlApplicationBridge.m:477: warning: invalid receiver type 'int'
GrowlApplicationBridge.m: In function '+[GrowlApplicationBridge _launchGrowlIfInstalledWithRegistrationDictionary:]':
GrowlApplicationBridge.m:606: error: 'GrowlPathUtil' undeclared (first use in this function)
lipo: can't figure out the architecture type of: /var/tmp//ccmkpRnQ.out
make: *** [GrowlApplicationBridge.o] Error 1
I have no idea what's going on here. Do I need to build the Growl frameworks before I build the bindings? I didn't think that was the case, because I *did* successfully build the same extension from Growl 0.6.2, but that won't run on MacTel (even though it built as a UB and lipo says there is i386 bits there as well).
The one odd thing here is that in the source code tree, GrowlApplicationBridge.h, GrowlApplicationBridge.m, and GrowlDefines.h are symlinked--not actually present in the Bindings/tcl directory. Not sure if that makes a difference or not.