LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   MinGW compile issue on windows (https://www.linuxquestions.org/questions/programming-9/mingw-compile-issue-on-windows-4175480332/)

PoleStar 10-10-2013 02:56 PM

MinGW compile issue on windows
 
Hello,

I installed MinGw on windows computer, and tried to test it with a "hello" code.
Compiler don't complain. But it also does not create any execute able file.

Here is the code and out put.

Code:

#include<stdio.h>

main(){

        printf("hello \n");


}

Out put:

Code:

PS C:\Users\\Desktop\test> gcc hello.c -o hello
PS C:\Users\\Desktop\test>
PS C:\Users\Desktop\test>
PS C:\Users\\Desktop\test> dir


    Directory: C:\Users\\Desktop\test


Mode                LastWriteTime    Length Name
----                -------------    ------ ----
-a---        10/10/2013  2:45 PM        62 hello.c


PS C:\Users\\Desktop\test>


John VV 10-10-2013 04:12 PM

the desktop on windows is a link
and it really is not a real folder ( you do not even use the desktop folder using VisualStudio )
on win 7 it is a royal mess of "libraries"and redirects

build software for MinGW in the mingw/msys setup
C://Msys
C://Mingw
C://Mingw/bin
C://Mingw/lib
C://Mingw/src
C://Mingw/src/ProgramName
-- ie
C://Mingw/src/HelloWorld

( using --prefix=C://Mingw )


All times are GMT -5. The time now is 09:34 AM.