Results 1 to 3 of 3
  1. #1

    Member Since
    Mar 17, 2010
    compiler question

    I recently started working with XCode. I was curious why programs compiled under xcode do not run when used in a unix environment. For example, when I wrote the Hello World program in Xcode and moved it to my linux machine it would not run. I had to gcc main.c before it would run. I thought the underlying architecture for OS X was unix so I expected ./HelloWorld to run.

    Thank you for your help!

  2. #2

    vansmith's Avatar
    Member Since
    Oct 19, 2008
    2012 13" MBP (2.5 i5, 8GB)
    Unix does not equal Linux. Mac OS X is Unix, Linux is Unix-like. You'll find that despite similiarities, you'll have to recompile programs. Someone with more experience in deploying across OSes can be more clear on that one.
    Important Links: Community Guidelines : Use the reputation system if you've been helped.
    M-F Blog :: Write for the blog
    Writing a Quality Post

  3. #3

    cradom's Avatar
    Member Since
    Feb 14, 2004
    Groves, Texas
    13in macbook - 10.11 --- 21in. iMac 10.11 --- HP win 8
    Is your linux machine a PC? If yes that's your main problem right there.
    Even if not, like Van said not all *nixes are equal. Also some libraries are machine specific and need to be recompiled for that machine.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. C Compiler
    By girgroupie47 in forum Switcher Hangout
    Replies: 6
    Last Post: 09-21-2009, 12:02 AM
  2. g++ compiler
    By trooper83 in forum OS X - Development and Darwin
    Replies: 3
    Last Post: 05-18-2009, 12:38 PM
  3. C++ Compiler
    By nyzwerewolf in forum OS X - Development and Darwin
    Replies: 4
    Last Post: 09-25-2008, 11:43 PM
  4. C\C++ Compiler
    By belitos in forum OS X - Operating System
    Replies: 6
    Last Post: 05-05-2008, 01:50 PM
  5. Compiler ...
    By A.I. BOT in forum OS X - Development and Darwin
    Replies: 2
    Last Post: 09-19-2005, 12:00 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts