[MacPorts] #20132: ghc missing variable definitions in 10.6

MacPorts noreply at macports.org
Thu Mar 11 02:22:25 PST 2010


#20132: ghc missing variable definitions in 10.6
------------------------------+---------------------------------------------
 Reporter:  snc@…             |       Owner:  gwright@…           
     Type:  defect            |      Status:  assigned            
 Priority:  Normal            |   Milestone:                      
Component:  ports             |     Version:  1.8.0               
 Keywords:  snowleopard       |        Port:  ghc                 
------------------------------+---------------------------------------------

Comment(by thomas.hutchinson@…):

 Replying to [comment:106 gwright@…]:
 > >
 > > Replying to [comment:100 gwright@…]:
 > > > I'd like to have the 64 bit version as the default.  For users that
 need a 32 bit compiler (for example, to make binaries that will run both
 on Leopard and Snow Leopard) I will make a new port, ghc-sl32.  You will
 be able to install both ports simultaneously.  (My original idea of making
 a 32 bit compiler on Snow Leopard a variant made it impossible to have
 both compilers at the same time.)
 > >
 > > Instead of making a separate ghc-sl32 port, can't you make the ghc
 port respect the build_arch and universal_archs variables and do it the
 way every other port in MacPorts does it?
 >
 > No, it is unfortunately not yet possible to make ghc do this.  The
 underlying problem is that ghc cooks its host platform into the code
 generator.  You can't, for example, output 64 bit code using a ghc that
 was built as a 32 bit binary (and vice versa).
 >
 > This is a known problem.  An old cross-compilation system that never
 worked and has been ripped out.  Parts of a new one are in 6.12.x, but are
 not working yet.
 >
 > At the moment, the only way to generate binaries for both 32 and 64 bit
 platforms is to have two compilers.
 >
 > I have mentioned these problems to the upstream maintainers and they
 have given it somewhat more attention of late.  But most of their efforts
 are going to parallelism and type hackery.

 I think there is a miscommunication going on.

 The idea is to have 32 bit functionality be in the main ghc port. It would
 be an exclusive choice. Either ghc is 32 bit or it's 64 bit. The ghc port
 would read the build_arch variable and act accordingly. The resulting
 compiler would (only) produce 32 bit or 64 bit binaries.

 Maybe there is a detail of the ghc bootstrapping that I'm not
 understanding (or I simply misread the comments on this ticket). Still, a
 user should not have to install a different port.

 Please note: there are many of us who use Snow Leopard on 32-bit
 architectures. For instance, I have a MacBook Pro with a Core Duo
 processor. It would be nice to be able to simply "sudo port install ghc".

 I see that you are trying to be able to have both 32 and 64 bit versions
 be installed at the same time. Do any haskell ports need this? Are there
 ports of other compilers that have a similar layout?

 It sounds like you are trying to solve a harder problem than necessary.
 Getting the ghc port working at all looks like difficult task. I think
 installing one "flavor" of ghc is sufficient. Maybe that's naïve of me.

-- 
Ticket URL: <http://trac.macports.org/ticket/20132#comment:107>
MacPorts <http://www.macports.org/>
Ports system for Mac OS


More information about the macports-tickets mailing list