Recent

Author Topic: Mac OS X x86 with Lazarus  (Read 15243 times)

JopieK

  • New Member
  • *
  • Posts: 15
    • http://www.legotrein.tk
Mac OS X x86 with Lazarus
« on: April 04, 2006, 11:10:07 am »
I'm trying to install FPC/Lazarus on Mac OS X with an Intel processor (on a Mac Book Pro). I get some problems already with installing FPC, so I thought it to be handy to use the tutorial on:
http://wiki.lazarus.freepascal.org/index.php/Installing_Lazarus#Installing_Lazarus_under_Mac_OS_X

In the http://www.de.freepascal.org/lazarus/ page I see Mac OS X i386 entries without the link available. Is there any info on when we might expect these and might the current issues with FPC and Lazarus have to do with Rosetta or should I in the meantime just use the PPC version and just reinstall everything using that tutorial?

Vincent Snijders

  • Administrator
  • Hero Member
  • *
  • Posts: 2661
    • My Lazarus wiki user page
Re: Mac OS X x86 with Lazarus
« Reply #1 on: April 04, 2006, 11:47:53 am »
Quote from: "JopieK"
In the http://www.de.freepascal.org/lazarus/ page I see Mac OS X i386 entries without the link available. Is there any info on when we might expect these and might the current issues with FPC and Lazarus have to do with Rosetta or should I in the meantime just use the PPC version and just reinstall everything using that tutorial?


I am working on creating snapshots for i386-darwin. Note that this port is less than a month old and hardly tested. It also requires the development version of fpc (2.1.1).

I hope to upload snapshots for i386-darwin before the end of the week, no guarantees though.

I appreciate any feedback, because I cannot run them, since I only have ssh (console) access to the i386-darwin build machine.

LucaN

  • Newbie
  • Posts: 1
RE: Re: Mac OS X x86 with Lazarus
« Reply #2 on: May 18, 2006, 07:31:53 pm »
Hi!

I have an Intel iMac and i'll be glad to help.

I installed the fpc, fpcsrc & lazarus snapshots found at <http://www.de.freepascal.org/lazarus/>, added all the needed libraries (GTK+, ...) but now (Running it froom the Xterm or i get a "Gtk-WARNING **: cannot open display:" :]) i'm getting a "The Free Pascal Compiler (filename: ppc386) was not found. It is recommended that you install fpc" error...

Maybe it's only a PATH variable error, i'll check again within a couple of hours...


Cheers!
Luca

Anonymous

  • Guest
RE: Re: Mac OS X x86 with Lazarus
« Reply #3 on: May 26, 2006, 08:43:30 pm »
Hello-

I also have a MacBook Pro. I found it easy to install X11, but was not able to install Fink - the installer appears to want to find PPC libraries. Can anyone give a step-by-step install guide for Lazarus on OSX Intel? I was able to install Lazarus on a PPC OSX system by following Phil H.'s simple instructions at
 http://www.lazarus.freepascal.org/index.php?name=PNphpBB2&file=viewtopic&p=8599
However, on the Intel Mac, I do not know how to install the required GTK libraries.

Anonymous

  • Guest
Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #4 on: May 26, 2006, 09:35:26 pm »
Quote from: "Anonymous"

I also have a MacBook Pro. I found it easy to install X11, but was not able to install Fink - the installer appears to want to find PPC libraries.


Are you using the PPC fink? If so, that's probably why it's trying to install PPC libraries. It's not clear if an Intel version of fink is available yet. See this link:

http://fink.sourceforge.net/news/index.php

Can someone who's actually using Lazarus on Mac Intel please clarify this for us?

pch

  • Jr. Member
  • **
  • Posts: 51
    • http://ap-i.net
RE: Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #5 on: May 28, 2006, 07:27:50 pm »
It is working fine for me, I am very happy my whole application can now run on OS X Intel.

For the installation I follow http://wiki.lazarus.freepascal.org/index.php/Installing_Lazarus .
The only problem is with Fink and GTK, it is very important to not install any PPC part.
I just note here some temporary differences until binary Intel package are available from Fink.

Start by installing Apple X11 and Xcode.

For Fink itself follow the instruction at http://fink.sourceforge.net/news/index.php ( search the page for "Preliminary version of Fink on Intel"). In short get the Fink tar, run bootstrap.sh, run fink selfupdate.
Upfate your profile as mentioned.

To install GTk do not use apt-get because there is no binary package at this time. Instead run:
fink install gdk-pixbuf gtk+ gtk+-data gtk+-shlibs gtk-doc gtk-engines
This download the source package, compile them and install.

Then install FPC and Lazarus using the daily snapshot, there is no problem here.

Patrick

Anonymous

  • Guest
RE: Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #6 on: June 15, 2006, 08:23:56 pm »
For those (like me) that got a little confuse; fink can be found in /sw/bin (I know the info is out there - just took me a while to figure it out)

Phil

  • Hero Member
  • *****
  • Posts: 2737
Re: RE: Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #7 on: June 18, 2006, 05:43:38 pm »
Quote from: "Anonymous"
For those (like me) that got a little confuse; fink can be found in /sw/bin (I know the info is out there - just took me a while to figure it out)


The fink installer tries to set the path to /sw/bin but in my experience it fails at this sometimes. To run either fink or apt-get, it's a good idea to include the /sw/bin/ path to them.

With PowerPC, you probably want to use apt-get so it installs the binary GTK packages. With Intel, you currently have to use fink in order to download and compile the packages' source.

Note that until binary packages are available for Intel, if you want to distribute a GUI app you create with Laz to other Intel Macs, you'll need to have the developer tools installed on those other Macs (in addition to X11) in order for fink to be able to compile the GTK packages! On PowerPC Macs, your users don't have to have the developer tools installed since apt-get will download only the binary packages and no compilation is necessary.

I find the whole fink process extremely confusing and error prone (plus fink and fink commander appear to be buggy). This points up the importance of one day having the native Carbon widgetset both for compiling Lazarus IDE and for compiling our GUI apps in Laz so we can drop this whole X11/fink/GTK requirement for OS X!

If we developers have problems with fink, imagine what kind of problems your users will have if you ask them to install fink and GTK themselves.

Marc

  • Administrator
  • Hero Member
  • *
  • Posts: 2583
Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #8 on: June 19, 2006, 11:01:13 am »
Quote from: "LucaN"
Hi!

I have an Intel iMac and i'll be glad to help.

I installed the fpc, fpcsrc & lazarus snapshots found at <http://www.de.freepascal.org/lazarus/>, added all the needed libraries (GTK+, ...) but now (Running it froom the Xterm or i get a "Gtk-WARNING **: cannot open display:" :]) i'm getting a "The Free Pascal Compiler (filename: ppc386) was not found. It is recommended that you install fpc" error...

Maybe it's only a PATH variable error, i'll check again within a couple of hours...


Cheers!
Luca


make sure the DISPLAY environment variable is set (localhost:0)
Usually it is if you are running a xterm.
What you also can do is running alzarus with --display=localhost:0 as option
//--
{$I stdsig.inc}
//-I still can't read someones mind
//-Bugs reported here will be forgotten. Use the bug tracker

Anonymous

  • Guest
RE: Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #9 on: June 22, 2006, 10:36:53 pm »
I noted that you can now get a binary download of Fink. I was able to install Lazarus and build a large application (that Lazarus can also compile to OSX PPC, Windows, Linux). The program compiled the first time - I was really impressed. Here is what I did

I essentially followed the recipe Phil suggested for OSX PPC at
 http://www.lazarus.freepascal.org/index.php?name=PNphpBB2&file=viewtopic&t=1289

Phil

  • Hero Member
  • *****
  • Posts: 2737
Re: RE: Re: RE: Re: Mac OS X x86 with Lazarus
« Reply #10 on: June 22, 2006, 11:18:32 pm »
Quote from: "Anonymous"
I noted that you can now get a binary download of Fink.


Thanks for the update.

Expanded instructions for installing, as well as a lot more tips, is now available on the Lazarus wiki:

http://wiki.lazarus.freepascal.org/index.php/OS_X_Programming_Tips

 

TinyPortal © 2005-2018