From owner-freebsd-questions Wed Nov 1 16:47: 7 2000 Delivered-To: freebsd-questions@freebsd.org Received: from trauco.colomsat.net.co (trauco.colomsat.net.co [200.13.195.2]) by hub.freebsd.org (Postfix) with ESMTP id 264FA37B4CF; Wed, 1 Nov 2000 16:46:59 -0800 (PST) Received: from yahoo.com (200.13.215.149) by trauco.colomsat.net.co (NPlex 4.0.068) id 3A006DB500003322; Wed, 1 Nov 2000 19:40:47 -0500 Message-ID: <3A00BA20.4E581E6E@yahoo.com> Date: Wed, 01 Nov 2000 19:49:36 -0500 From: "Yonny Cardenas B." Organization: Ingenieria Integral Ltda. X-Mailer: Mozilla 4.61 [en] (Win98; I) X-Accept-Language: en MIME-Version: 1.0 To: questions@FreeBSD.ORG, freebsd-net@FreeBSD.ORG Subject: Implicit declaration of function Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi I have a error when compile my kernel. I don't understand the message "implicit declaration of function `socket' ". The directive #include has declaration of function socket. I don't know if I can do this because the kernel and userland address spaces are sort seperate, and I must use copyin/copyout. The function _sys_create_socket is called for a system call "CreateConection()" that I'm makeing, so CreateConection() and socket() are system calls, żIs this a problem? Thanks for your help. cc -c -O -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-pr ototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -ansi -nostdinc -I- -I. -I../.. -I/usr/include -D_KERNEL -include opt_global.h -elf -mpreferred- stack-boundary=2 ../../kern/rtp/rtp_unix.c In file included from /usr/include/sysdep.h:39, from ../../kern/rtp/rtp_unix.c:11: /usr/include/math.h:175: warning: function declaration isn't a prototype /usr/include/math.h:258: warning: function declaration isn't a prototype ../../kern/rtp/rtp_unix.c: In function `_sys_create_socket': ../../kern/rtp/rtp_unix.c:29: warning: implicit declaration of function `socket' ../../kern/rtp/rtp_unix.c: In function `_sys_connect_socket': ../../kern/rtp/rtp_unix.c:52: warning: implicit declaration of function `connect' The funtion _sys_create_socket in rtp_unix.c file are: #include /* ... */ int _sys_create_socket ( ){ /*... */ int sd ; sd = socket(AF_INET, 1, 0 ) /* ... */ } +------------------------------------------------------------------+ | YONNY CARDENAS B. Apartado Aereo 22828 | | Systems Engineer Santafe de Bogota D.C. | | Colombia - South America | | Student M.Sc. Tels: +571 3451554 +571 3465454 | | UNIVERSIDAD DE LOS ANDES mailto: y-carden@uniandes.edu.co | | ycardena@computer.org | | ICQ #: 46933750 | +------------------------------------------------------------------+ UNIX is BSD, and FreeBSD is an advanced 4.4BSD To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message