URL: <http://savannah.gnu.org/bugs/?35777>
Summary: GSWeb build on Mac OS X fails due to object_getClass() Project: GNUstep Submitted by: leeg Submitted on: Fri 09 Mar 2012 09:54:30 PM GMT Category: gsweb Severity: 3 - Normal Item Group: Bug Status: None Privacy: Public Assigned to: None Open/Closed: Open Discussion Lock: Any _______________________________________________________ Details: Building for apple-apple-apple fails with this error: $ make This is gnustep-make 2.6.2. Type 'make print-gnustep-make-help' for help. Making all in GSWeb ... Making build-headers for framework WebObjects... Making all for framework WebObjects... Compiling file GSWConstants.m ... In file included from GSWeb.h:176, from GSWConstants.m:37: GSWDynamicElement.h: In function ‘GSWDynamicElement_evaluateValueInContext’: GSWDynamicElement.h:62: error: implicit declaration of function ‘object_getClass’ GSWDynamicElement.h:62: warning: comparison between pointer and integer make[3]: *** [obj/WebObjects/WebObjects.obj/GSWConstants.m.o] Error 1 make[2]: *** [internal-framework-run-compile-submake] Error 2 make[1]: *** [WebObjects.all.framework.variables] Error 2 make: *** [internal-all] Error 2 On the new Apple Objective-C runtime, the API for getting a class (objc_getClass()) takes a name, not an instance. Therefore I've patched this by using the -class method, which should work with any Objective-C runtime. Index: GSWeb/GSWDynamicElement.h =================================================================== --- GSWeb/GSWDynamicElement.h (revision 34917) +++ GSWeb/GSWDynamicElement.h (working copy) @@ -58,8 +58,7 @@ BOOL GSWDynamicElement_evaluateValueInContext(GSWDynamicElement* element,Class standardClass, GSWIMP_BOOL imp,GSWAssociation* condition,GSWContext* context) { - // was object_get_class - if (imp && object_getClass(element)==standardClass) + if (imp && ([element class]==standardClass)) { return (*imp)(element,evaluateConditionInContextSEL, condition,context); _______________________________________________________ Reply to this item at: <http://savannah.gnu.org/bugs/?35777> _______________________________________________ Message sent via/by Savannah http://savannah.gnu.org/ _______________________________________________ Bug-gnustep mailing list Bug-gnustep@gnu.org https://lists.gnu.org/mailman/listinfo/bug-gnustep