Ticket #25 (closed defect: worksforme)

Opened 5 years ago

Last modified 5 years ago

'Bus Error' in Mac OS X

Reported by: AntoineLatter Owned by:
Priority: major Milestone:
Component: network Version:
Keywords: Cc:

Description

I'm running Mac OS X Version 10.6.2 on a 2.4 GHz Intel Core 2 Duo. I'm running this on GHC 6.12.1 which I compiled myself (from GHC 6.12.0.20091120). I'm testing this with network-2.2.1.5 as downloaded from hackage.

Here's an example ghci session:

$ ghci
GHCi, version 6.12.1: http://www.haskell.org/ghc/  :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package ffi-1.0 ... linking ... done.
Prelude> :m Network
Prelude Network> sendTo "localhost" (PortNumber 20) "hello"
Loading package syb-0.1.0.2 ... linking ... done.
Loading package base-3.0.3.2 ... linking ... done.
Loading package parsec-2.1.0.1 ... linking ... done.
Loading package network-2.2.1.5 ... linking ... done.
Bus error

A more specific error:

> getAddrInfo (Just defaultHints) (Just "google.com") Nothing
Loading package syb-0.1.0.2 ... linking ... done.
Loading package base-3.0.3.2 ... linking ... done.
Loading package parsec-2.1.0.1 ... linking ... done.
Loading package network-2.2.1.5 ... linking ... done.
Bus error

If there are any other components you'd like me to test let me know.

If you need any logs from me trying to configure netwok or build logs anything like that let me know.

Change History

Changed 5 years ago by AntoineLatter

I'm on a 64-bit platform, so I used to run into problems at run-time with things compiled with hsc2hs. I haven't seen that with the released version of GHC 6.12.1 - zlib works great now.

But it wouldn't surprise me if something somewhere in the toolchain wasn't told that we need to be building for a 32-bit architecture. All of the tools installed with OS X 10.6 assume 64-bit by default.

Changed 5 years ago by AntoineLatter

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

So I edited the sources of Socket.hsc to insert some Debug.Trace messages to figure out how far we got before the bus error. After recompiling everything worked. I removed the calls to 'trace' and things still worked.

Closing!

Note: See TracTickets for help on using tickets.