Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > Need librarys from Fink lib directory

Need librarys from Fink lib directory
Thread Tools
Dedicated MacNNer
Join Date: Jul 2002
Location: Norway
Status: Offline
Reply With Quote
Sep 22, 2003, 08:12 AM
 
I am trying to compile a modified version of 'Links' here, and it has graphic support, therefore I needed some extra libs. I dl the libs I needed from Fink (libpng, libtiff, libjpg, and so on).

And my question is how to make the build it with libs from /sw/lib ? The ./configure returned that it cannot find libpng, but it is installed. I have tried 'libdir=/sw/lib' and so on.

I am just a basic shell user, trying to learn more. And help would be great
Mac Pro 2 x 2.8 GHz Quad-Core, Nvidia GeForce 8800GT
     
Mac Enthusiast
Join Date: Jul 2002
Location: Leiden, Netherlands
Status: Offline
Reply With Quote
Sep 22, 2003, 10:01 AM
 
Originally posted by Johnny_B:
I am trying to compile a modified version of 'Links' here, and it has graphic support, therefore I needed some extra libs. I dl the libs I needed from Fink (libpng, libtiff, libjpg, and so on).

And my question is how to make the build it with libs from /sw/lib ? The ./configure returned that it cannot find libpng, but it is installed. I have tried 'libdir=/sw/lib' and so on.

I am just a basic shell user, trying to learn more. And help would be great
try something like ./configure --helpwhich should give you someting like :
./configure --with-png-dir=/sw/lib something like that.
     
Dedicated MacNNer
Join Date: May 2003
Location: Santa Barbara
Status: Offline
Reply With Quote
Sep 22, 2003, 10:07 AM
 
Links2 is very cool! Text in a shell, graphics in X.

To compile under tcsh:

setenv CFLAGS="-I/sw/include"
setenv CPPFLAGS="-I/sw/include"
setenv CXXFLAGS="-I/sw/include"
setenv LDFLAGS="-L/sw/lib"
./configure --prefix=/usr/local --with-x --enable-graphics --enable-javascript


You should get a result like this:

Code:
Configuration results: GPM support: NO SSL support: YES Javascript enabled: YES Graphics enabled: YES Graphics drivers: X Image formats: GIF PNG XBM JPEG TIFF xterm for OS/2 support: NO
Then (duh):

make
sudo make install
     
Dedicated MacNNer
Join Date: Jul 2002
Location: Norway
Status: Offline
Reply With Quote
Sep 22, 2003, 12:07 PM
 
Still didn't work man, I added all your "setenv" in the .tcshrc file. He still complains about not finding it.

Code:
checking for png.h... no checking for libpng/png.h... no checking for png_create_info_struct in -lpng... no configure: error: You need libpng to compile Links in graphics mode
I have all this files, they are installed.

And yes, I did a rehash, even closed the Terminal, and open again. Still the same.

Edit: Now it works. I tried it with the "Apple" Terminal, with your tips applied to the .tcshrc file as before. iTerm is the Terminal I use normally, and it uses /bin/tcsh as well. Why doesn't it work here ?
(Last edited by Johnny_B; Sep 22, 2003 at 12:17 PM. )
Mac Pro 2 x 2.8 GHz Quad-Core, Nvidia GeForce 8800GT
     
Dedicated MacNNer
Join Date: Jul 2002
Location: Norway
Status: Offline
Reply With Quote
Sep 22, 2003, 12:25 PM
 
Okay, now I get this when i make.

Code:
gcc -DHAVE_CONFIG_H -I. -I. -I. -I/sw/include -I/usr/X11R6/include -I/sw/include -c font_include.c *** malloc[10124]: error for object 0x15cf4c0: Incorrect checksum for freed object - object was probably modified after being freed; break at szone_error gcc: Internal error: Segmentation fault (program /usr/libexec/gcc/darwin/ppc/cpp-precomp) Please submit a full bug report. See <URL:http://developer.apple.com/bugreporter> for instructions. make: *** [font_include.o] Error 1
Mac Pro 2 x 2.8 GHz Quad-Core, Nvidia GeForce 8800GT
     
Dedicated MacNNer
Join Date: May 2003
Location: Santa Barbara
Status: Offline
Reply With Quote
Sep 22, 2003, 01:58 PM
 
Originally posted by Johnny_B:
Okay, now I get this when i make.
That happened to me once but I don't remember what I did to fix it. Try:
setenv CFLAGS '-I/sw/include -no-cpp-precomp -fsigned-char'
setenv CXXFLAGS '-I/sw/include -no-cpp-precomp -fsigned-char'

Also, what version of GCC are you using? I'm compiling it fine with 3.3.

By the way, are you using the same source I am? This is what I'm using.
(Last edited by bracken; Sep 22, 2003 at 02:41 PM. )
     
Dedicated MacNNer
Join Date: Jul 2002
Location: Norway
Status: Offline
Reply With Quote
Sep 22, 2003, 03:28 PM
 
I have some good news, and some bad. Your setenv didn't work. I found something that looked good (hehe) somewhere on the Fink homepage:

Code:
setenv CFLAGS -no-cpp-precomp setenv CPP 'gcc -E -no-cpp-precomp' setenv CXXCPP 'g++ -E -no-cpp-precomp' setenv CXXFLAGS -no-cpp-precomp setenv LDFLAGS '-L/usr/X11R6/lib -L/sw/lib -bind_at_load' setenv CPPFLAGS '-I/usr/X11R6/include -I/sw/include'
Then I compiled, got this error:

Code:
ld: warning dynamic shared library: /usr/lib/libz.dylib not made a weak library in output with MACOSX_DEPLOYMENT_TARGET environment variable set to: 10.1
But I didn't care, it was build. Then I installed, and I can't see any errors in the app running from X11.

