Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22113

About OpenMP with gnu gcc

$
0
0

I have Windows 8 64bit operating system.

I wanted to experiment with following C code for OpenMP functionality:

hello.c program

#include <stdio.h>#include <stdlib.h>#include<omp.h>int main(){    #pragma omp parallel    printf("Hello world!\n");    return 0;}

While I tried to run the program from command prompt using:gcc -fopenmp hello.c

I got the following error:

c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: cannot find -lpthreadcollect2.exe: error: ld returned 1 exit status

I have C:\MinGW in my path with gcc 4.8.1.

What is it I am missing?


Viewing all articles
Browse latest Browse all 22113

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>