Date: Sat, 10 Feb 2007 22:46:56 -0800 From: Garrett Cooper <youshi10@u.washington.edu> To: freebsd-hackers@freebsd.org Subject: Re: Finding libraries to link with and autoconf resources? Message-ID: <2D763A31-2BAF-4AD5-A256-273CD37EB7A5@u.washington.edu> In-Reply-To: <17870.42419.779434.735451@bhuda.mired.org> References: <45CE8BEC.7050404@u.washington.edu> <17870.42419.779434.735451@bhuda.mired.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Feb 10, 2007, at 9:12 PM, Mike Meyer wrote: > In <45CE8BEC.7050404@u.washington.edu>, Garrett Cooper > <youshi10@u.washington.edu> typed: >> Hello, >> This is my first attempt at porting an application, so please >> bear with me. >> I'm trying to port tvtime from Linux to FreeBSD and it's failing >> during >> the configure stage (claims it can't find -lpng when running a link >> test). I know I should probably use the Linux libpng library but I'm >> trying to make the application as native as possible with FreeBSD. >> Anyhow though, I was wondering what directories I should typically >> search when using -L for searching for the png libraries, for >> instance >> (/usr/lib.. ?). > > libpng isn't part of the base system, it's in the ports tree in > graphics/png. Assuming you've got that installed, then use > $LOCALBASE/bin/libpng-config to get the appropriate options. > > If you're creating a port, add "png.5:${PORTSDIR}/graphics/png" to > LIB_DEPENDS. > > <mike Well, what I'm trying to do is first compile the program (if possible), then determine what needs to be done to port tvtime to FreeBSD natively, as best possible (tvtime uses Video4Linux for a lot of its stuff). I just like that program because of the clean interface and simplicity of use. Anyhow, I looked for png under /usr/local and I came up with the following: [gcooper@sprsd /usr/local/lib]$ ls *png* libpng.a libpng.so libpng.so.5 However the original configure script fails trying to find the lib under /usr/local/include (all that's there are .h files). That's why I asked the two-fold question about finding libraries with autoconf scripts and autoconf resources. I know I have to change the script somehow or pass in the right arguments, so that's why I was asking. Are there any global scripts or options to pass to autoconf that sets the -L option for gcc properly? -Garrett
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2D763A31-2BAF-4AD5-A256-273CD37EB7A5>