[Linux-Biella] domanda compilazione

PaulTT paultt a bilug.linux.it
Mar 8 Nov 2011 11:45:24 CET


On 07/11/2011 10:37, zane 說:
> Ho cercato di compilare un prg con gcc, il prg ha tale intestazione:
>
> #include <X11/Xlib.h>
> #include <X11/Xutil.h>
> #include <stdio.h>
> #include <stdlib.h>
> #include <string.h>
>
> indi utilizzo il comando gcc nome -o nome -lX11
>
> ottengo pero':
>
> /home/roberto/
> /EP4X.c: In function ‘main’:
> /home/roberto/earthsin/EP4X.c:263: warning: passing argument 1 of 
> ‘XRefreshKeyboardMapping’ from incompatible pointer type
> /usr/include/X11/Xlib.h:3074: note: expected ‘struct XMappingEvent *’ 
> but argument is of type ‘union XEvent *’
> /home/roberto/earthsin/EP4X.c:270: warning: passing argument 1 of 
> ‘XLookupString’ from incompatible pointer type
> /usr/include/X11/Xutil.h:526: note: expected ‘struct XKeyEvent *’ but 
> argument is of type ‘union XEvent *’
> /tmp/cc3YMJIM.o: In function `main':
> EP4X.c:(.text+0x7f): undefined reference to `eppsds'
> collect2: ld returned 1 exit status
>
> E' un problema di librerie installate o di path?
i warning son poco belli, ma amen, magari sono anche forzature che hanno 
senso

cos'e' sta eppsds?
a naso dovresti aggiungere un -leppsds, ma non so cosa sia, oppure devi 
compilargli insieme qualcos'altro e poi linkarlo
gcc nome1 -o nome1.o -c -lX11
gcc nome2 -o nome2.o -c -lX11
gcc -o nome nome1 nome2


da dove arriva sto sorgente che stai compilando?

cos'e' earthsin? un videogioco porno?

-- 
Stallman's Law: under corporatocracy, every advance in technology
is an opportunity for corporations to reduce, in practice,
the rights of human beings.



Maggiori informazioni sulla lista Linux