LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 06-20-2002, 08:45 PM   #1
Sifvion
Member
 
Registered: Jan 2002
Location: Singapore
Distribution: Slackware
Posts: 250

Rep: Reputation: 30
Compile


Hi guys,

How to i compile the code in linux and use the program in window?

normally i cc files.c

then i run ./files

of cause no problem in linux but if it is run in window then the program wont run.


Thanks in advance
 
Old 06-21-2002, 03:24 AM   #2
Mik
Senior Member
 
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
Well windows is a whole different architecture. So binaries for linux will never run in windows. You will either have to compile the same file on windows to create a windows executable. Or you will have to find a crosscompiler which creates windows binaries.
 
Old 07-19-2002, 09:20 AM   #3
edreddy
Member
 
Registered: Jul 2002
Location: INDIA, Bangalore.
Distribution: Red Hat Enterprise Linux 3.0 Advanced Server
Posts: 34

Rep: Reputation: 15
Sifvion,
when you port an application from one OS to other OS, you can't binaries. all you can do is source code porting maening that take source code and recomplile on the new OS using compiler on the new OS. or otherwise find a cross compiler on linux that produce binaries for windows architecture, still i suspect linking loading problems. best advice is to port source code. many c complilers are available on windows. so there won't be problem if you opt for souce code porting.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I compile? icecream33 Programming 3 12-20-2017 11:49 AM
compile 2.6.13 jupiter3437 Linux - Software 3 09-09-2005 04:09 PM
ntop compile/post-compile problem? tjb Linux - Software 3 12-28-2004 04:22 PM
Cannot compile c davidtsl Programming 8 12-13-2004 01:36 AM
Compile help Twiggy794 Linux - Software 1 12-03-2003 01:53 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration