Mattias Gaertner wrote:
On Sun, 17 Sep 2006 16:15:43 +0700
Colin Lehmann <[EMAIL PROTECTED]> wrote:
Mattias Gaertner wrote:
[...]
Sorry, for the misunderstanding. I will try to explain a few things:
A program is first compiled and then linked.
Your first reported error was that unit glib not found. This was
a compiler error. Your fpc was not installed properly.
Your second error was -lglib not found. This is a *linker* error and
this typically means the compilation worked, so your FPC and
Lazarus is completely there. Only some of the external libraries
were missing. You installed the gtk1.2 libs. This should have fixed
the linker error.
Now you got a compiler error again (unit interfaces not found), so
something of FPC and/or Lazarus has changed.
Then you need to recompile Lazarus clean:
cd path/to/lazarus
make clean all
I have a question about your paths:
/home/colin/lazarus-0.9.16/usr/lib/lazarus/ide
This path looks rather untypical. Did you create
the /home/colin/lazarus-0.9.16/usr/lib/ path manually or was it
created by some installer?
[...]
Mattius, I had a long session on XChat with Andrew this morning and
with his expertise we finally got Lazarus to work.
As you wrote in another mail: probably it is something very simple. A
missing path or a wrong path or a file copied to the wrong place or
jut a typo.
He went off for a sleep and I played with Lazarus. The first project
I tried came up with 'Can't find unit Interfaces' and that is where I
stalled, I simply cannot find :
Is it looking for the unit interfaces or the Interface unit?
It searches the file interfaces.ppu.
Or to be more exact: the compiler searches a valid interfaces.ppu. You
can see what the compiler searches with the -vt switch, but it needs
some experience to understand the output.
Where are they going to be?
It is part of the LCL.
How do I tell Lazarus/fpc where they are when/if I find them?
If you create a new application in the IDE, it
will add the LCL package as requirement automatically.
If you created a program, then you must add it manually.
Project -> Project Inspector -> Add -> New Requirement -> LCL.
Because you might have an extraordinary setup check the following:
- Where is your lazarus directory?
The lazarus directory contains all sources and ppu files.
It should contain files like:
ide/main.pp
lcl/lclproc.pas
lcl/units/i386-linux/gtk/interfaces.ppu
Please check.
Is /home/colin/lazarus-0.9.16/usr/lib/lazarus/ your lazarus path?
Note: You can install lazarus as root. But if you use lazarus only as
your normal user 'colin', it is often easier to just put it somewhere in
your home directory. So the above path is a good idea.
- Is this path setup correctly in the IDE?
Environment Options -> Environment -> Lazarus directory
- Is the interfaces.ppu valid?
It's to difficult to explain how to check that. So just rebuild:
cd into the lazarus directory and do
make clean all
- Check the compiler options of your project.
Project -> Compiler options -> Show Options
Please paste them in your next mail, so we can check them.
I am getting heartily sick of typing the path to the lazarus
directory, Andrew gave me a shortcut string "sudo ln -sf
&(pwd) /lazarus/usr/bin" but that can't find a directory (which one?)
either...
sudo ln -sf /your/path/to/lazarus /usr/bin/lazarus
Mattias
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives
Thank you Mattius, it is late, I have had a couple of beers and my
dinner is on the table. I will follow your advice first thing Monday,
rest assured you will hear all about it!!
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives