Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7037255
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T01:31:21+00:00 2026-05-28T01:31:21+00:00

One code work from runghc, but I can not compile same one with ghc

  • 0

One code work from runghc, but I can not compile same one with ghc command. Why?

Below is my minimal code and environment:
https://gist.github.com/1588756

Works well:

$ runghc cat.hs

Can not compile:

$ ghc cat.hs -o cat

Macbook air, max os x snow leopard

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T01:31:22+00:00Added an answer on May 28, 2026 at 1:31 am

    The .cs extension shown in your paste is wrong;1 rename the file to cat.hs and it’ll work fine.

    This error message:

    ld: warning: ignoring file cat.cs, file was built for unsupported file format
    which is not the architecture being linked (i386)
    

    occurs when you pass a file GHC doesn’t know how to handle; it just passes it on directly to the linker, which then ignores it as it doesn’t know, either. 🙂

    1 At least until GHC gets C# support…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I had my code work fine yesterday, but today I can no longer get
I used textmate to work with ruby code for over one year. Recently I
In code one can specify globally accessible constants/enums/etc once that can then be reused
How can one allow code snippets to be entered into an editor (as stackoverflow
how does one use code to do this: produce 15 random numbers [EDIT: from
I've got a code work flow dependent on pulling changes from a repo clones
A simple question: Why does this the first code work but the seemingly identical
here is my code , i am trying to get from one view to
I'm migrating some stuff from one mysql server to a sql server but i
I have working code below for collision of two circles, but now I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.