[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Help compiling Xlib



I tried all sorts of combinations but don't seem to be
able to get it going. What is the name of the Xlib
library files? Here are the things I tried. Any other
advice?

Thanks.



gcc test1.c -lX11
test1.c: In function `main':
test1.c:18: warning: return type of `main' is not
`int'
/usr/bin/ld: cannot find -lX11
collect2: ld returned 1 exit status

gcc test1.c -lxlib6g
test1.c: In function `main':
test1.c:18: warning: return type of `main' is not
`int'
/usr/bin/ld: cannot find -lxlib6g
collect2: ld returned 1 exit status

gcc test1.c -l/usr/X11R6/lib
test1.c: In function `main':
test1.c:18: warning: return type of `main' is not
`int'
/usr/bin/ld: cannot find -l/usr/X11R6/lib
collect2: ld returned 1 exit status

gcc test1.c -l/usr/X11R6/lib/libX11.so.6.1
test1.c: In function `main':
test1.c:18: warning: return type of `main' is not
`int'
/usr/bin/ld: cannot find
-l/usr/X11R6/lib/libX11.so.6.1
collect2: ld returned 1 exit status

gcc test1.c -llibX11                      
test1.c: In function `main':
test1.c:18: warning: return type of `main' is not
`int'
/usr/bin/ld: cannot find -llibX11
collect2: ld returned 1 exit status

gcc test1.c -llibX11.so.6.1
test1.c: In function `main':
test1.c:18: warning: return type of `main' is not
`int'
/usr/bin/ld: cannot find -llibX11.so.6.1
collect2: ld returned 1 exit sta


--- "Pavel M. Penev" <kal_pav@sz.techno-link.com>
wrote:
> 
> 
> On Mon, 17 Jul 2000, Dinesh Nadarajah wrote:
> 
> > I am trying to compile a simple X application but
> I
> > keep getting the folloeing error:
> > 
> > gcc -g -o testapp test1.c -lX11
> > 
> > /usr/bin/ld: cannot find -lX11
> > collect2: ld returned 1 exit status
> > 
> > Any suggestions? What are the Xlib libraries
> called
> > under Linux.  Thanks.
> > 
> > -D
> > 
> 
> xlib6g installs its libraries under /usr/X11R6/lib/
> (try dpkg --largemem
> -L xlib6g) and are trying to have names compatible
> with all other
> distributions. I think the problem is that xlib6g
> does not make
> /usr/lib/X11 to be a symlink to /usr/lib/X11R6 where
> ld likes to look for
> the libraries. Either make the symlink, or give ld
> (gcc will pass
> appropriate arguments to ld) a "-L/usr/X11R6/lib"
> switch.
> 
> This is for now,
> Pavel M. Penev
> 
> 
> 
> -- 
> Unsubscribe?  mail -s unsubscribe
> debian-user-request@lists.debian.org < /dev/null
> 


__________________________________________________
Do You Yahoo!?
Get Yahoo! Mail ? Free email you can access from anywhere!
http://mail.yahoo.com/



Reply to: