Ticket #595 (closed defect: fixed)

Opened 13 months ago

Last modified 12 months ago

0.5.2 - compile error on OSX using clang, non-void function should return a value

Reported by: github2bits Owned by: phil
Priority: normal Milestone:
Component: libinfinity Version:
Severity: normal Keywords: clang non-void function
Cc: Launchpad Bug:

Description

As reported to Homebrew here, https://github.com/mxcl/homebrew/issues/12462 and documented in this gist of the build: https://gist.github.com/2815501

libinfinity-0.5.2 fails to compile using clang on OSX due a bug in the code where a non-void function 'inf_communication_method_received' does not return a value. This bug is acceptable with llvm-gcc or gcc, but clang is stricter. Clang is the default compiler on Apples these days. Atm, Homebrew works around this issue by forcing the library to be built using an alternate compiler. This might be raised to a blocker on the next version of OSX, Mt. Lion, because it will likely only have clang. Thanks for looking into this.

Change History

Changed 12 months ago by phil

  • owner changed from armin to phil

Changed 12 months ago by phil

  • status changed from new to closed
  • resolution set to fixed

Fixed in c3dfffb6486f68a651cf4a96486c931945a3b88f (master), thanks. (By using return_val_if_fail and using 0. Which does seem unclean, but is equivalent to the existing code.)

Note: See TracTickets for help on using tickets.