From owner-freebsd-questions Wed Jun 26 12: 7:38 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mail.smartrafficenter.org (mail.smartrafficenter.org [207.14.56.3]) by hub.freebsd.org (Postfix) with SMTP id B3E1937BE58 for ; Wed, 26 Jun 2002 12:05:58 -0700 (PDT) Received: (qmail 43571 invoked by uid 1000); 26 Jun 2002 19:05:58 -0000 Date: Wed, 26 Jun 2002 15:05:58 -0400 From: "Kevin A. Pieckiel" To: freebsd-questions@freebsd.org Subject: gcc with -pthread links to libc? Warnings on output... Message-ID: <20020626150558.A36720@pacer.dmz.smartrafficenter.org> Mail-Followup-To: freebsd-questions@freebsd.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7JfCtLOvnd9MIVvH" Content-Disposition: inline User-Agent: Mutt/1.2.5.1i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --7JfCtLOvnd9MIVvH Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I'm developing a threaded package using standard pthread symantics. My gcc compile line includes -pthread to link in libc_r instead of libc, but I gt these warning messages: /usr/lib/libc.so.4: WARNING! setkey(3) not present in the system! /usr/lib/libc.so.4: warning: this program uses gets(), which is unsafe. /usr/lib/libc.so.4: warning: mktemp() possibly used unsafely; consider usin= g mkstemp() /usr/lib/libc.so.4: WARNING! des_setkey(3) not present in the system! /usr/lib/libc.so.4: WARNING! encrypt(3) not present in the system! /usr/lib/libc.so.4: warning: tmpnam() possibly used unsafely; consider usin= g mkstemp() /usr/lib/libc.so.4: warning: this program uses f_prealloc(), which is not r= ecommended. /usr/lib/libc.so.4: WARNING! des_cipher(3) not present in the system! /usr/lib/libc.so.4: warning: tempnam() possibly used unsafely; consider usi= ng mkstemp() First, I thought -pthread links libc_r instead of libc. Why is this showing up here? Second, my program doesn't even use setkey, gets, mktemp, des_setkey, encrypt, tmpnam, f_prealloc, des_cipher, nor tempnam. From where are these references coming? The funny thing is, I've developed apps before that use pthreads, and I didn't get these warnings. I don't know what is different. They were much smaller projects, and I no longer have the source code to reference. How do I fix these warnings? I'm running FBSD 4.5-Stable (cvs'd sources mid Februrary). Gcc version is 2.95.3. Language is C. Don't know what other info would be of use, but will be glad to answer questions. Thanks, Kevin --=20 This message was signed by GnuPG. For my PGP public key, send a blank = =20 email to kpieckiel-pgp@smartrafficenter.org and it will be sent to you. = =20 You may also get my key from certserver.pgp.com; my ID is 0x79FC593E. My current key will expire on 21 August 2002. --7JfCtLOvnd9MIVvH Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (FreeBSD) iD8DBQE9GhCTdJoPN3n8WT4RAjWAAJ93PwbvmJZSoLfob6OWFqPn8jDhLwCgvY2E 8kFeR2BCfa0iGy3mSObrmiE= =SVTu -----END PGP SIGNATURE----- --7JfCtLOvnd9MIVvH-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message