But I am a perfectionist, so I wonder what the error meant. And was my setenv settings any good ? Yours just turned out
error about to many arguments or something.

Edit: I write this from 'links -g', and I forgot to tell you that I use the same Links as you noted. It looks great, it is really fast to go back and forward in history. Draw time could be faster, but it is good. The web should have been more friendly thought. Even most pages renders as I understand them.

Cheers

Edit (again): Is this app nice on older macs ? I mean, I've got Linux to work on some Performas here, but I didn't have so much experience then, and I couldn't fit Xfree86 on the HD. Would Links make a good 'internet-kiosk' ?
(Last edited by Johnny_B; Sep 22, 2003 at 03:44 PM. )
Mac Pro 2 x 2.8 GHz Quad-Core, Nvidia GeForce 8800GT
     
Dedicated MacNNer
Join Date: May 2003
Location: Santa Barbara
Status: Offline
Reply With Quote
Sep 22, 2003, 09:13 PM
 
Originally posted by Johnny_B:
But I am a perfectionist, so I wonder what the error meant. And was my setenv settings any good ?
The error is harmless. Check this out. You can set MACOSX_DEPLOYMENT_TARGET to 10.2 in your cshrc to stop the warnings.

Edit: I write this from 'links -g', and I forgot to tell you that I use the same Links as you noted. It looks great, it is really fast to go back and forward in history. Draw time could be faster, but it is good. The web should have been more friendly thought. Even most pages renders as I understand them.
Yes, I like the history speed. It doesn't have a snazzy Gecko engine but it renders pages amazingly well. You might also want to mess with the network, video, etc. settings to speed things up even more. Also, you could also try compiling it with more optimization. I use the following flags to compile it (for my iBook): -O3 -mcpu=750 -pipe -fsigned-char -mpowerpc-gpopt -mpowerpc-gfxopt -no-cpp-precomp -ffast-math

I love going from one bookmarked page to another very fast with s, arrow key, enter. BAM!

Edit (again): Is this app nice on older macs ? I mean, I've got Linux to work on some Performas here, but I didn't have so much experience then, and I couldn't fit Xfree86 on the HD. Would Links make a good 'internet-kiosk' ?
Yes! That's when I actually started using it. I was using MkLinux on a Performa 6100 and Debian Linux on a PowerMac 8500. It didn't have graphics support then but the text rendering was just fine...I wasn't using X on the 6100 anyways. I remember getting information off the web via those old Macs, a modem, and Links almost as fast I do now with a modern computer and broadband.

Later.
     
Dedicated MacNNer
Join Date: Jul 2002
Location: Norway
Status: Offline
Reply With Quote
Sep 23, 2003, 04:26 AM
 
Yes, I like the history speed. It doesn't have a snazzy Gecko engine but it renders pages amazingly well. You might also want to mess with the network, video, etc. settings to speed things up even more. Also, you could also try compiling it with more optimization. I use the following flags to compile it (for my iBook): -O3 -mcpu=750 -pipe -fsigned-char -mpowerpc-gpopt -mpowerpc-gfxopt -no-cpp-precomp -ffast-math
I didn't understand where to write this. I tried it with the ./configure cmd but that only returned out errors. You have an url or more help on that ?

I am on a G4 867 (the one in my signature), so Links is only a project for fun, but it could be cool to try it out on some of my older machines.

I think there should be a extreme light Linux distro, only containing Links, a compiler, and option for XFree86.

It would be cool to connect to my X11 on my G4, from an old Performa Linux machine or something. And also have Privoxy or something applied to Links.
Mac Pro 2 x 2.8 GHz Quad-Core, Nvidia GeForce 8800GT
     
Dedicated MacNNer
Join Date: May 2003
Location: Santa Barbara
Status: Offline
Reply With Quote
Sep 23, 2003, 01:17 PM
 
Originally posted by Johnny_B:
I didn't understand where to write this. I tried it with the ./configure cmd but that only returned out errors. You have an url or more help on that ?
Set the CFLAGS and CXXFLAGS to this. I have a generic script I use when to run configure. It's something like this:

Code:
#!/bin/sh make clean OPT="-O3 -mcpu=750 -pipe -fsigned-char -mpowerpc-gpopt -mpowerpc-gfxopt -no-cpp-precomp -ffast-math" export CFLAGS="$CFLAGS -I/sw/include $OPT" export CPPFLAGS="$CPPFLAGS -I/sw/include" export CXXFLAGS="$CXXFLAGS -I/sw/include $OPT" export LDFLAGS="$LDFLAGS -L/sw/lib" ./configure --host=powerpc-apple-darwin6.6 --prefix=/usr/local $@
Then I just run it with something like: myconfigure --with-x --enable-graphics --enable-javascript

Change -mcpu to your processor found here.

I think there should be a extreme light Linux distro, only containing Links, a compiler, and option for XFree86.
Ah, view a list for "Minimalist" distributions here.

It would be cool to connect to my X11 on my G4, from an old Performa Linux machine or something. And also have Privoxy or something applied to Links.
That would be cool (and give a life to an otherwise obsolete machine). I'd try it out if I still had my Performa around...
     
Senior User
Join Date: Oct 2000
Location: Midwest
Status: Offline
Reply With Quote
Sep 23, 2003, 06:31 PM
 
Johnny B-

Here is a link to the fink-beginners lailing list. Lots of help there. With the transition to 10.3 and sourceforge struggling with their servers, problems are more frequent.

https://lists.sourceforge.net/lists/listinfo/fink-users.

Also look in the fink-FAQ. There is lots and lots of help there- I would guess 90% plus of all questions to the list could have benn answered in the FAQ.

Craig
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 08:35 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2