[uClinux-dev] Build problem: select(), FD_SET(), etc.

Paul Carpenter paul.carpenter at eng.nciaccess.com
Mon Nov 19 09:42:04 EST 2001


Thanks for the reply.  I cannot find a select.h in my uClinux distribution.
Am I misunderstanding something here?


> Hi Paul,
> The last time I did this, I found that for uClinux, you need to
> include /sys/select.
>
> Pat Adamo
> Dir of Access Ctl Eng,
> Ademco Group
>
>
> Paul Carpenter wrote:
>
> > I am using Lineo's 2.0.38pre7 distribution to build a TCP/IP server app
> > that uses the select() system call.  The application builds and runs
> > fine on my RH7.l system.  However, the build fails for my M5272C3
> > target.  It seems that it cannot find the macros for FD_ZERO(),
> > FD_SET(), etc.  They ought to be in the header types.h.  Here is a
> > partial listing of my build output:
> >
> > make[2]: Entering directory `/opt/uClinux-coldfire/user/tstserver'
> > /opt/uClinux-coldfire/tools/m68k-elf-ld --sort-common -r
> > /opt/uClinux-coldfire/lib/libc/crt0.o -o wserver.elf wserver.o
> > --start-group /opt/uClinux-coldfire/lib/libc/libc.a
> > /opt/uClinux-coldfire/tools/gcc-lib/libgcc.a --end-group
> > mv wserver.elf .wserver.elf; /opt/uClinux-coldfire/tools/m68k-elf-ld -T
> > /opt/uClinux-coldfire/user/arch/coldfire/user.ld -Ur -o wserver.elf
> > .wserver.elf; /opt/uClinux-coldfire/tools/m68k-elf-ld -T
> > /opt/uClinux-coldfire/user/arch/coldfire/user.ld -o wserver.gdb
> > .wserver.elf; rm -f .wserver.elf; /opt/uClinux-coldfire/tools/elf2flt
> > -o wserver -r wserver.elf wserver.gdb
> > .wserver.elf: In function `main':
> > .wserver.elf(.text+0x1fe): undefined reference to `FD_ZERO'
> > .wserver.elf(.text+0x226): undefined reference to `FD_SET'
> > .wserver.elf(.text+0x280): undefined reference to `FD_ISSET'
> > Can't open wserver.gdb
> > make[2]: *** [wserver] Error 1
> > make[2]: Leaving directory `/opt/uClinux-coldfire/user/tstserver'
> > make[1]: *** [all] Error 2
> > make[1]: Leaving directory `/opt/uClinux-coldfire/user'
> > make: *** [subdirs] Error 1
> >
> > Here is what I include in my source code:
> >
> > /* wserver.c */
> > #include <sys/types.h>
> > #include <sys/socket.h>
> > #include <stdio.h>
> > #include <string.h>
> > #include <stdlib.h>
> > #include <netinet/in.h>
> > #include <signal.h>
> > #include <arpa/inet.h>
> > #include <unistd.h>
> > #include <fcntl.h>
> > #include <termios.h>
> >
> > Any help would be greatly appreciated.  Thanks!
> >
> > Paul Carpenter
> > Northern Computers
> >
> > This message resent by the uclinux-dev at uclinux.org list server
http://www.uClinux.org/

This message resent by the uclinux-dev at uclinux.org list server
http://www.uClinux.org/

This message resent by the uclinux-dev at uclinux.org list server http://www.uClinux.org/



More information about the uClinux-dev mailing list