From owner-freebsd-questions Sat Jul 13 8:12:55 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ED82C37B400 for ; Sat, 13 Jul 2002 08:12:51 -0700 (PDT) Received: from mail.thundernet.cz (mail.thundernet.cz [62.77.87.114]) by mx1.FreeBSD.org (Postfix) with SMTP id C9ED743E58 for ; Sat, 13 Jul 2002 08:12:50 -0700 (PDT) (envelope-from neuhauser@bellavista.cz) Received: (qmail 11102 invoked from network); 13 Jul 2002 15:12:48 -0000 Received: from unknown (HELO freepuppy.bellavista.cz) (62.168.44.50) by mail.thundernet.cz with SMTP; 13 Jul 2002 15:12:48 -0000 Received: from freepuppy.bellavista.cz (localhost.bellavista.cz [127.0.0.1]) by freepuppy.bellavista.cz (8.12.5/8.11.6) with ESMTP id g6DFClcS002437; Sat, 13 Jul 2002 17:12:48 +0200 (CEST) (envelope-from neuhauser@bellavista.cz) Received: (from roman@localhost) by freepuppy.bellavista.cz (8.12.5/8.12.4/Submit) id g6DFClIv002436; Sat, 13 Jul 2002 17:12:47 +0200 (CEST) X-Authentication-Warning: freepuppy.bellavista.cz: roman set sender to neuhauser@bellavista.cz using -f Date: Sat, 13 Jul 2002 17:12:47 +0200 From: Roman Neuhauser To: Paul Everlund Cc: freebsd-questions@freebsd.org Subject: Re: Include files in /usr/local/include not found Message-ID: <20020713151247.GI322@freepuppy.bellavista.cz> Mail-Followup-To: Paul Everlund , freebsd-questions@freebsd.org References: <3D3013EA.C0904498@cs.umu.se> <20020713140607.GH322@freepuppy.bellavista.cz> <3D303DC6.CD4A5CFB@cs.umu.se> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3D303DC6.CD4A5CFB@cs.umu.se> User-Agent: Mutt/1.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 > Date: Sat, 13 Jul 2002 16:48:38 +0200 > From: Paul Everlund > To: Roman Neuhauser > Cc: freebsd-questions@freebsd.org > Subject: Re: Include files in /usr/local/include not found > > Roman Neuhauser wrote: > > > From: Paul Everlund > > > > > > I got an error while making ./configure for a program. It said it > > > did not find png.h, but it's there as I have png-1.2.4 installed > > > on my system. > > > > > > Wrote the following test program: > > > > > > ---test.c > > > #include > > > > > > int main() > > > { > > > return 0; > > > } > > > > > > Did then compile it with: > > > cc test.c > > > > > > Got the following error: > > > test.c:1: png.h: No such file or directory > > > > > > Did then try to compile it as this: > > > cc -I/usr/local/include test.c > > > > > > This worked! > > > > > > My question is: > > > How do one fix so /usr/local/include is searched automatically? > > > > > > If that can be done, the ./configure should work for the program > > > I'm trying to build. > > > I don't have an answer, but two questions instead (and a hint > > maybe): > > > > what does config.log say about that error? > > configure:5957: checking for PNG support > configure:5963: checking for png.h > configure:5973: cc -E conftest.c >/dev/null 2>conftest.out > configure:5969: png.h: No such file or directory > configure: failed program was: > #line 5968 "configure" > #include "confdefs.h" > #include > configure:5996: checking for png_get_io_ptr in -lpng > configure:6015: gcc -o conftest -g -O2 conftest.c -lpng 1>&5 > /usr/libexec/elf/ld: cannot find -lpng > configure: failed program was: > #line 6004 "configure" > #include "confdefs.h" > /* Override any gcc2 internal prototype to avoid an error. */ > /* We use char because int might match the return type of a gcc2 > builtin and then its argument prototype would still apply. */ > char png_get_io_ptr(); > > int main() { > png_get_io_ptr() > ; return 0; } > configure:6037: checking if PNG package is complete > > > is the software publically available? > > Yep! and what is it? :) > > morale: don't trust configure, and if at all possible, double > > check what it tells you with its guts, and config.log > > I don't trust configure. :-) That's why I wrote my own test program. > Directory /usr/include is searched by gcc automatically, but it seems > /usr/local/include is not. I think that is somehow strange. Locally > installed packages/libraries with header files should be in gcc's > search path. doesn't that configure have a --enable-png[=/path/to/png/prefix] option or sumsuch? -- FreeBSD 4.6-STABLE 5:11PM up 7:25, 6 users, load averages: 0.05, 0.01, 0.00 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message