Closed Bug 535908 Opened 15 years ago Closed 15 years ago

Patch for bug 396680 breaks 64-bit builds on SnowLeopard

Categories

(Core :: Widget: Cocoa, defect)

All
macOS
defect
Not set
critical

Tracking

()

RESOLVED FIXED

People

(Reporter: smichaud, Assigned: smichaud)

References

Details

Attachments

(1 file)

My patch for bug 396680 breaks 64-bit builds.  They die with the
following link errors:

Undefined symbols:
  "_OBJC_CLASS_$_PDEPluginCallback", referenced from:
      l_OBJC_$_CATEGORY_PDEPluginCallback_$_MethodSwizzling
        in libwidget_mac.a(nsAppShell.o)
      __objc_classrefs__DATA@0 in libwidget_mac.a(nsAppShell.o)
  "_OBJC_IVAR_$_PDEPluginCallback._printWindowController", referenced from:
      -[PDEPluginCallback(MethodSwizzling)
        nsAppShell_PDEPluginCallback_dealloc]
        in libwidget_mac.a(nsAppShell.o)
ld: symbol(s) not found

These are caused by a change in the behavior of gcc:  The errors don't
happen when using gcc 4.2 to compile a 32-bit build on OS X 10.5.8.  I
haven't yet tried a 32-bit build (with gcc 4.2) on SnowLeopard.

The solution is to use a lower-level method to access the
PDEPluginCallback class's _printWindowController variable.

I'll post a patch in my next comment.

Thanks to Joel Reymont for pointing this out to me via email.
Assignee: nobody → smichaud
Blocks: 396680
Attached patch Fix/workaroundSplinter Review
Attachment #418457 - Flags: review?(joshmoz)
Status: NEW → ASSIGNED
I've tested this patch in a 32-bit build on OS X 10.5.8.  It has
exactly the same functionality as the previous code -- it still fixes
bug 396680, without introducing any new problems.
Summary: Patch for bug 396680 breaks 64-bit builds → Patch for bug 396680 breaks 64-bit builds on SnowLeopard
The link errors don't happen doing a 32-bit build on SnowLeopard.  So they only happen doing 64-bit builds.
Joel, please test my patch and let us know your results.
Attachment #418457 - Flags: review?(joshmoz) → review+
Landed on trunk:
http://hg.mozilla.org/mozilla-central/rev/4ad1dfc25ea7
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Builds fine on x86-64.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: