answersLogoWhite

0


Best Answer

First, because it depends on libraries that may or may not be present on other computers. If you compile a Windows .exe program, for instance, it's going to be trying to make calls to Windows APIs like WIN32 and/or WPF. So if you run it on Mac OS X or Linux, it's going to be looking for the Windows stuff that it needs to run and it's going to be totally lost.

WINE is an open-source project that basically acts as a translator for Windows apps on other platforms. It's used in stuff like Crossover Games, a Mac app that lets you run certain Windows games on a Mac. It's not perfect, though, and even if you can get a Windows game or app to run using WINE it might run into quirks, like video cutscenes not playing.

Second, the problem of different processor architectures. This is why you can't use WINE on a PlayStation 3 or an older Mac with a PowerPC processor, even if they're running an OS (like Linux or Mac OS X) that can theoretically support WINE. It's because when a program's compiled, it's only compiled to run on one particular processor architecture, like Intel/AMD or PowerPC or the ARM chips in mobile handhelds. Put it on anything else, and it can't run. The Mac world is split between two different processor architectures (Intel and PowerPC), so they deal with this stuff pretty frequently, although not as much as in 2006 when the first Intel Macs appeared. Ask them about "universal binaries" sometime.

It's also why my Android phone chokes on certain Super Nintendo games. Emulators aren't just a translator like WINE, they have to literally simulate the whole hardware architecture of the platform they're emulating. So my modern high-powered smartphone slows down when running an 18-year-old game for a 20-year-old console, because it's trying to pretend to be every circuit inside that console while it's doing it. But it has to in order to run them.

User Avatar

Wiki User

13y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Why won't a compiled program run on any computer?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do you run a C program on SunOS?

A "C" program has to be compiled to machine code on any Unix system, whether it is Solaris or some other version. After compiling the program, execute it by typing in the name of the compiled program created by the "C" compiler. The standard name is 'a.out', but it could be named anything you want.


How do i turn your Nintendo Wii into a computer?

Not possible, while you can get a Emulator like Dolphin. if you don't know, an emulator tricks your computer into thinking its a wii. of course, this wont harm your computer in any way, close the program and the computer will be like it was. but, an emulator needs ROM's which can be hard to get.


Give a brief description about compiled and interpreted high level languages?

Any high level language may be either compiled or interpreted. The difference is in the execution speed. Interpreted programs must re-learn how to do each statement in the program, whereas a compiled program is already in the machine code language of the hardware and runs much faster.


When can you get computer viruses?

Any time you are in a program.


What program handles CLASS files?

CLASS files are executed by the JVM. Essentially, they are compiled (they aren't exactly compiled, but that's the basic idea) code that can be run by the computer. They aren't designed to be opened and viewed. You can view the corresponding JAVA file in any text editor, though a good IDE, such as Eclipse or NetBeans will do all of the syntax highlighting for you.


What is computer virvus?

A program like any computer program, intended to alter your configuration in a malicious way, or weaken your security.


Why wont your computer download any videos?

Mine does. Thanks for asking.


What products are available on avg.com?

Avg is a computer software program that protects your computer from viruses. You can scam and check for viruses with this program. You can remove any viruses with this program.


What do a java developer do?

A Java developer helps create a program which can understand any form of computer language. A Java developer tries to make a program that can understand the computer language that is on any computer platform.


Can installing the program Stylish give your computer any viruses?

no


Can you open a CD from a windows computer program with an apple computer?

If the CD contains photos or music they will work on a Mac. If the CD contains a Windows program it will not run on any Apple computer.


How can you prevent a computer virus from attacking your machine?

Any antivirus program can do that.