Linking GDAL and GTK


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Linking GDAL and GTK
# 1  
Old 02-27-2015
Linking GDAL and GTK

Hi all,

I am trying to link the GDAL libraries and GTK. This is my compile line.....not sure why I am getting these errors.

Code:
bash-4.2$ gcc proj.c -o proj $(shell pkg-config --libs gthread-2.0 gtk+-2.0) -I/usr/lib/ -lproj
bash: shell: command not found
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-redhat-linux/4.8.3/../../../libproj.so when searching for -lproj
/usr/bin/ld: skipping incompatible /lib/libproj.so when searching for -lproj
/usr/bin/ld: skipping incompatible /usr/lib/libproj.so when searching for -lproj
/usr/bin/ld: cannot find -lproj
collect2: error: ld returned 1 exit status

I have installed the proj-devel binaries.
Any tips?
Thanks!
Moderator's Comments:
Mod Comment I repeat: Please use CODE (not ICODE) tags for multi-line sample input, output, and code.

Last edited by Don Cragun; 02-27-2015 at 06:14 PM.. Reason: Change ICODE tags to CODE tags.
# 2  
Old 02-27-2015
It means what it says. There's no command called 'shell'. Just do $(pkg-config ...) instead of $(shell pkg-config ...)
 
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Programming

curses.h not found , gtk/gtk.h not found

i have downloaded <libncurses5-dev_5.7+20101128-1_i386.deb> and <ndk++-0.0.1alpha4.tar.bz2> which contains the header files curses.h and gtk/gtk.h .. i have also included them using .. #include "/home/ball/Desktop/Sudoku/project/libncurses5-dev_5.7+20101128-1_i386/usr/include/curses.h" ... (2 Replies)
Discussion started by: upvan111
2 Replies

2. Programming

Database Linking

Hey, i cant seem to find #include<sqlite3> in the libraries, even after installing sqlite3 in linux. how do i solve this problem (1 Reply)
Discussion started by: gregarion
1 Replies

3. UNIX for Dummies Questions & Answers

is linking possible?

how would i link 2 files together? is it the same as copying? (1 Reply)
Discussion started by: trob
1 Replies

4. AIX

linking problem

hello, Is the code compiled under Visual Age C++ Broker (a third party library) - can be used to link against a code compiled from gcc compiler. I have a problem in building xerces in AIX Please reply. Regards, Parthasarathy (1 Reply)
Discussion started by: Parthasarathy
1 Replies

5. Shell Programming and Scripting

Query in linking

Hey guys, i have written the folowing grep command to find an ip address from various files and now i have to find the reverse DNS for it. I wanted to do it via nslookup or host does someone have any clue about how to do it? what i tried was grep -o... (2 Replies)
Discussion started by: snake450
2 Replies

6. Solaris

linking in solaris9

at the end of the compilation in solaris 9. it is showing link error. like..... ld: fatal: library -lgthread-2.0 not found failed to create the binary the library is in /usr/lib and in /usr/local/lib the lib file is present --->libgthread.2.0.so ......etc if i remove... (3 Replies)
Discussion started by: biswajithit
3 Replies

7. Programming

dynamic linking

Hi, Could any one tell me solution for this. i have a library in my /usr/lib and latest in /myhome/lib/ (thay differ functionality symbols my application uses symbols from latest lib). when compile and link my application , every thing goes fine but when running the application ld... (4 Replies)
Discussion started by: Raom
4 Replies

8. Programming

Linking with gcc

Forgive as I am new to the gcc compiler and to linux. I am trying to compile/link a program for the first time and am receiving an error complaining about the crtbegin.o file. I use the -v option and get the following: Using built-in specs. Configured with: ../configure --enable-threads=posix... (1 Reply)
Discussion started by: jbeauchamp
1 Replies

9. Programming

Linking problem while linking to shared library

Hi I'm getting ld: fatal: option -h and building a dynamic executable are incompatible ld: fatal: Flags processing errors When I run ld -shared -L/usr/dt/lib -lDtSvc -o builtin.so Workspace.o after running gcc -fPIC -I/usr/X11R6/include -I/usr/dt/include -c Workspace.c I'm... (6 Replies)
Discussion started by: laho
6 Replies
Login or Register to Ask a Question