RE: [lazarus] Building Lazarus (first time ever) on Mac OS X 10.5 (Leopard) fails - fink's apt-get sources has no glib or other packages.

2007-11-30 Thread Hess, Philip J
Hi Warren,

The Lazarus snapshots for OS X include an app bundle (lazarus.app) but
the Lazarus executable is still compiled for and dependent on GTK so you
can't launch from it the bundle until you've recompiled the IDE for the
Carbon widgetset.

See this link for more information, including an uninstall script that
gives the location of all FPC and Lazarus files installed by the
snapshot installers:

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

The Lazarus folder is read-only. To get to it with Finder, choose Go |
Go to Folder and enter /usr, then navigate to /usr/local/share. Damien's
script should work to recompile the IDE because it changes the ownership
of the Lazarus folder to make it writeable. You can also do what I do
which is simply to use Finder to copy the Lazarus folder into my user
area and recompile it there.

I would hope that within a couple months or so we'll have a stable,
functional Carbon-based IDE and we can just forget all the GTK, X11
stuff for OS X and have a normal app bundle that's ready to go out of
the box.

Thanks.

-Phil


-Original Message-
From: Warren Postma [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 29, 2007 9:11 PM
To: lazarus@miraclec.com
Subject: [lazarus] Building Lazarus (first time ever) on Mac OS X 10.5
(Leopard) fails - fink's apt-get sources has no glib or other packages.

I couldn't get the pre-built binary of Lazarus to run on Mac OS X 10.5 
(Leopard). First the installer put the files somewhere invisible to the 
finder, so I couldn't start up by clicking any mac App icon. Secondly, 
even when I found lazarus.app and did "open lazarus.app" from terminal, 
it crashed saying it can't find some resources. I tried all different 
kinds of paths and working folders with no luck.

So then I tried to install from subversion.  I got the svn stuff checked

out and it builds up until it dies linking, missing library glib.  

So then I tried to get fink onto my system, because I realized I need 
glib.   Fink built and installed, and apt-get is there and works but 
there's no glib package in apt-get.
Do I have to edit my sources.list or something, to find whatever 
fink-repository it is that contains the glib packages?  I had to build 
fink using the bootstrap from source shell script
because according to the finkmeisters,  the binary fink releases 
available on the web don't work with leopard.

Ain't it fun being on the bleeding edge?

Cheers.

Warren

P.S. The instructions for building that I was using were here:
http://wiki.lazarus.freepascal.org/Installing_Lazarus_on_MacOS_X


_
 To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives

_
 To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives


Re: [lazarus] Building Lazarus (first time ever) on Mac OS X 10.5 (Leopard) fails - fink's apt-get sources has no glib or other packages.

2007-11-30 Thread Damien Gerard


On Nov 30, 2007, at 3:11 AM, Warren Postma wrote:

I couldn't get the pre-built binary of Lazarus to run on Mac OS X  
10.5 (Leopard). First the installer put the files somewhere  
invisible to the finder, so I couldn't start up by clicking any mac  
App icon. Secondly, even when I found lazarus.app and did "open  
lazarus.app" from terminal, it crashed saying it can't find some  
resources. I tried all different kinds of paths and working folders  
with no luck.


So then I tried to install from subversion.  I got the svn stuff  
checked out and it builds up until it dies linking, missing library  
glib.
So then I tried to get fink onto my system, because I realized I  
need glib.   Fink built and installed, and apt-get is there and  
works but there's no glib package in apt-get.
Do I have to edit my sources.list or something, to find whatever  
fink-repository it is that contains the glib packages?  I had to  
build fink using the bootstrap from source shell script
because according to the finkmeisters,  the binary fink releases  
available on the web don't work with leopard.


Ain't it fun being on the bleeding edge?




Fink does not work well on Leopard (not at all for me...). You can use  
MacPorts and personally I prefer it. It is more up-to-date. I always  
had problems when using Fink as far I remember.
The available snapshots work well under leopard in GTK1. However the  
app produces from time to time a bad request to X11 and directly quit  
(and afaik you cannot produce a backtrace). Under GTK2 as previously  
posted images are strangely displayed. I have difficulties to compile  
lazarus using QT. The best is the carbon widgetset, but it is still  
quite difficult to use the code editor.


With MacPorts, you nearly only of this :
# sudo port install gdk-pixbuf
# sudo port install gdk2

In the same time I suggest you to install coreutils.

You can use both, Fink is by default in /sw and MacPorts in /opt/. But  
it is better to remove (or move) the /sw folder and to replace it with  
a symbolic link to opt like this :

# cd /
# sudo ln -s /opt sw


To get the carbon Interface, you can use this : 
http://wiki.lazarus.freepascal.org/Carbon_Interface
But I prefer the command line :
# make clean all LCL_PLATFORM=carbon FPC=fpc OPT="-k'-framework' - 
k'carbon'"


To get the GTK2 Interface, use this : 
http://wiki.lazarus.freepascal.org/GTK2_Interface

Here is a script I made to fast recompile Lazarus (changes are  
necessary / I only use snapshots for now under OS X):




#!/bin/sh

path="/usr/local/share/lazarus"

sudo chown -R milipili:wheel "${path}"
cd "${path}"

widgetset="$1"

if [ "$widgetset" = 'gtk2' ]; then
make clean all LCL_PLATFORM=gtk2 FPC=fpc OPT="@/Users/milipili/ 
Projects/lazarus/gimplib.cfg"

exit 0
fi
if [ "$widgetset" = 'gtk' -o "$widgetset" = 'gtk1' ]; then
make clean all LCL_PLATFORM=gtk FPC=fpc
exit 0
fi
if [ "$widgetset" = 'carbon' ]; then
make clean all LCL_PLATFORM=carbon FPC=fpc OPT="-k'-framework' - 
k'carbon'"

exit 0
fi

echo " Specify the widgetset : gtk, gtk2, carbon"


--
Damien Gerard
[EMAIL PROTECTED]



_
To unsubscribe: mail [EMAIL PROTECTED] with
   "unsubscribe" as the Subject
  archives at http://www.lazarus.freepascal.org/mailarchives