I am the Mac guy for the ChemDraw (http://cambridgesoft.com) application and plugins. I am trying to debug our plugins using the nightly build. The problem is it will not even load. The load is failing on line 286 of WebNetscapePluginPackage.m :
and the following is printed from the console.
**** begin console output ******
2007-02-12 13:26:04.438 Safari CFLog (21): Error loading /Users/glenn/Library/Internet Plug-Ins/CS ChemDraw Pro.plugin/Contents/MacOS/CS ChemDraw Pro: error code 4, error number 0 (Symbol not found: _objc_msgSend_fpret
Referenced from: /Users/glenn/Library/Internet Plug-Ins/CS ChemDraw Pro.plugin/Contents/MacOS/CS ChemDraw Pro
Expected in: /Users/glenn/WebKit/WebKit/WebKitBuild/Debug/WebKit.framework/Versions/A/WebKit
***** end console output *********
Our plugin uses elements of both Cocoa and Carbon. I doubt if our release plugins have this problem as we have massively changed their structure for this release.
If someone with authority to sign an NDA could get in touch with me, I could see about getting them enrolled in our beta cycle.
Per Comment #0, this is a regression.
I won't pretend to understand what _objc_msgSend_fpret does, but some more information about your build environment would be helpful. For example:
What version of Xcode are you using?
Are you building on a PowerPC-based or Intel-based Mac?
Are you building a universal binary?
Which OS X SDK does your project use, e.g., MacOSX10.4u.sdk?
Answer to Questions:
Version of XCode: 2.4.1
Built on Intel Mac
Building a Universal Binary
Cross Developed using the 10.4 Universal SDK
SDK path: /Developer/SDKs/MacOSX10.4u.sdk
A Google search for _objc_msgSend_fpret finds it defined in the following places
I get the feeling this is very similar to the issue mentioned in passing in bug 12612 comment 6. The reason it doesn't work with nightly builds is that they linked in slightly different fashion than production builds. WebKit is not built as an umbrella framework, which makes symbol lookup happen in a different fashion for symbols in dependent libraries. In this case your plugin is expecting to find objc_msgSend_fpret (used for processing Objective-C message sends with floating-point results) in WebKit. You can work around this temporarily by linking your plugin directly against /usr/lib/libobjc.dylib. I'll prepare a patch to WebKit shortly, it would be great if you can test it and let me know if it resolves your issue.
I landed a change to the linker configuration in r19594 that should address this issue. Can you please test with a nightly build from on or after this revision to confirm that the fix has resolved the problem.
Yes, I did a build from source and our plugin now loads. I can now debug our plugin, which is what I wanted to do initially.
Thank you for the amazingly fast turn around time.
Safari now crashes when I try to quit the application with an EXC_BAD_ACCESS message in the debugger. The call stack for the thread that crashed has only one member, tellingly it's "objc_msgSend"
Glenn, it seems very unlikely that a crash like that would be due to the same issue. If you can reproduce it easily it would be great if you could file a new bug report.
I've reported my crash on quit bug as 12767.