thanks for your quick reply. I still get the same error which is the following
bobs-imac:connectivity roberto$ gcc igraph_test.c -I/opt/local/include/igraph -L/opt/local/lib -ligraph -o igraph_test
igraph_test.c:1:20: error: igraph.h: No such file or directory
igraph_test.c: In function ‘main’:
igraph_test.c:5: error: ‘igraph_real_t’ undeclared (first use in this function)
igraph_test.c:5: error: (Each undeclared identifier is reported only once
igraph_test.c:5: error: for each function it appears in.)
igraph_test.c:5: error: syntax error before ‘diameter’
igraph_test.c:6: error: ‘igraph_t’ undeclared (first use in this function)
igraph_test.c:7: error: ‘graph’ undeclared (first use in this function)
igraph_test.c:7: error: ‘IGRAPH_ERDOS_RENYI_GNP’ undeclared (first use in this function)
igraph_test.c:8: error: ‘IGRAPH_UNDIRECTED’ undeclared (first use in this function)
igraph_test.c:8: error: ‘IGRAPH_NO_LOOPS’ undeclared (first use in this function)
igraph_test.c:9: error: ‘diameter’ undeclared (first use in this function)
igraph_test.c:10: warning: incompatible implicit declaration of built-in function ‘printf’
bobs-imac:connectivity roberto$ gcc -o igraph_test igraph_test.c $(pkg-config --libs --cflags igraph)
Package igraph was not found in the pkg-config search path.
Perhaps you should add the directory containing `igraph.pc'
to the PKG_CONFIG_PATH environment variable
No package 'igraph' found
igraph_test.c:1:20: error: igraph.h: No such file or directory
igraph_test.c: In function ‘main’:
igraph_test.c:5: error: ‘igraph_real_t’ undeclared (first use in this function)
igraph_test.c:5: error: (Each undeclared identifier is reported only once
igraph_test.c:5: error: for each function it appears in.)
igraph_test.c:5: error: syntax error before ‘diameter’
igraph_test.c:6: error: ‘igraph_t’ undeclared (first use in this function)
igraph_test.c:7: error: ‘graph’ undeclared (first use in this function)
igraph_test.c:7: error: ‘IGRAPH_ERDOS_RENYI_GNP’ undeclared (first use in this function)
igraph_test.c:8: error: ‘IGRAPH_UNDIRECTED’ undeclared (first use in this function)
igraph_test.c:8: error: ‘IGRAPH_NO_LOOPS’ undeclared (first use in this function)
igraph_test.c:9: error: ‘diameter’ undeclared (first use in this function)
igraph_test.c:10: warning: incompatible implicit declaration of built-in function ‘printf’
bobs-imac:connectivity roberto$
On Mon, Nov 23, 2009 at 5:11 PM, zhengjun chen
<zhjchen.sa@gmail.com> wrote:
Hi,
I also tried to install igraph for mac today. In the beginning, I also met your problem.
I chose another way to compile:
gcc -o igraph_test igraph_test.c $(pkg-config --libs --cflags igraph)
As for your form of compile, I think you can try:
gcc igraph_test.c -I/opt/local/include/igraph -L/opt/local/lib -ligraph -o igraph_test
On Mon, Nov 23, 2009 at 7:50 PM, Roberto Pagliari
<address@hidden> wrote:
Hi All,
I tried to install igraph for mac (the C package) but I'm unable to find the library.
I get the following error
bobs-imac:connectivity roberto$ gcc igraph_test.c -I/usr/local/igraph -L/usr/local/lib -ligraph -o igraph_test
igraph_test.c:1:20: error: igraph.h: No such file or directory
igraph_test.c: In function ‘main’:
igraph_test.c:5: error: ‘igraph_real_t’ undeclared (first use in this function)
igraph_test.c:5: error: (Each undeclared identifier is reported only once
igraph_test.c:5: error: for each function it appears in.)
igraph_test.c:5: error: syntax error before ‘diameter’
igraph_test.c:6: error: ‘igraph_t’ undeclared (first use in this function)
igraph_test.c:7: error: ‘graph’ undeclared (first use in this function)
igraph_test.c:7: error: ‘IGRAPH_ERDOS_RENYI_GNP’ undeclared (first use in this function)
igraph_test.c:8: error: ‘IGRAPH_UNDIRECTED’ undeclared (first use in this function)
igraph_test.c:8: error: ‘IGRAPH_NO_LOOPS’ undeclared (first use in this function)
igraph_test.c:9: error: ‘diameter’ undeclared (first use in this function)
igraph_test.c:10: warning: incompatible implicit declaration of built-in function ‘printf’
bobs-imac:connectivity roberto$ pkg-config --libs --cflags igraph
Package igraph was not found in the pkg-config search path.
Perhaps you should add the directory containing `igraph.pc'
to the PKG_CONFIG_PATH environment variable
No package 'igraph' found
bobs-imac:connectivity roberto$ pkg-config --libs --cflags igraph.pc
Failed to open 'igraph.pc': No such file or directory
No package 'igraph.pc' found
Does anybody know how to fix it?
Thanks,
Bob
_______________________________________________
igraph-help mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/igraph-help
--
Thanks
zhengjun
Graduate research assistant
Dept of Computer Science and Engineering
Lehigh University
_______________________________________________
igraph-help mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/igraph-help