Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2008-11

Where does Lazarus store/look for global settings/options?

43 messages · 10 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Tom Verhoeff

I was unable to find (in the wiki/FAQ) where Lazarus stores its global settings/options (the ones that are not project-specific and don't go into *.lpi).

Where does Lazarus look for these options, in what order? This is most likely platform dependent.

On my Mac, they appear to be stored in several XML files located in ~/.lazarus/

If I find out, where would be an appropriate place to document this in the wiki? It is something to put in IDE documentation, but I had also hoped to find it under development documentation.

To get some more detailed picture, can someone comment on each of the following files/directories that I find in ~/.lazarus/

bin/
cleandirectorydialog.xml
codeexploreroptions.xml
compilertest.pas Should I put something in this? (it is empty) editoroptions.xml Environment > Editor options ... environmentoptions.xml Environment > Environment options ... helpoptions.xml Help > Configure help ...
idemake.cfg
includelinks.xml
inputhistory.xml
lazarus.dci Environment > Code templates ...
lib/
miscellaneousoptions.xml
packagefiles.xml Packages > Configure installed packages ... projectsessions/
protocol.xml
staticpackages.inc
templates/ Tools > Project templates options

Thanks,

Tom

E-MAIL: T.Verhoeff @ TUE.NL | Dept. of Math. & Comp. Science PHONE: +31 40 247 41 25 | Technische Universiteit Eindhoven FAX: +31 40 247 54 04 | PO Box 513, NL-5600 MB Eindhoven http://www.win.tue.nl/~wstomv/ | The Netherlands

Reply by email

Mattias Gaertner
to Tom Verhoeff
I was unable to find (in the wiki/FAQ) where Lazarus stores its global settings/options (the ones that are not project-specific and don't go into *.lpi).

Because no one needed general information about them yet. See below.

Show quoted text 5 lines
Where does Lazarus look for these options, in what order? This is most likely platform dependent. On my Mac, they appear to be stored in several XML files located in ~/.lazarus/

Yes.
(There are some ideas to change this to a more mac like directory.)

If I find out, where would be an appropriate place to document this in the wiki? It is something to put in IDE documentation, but I had also hoped to find it under development documentation.

IMO it should go to development documentation, because these files are almost only edited by the IDE itself. I never edited them myself manually.
I would even say: If you need to edit/inspect them, then you found a bug.

To get some more detailed picture, can someone comment on each of the following files/directories that I find in ~/.lazarus/

bin/ - the IDE compiles itself here, if the source directory is readonly

cleandirectorydialog.xml - the dlg wih the same name

codeexploreroptions.xml - the wnd with the same name

compilertest.pas - auto generated, used to test/query compiler

editoroptions.xml - Environment > options > Editor ...

environmentoptions.xml - Environment > options > general ...

helpoptions.xml - Help > Configure help ...

idemake.cfg - the fpc cfg used for compiling the IDE

includelinks.xml - what files were included by what file, needed to find the unit of an include file

inputhistory.xml - various history lists of comboboxes/edit fields

lazarus.dci > Environment > Code

templates ... lib/ - if a package is readonly the IDE uses this directory instead for output

miscellaneousoptions.xml - IDE build options and some minors

packagefiles.xml - View > IDE internals

protocol.xml - IDE start log, used to not crash a second time due to a buggy project/package staticpackages.inc - the installed packages as uses section

Some packages create their own config files. For example:

templates/ - used by the projecttemplates package. Tools > Project templates options

Mattias

Reply by email

Tom Verhoeff
to Mattias Gaertner
Mattias Gaertner wrote 8 lines
On Sat, 22 Nov 2008 19:51:10 +0100 Tom Verhoeff wrote: > On my Mac, they appear to be stored in several XML files located > in ~/.lazarus/ Yes. (There are some ideas to change this to a more mac like directory.)

Where do they go under Windows and Linux?

Show quoted text 9 lines
> If I find out, where would be an appropriate place to document > this in the wiki? It is something to put in IDE documentation, > but I had also hoped to find it under development documentation. IMO it should go to development documentation, because these files are almost only edited by the IDE itself. I never edited them myself manually. I would even say: If you need to edit/inspect them, then you found a bug.

OK, I'll see if I can find some time to add the information.

For the plain user, it is still useful to know where Lazarus stores options and settings (e.g. for backup, permission issues). Internal details should indeed go into developer documentation.

Thanks,

Tom

E-MAIL: T.Verhoeff @ TUE.NL | Dept. of Math. & Comp. Science PHONE: +31 40 247 41 25 | Technische Universiteit Eindhoven FAX: +31 40 247 54 04 | PO Box 513, NL-5600 MB Eindhoven http://www.win.tue.nl/~wstomv/ | The Netherlands

Reply by email

Mattias Gaertner
to Tom Verhoeff
Show quoted text 11 lines
On Mon, Nov 24, 2008 at 11:38:54AM +0100, Mattias Gaertner wrote: > On Sat, 22 Nov 2008 19:51:10 +0100 > Tom Verhoeff wrote: > > > On my Mac, they appear to be stored in several XML files located > > in ~/.lazarus/ > > Yes. > (There are some ideas to change this to a more mac like directory.) Where do they go under Windows and Linux?

Linux, BSD, Solaris: $HOME/.lazarus

Windows: depends on the installation. I'm not sure if GetAppConfigDir depends on windows version. Maybe Vincent can tell.

You can see the config directory, when starting the IDE on the console.

Show quoted text 11 lines
> > If I find out, where would be an appropriate place to document > > this in the wiki? It is something to put in IDE documentation, > > but I had also hoped to find it under development documentation. > > IMO it should go to development documentation, because these files > are almost only edited by the IDE itself. I never edited them myself > manually. > I would even say: If you need to edit/inspect them, then you found a > bug. OK, I'll see if I can find some time to add the information.

Thanks.

For the plain user, it is still useful to know where Lazarus stores options and settings (e.g. for backup, permission issues). Internal details should indeed go into developer documentation.

Mattias

Reply by email

John vd Waeter
to Mattias Gaertner
Windows: depends on the installation. I'm not sure if GetAppConfigDir depends on windows version. Maybe Vincent can tell.

On winxp I found them under:

C:\Documents and Settings\John\Local Settings\Application Data\lazarus

Note that "local Settings" is a hidden dir, usually.

kind regards,
John

Show quoted text 34 lines
You can see the config directory, when starting the IDE on the console. >>>If I find out, where would be an appropriate place to document >>>this in the wiki? It is something to put in IDE documentation, >>>but I had also hoped to find it under development documentation. >> >>IMO it should go to development documentation, because these files >>are almost only edited by the IDE itself. I never edited them myself >>manually. >>I would even say: If you need to edit/inspect them, then you found a >>bug. > >OK, I'll see if I can find some time to add the information. Thanks. >For the plain user, it is still useful to know where Lazarus stores >options and settings (e.g. for backup, permission issues). Internal >details should indeed go into developer documentation. Mattias _______________________________________________ Lazarus mailing list http://www.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply by email

Tom Verhoeff
to Mattias Gaertner: On Mon, 24 Nov 2008 18:04:38 +0100 Linux, BSD, Solaris: $HOME/.lazarus Windows: depends…
Mattias Gaertner wrote 10 lines
On Mon, 24 Nov 2008 18:04:38 +0100 Tom Verhoeff wrote: > Where do they go under Windows and Linux? Linux, BSD, Solaris: $HOME/.lazarus Windows: depends on the installation. I'm not sure if GetAppConfigDir depends on windows version. Maybe Vincent can tell. You can see the config directory, when starting the IDE on the console.

Is it searched in only one location, or is there a sequence of locations that is tried?

Thanks once more,

Tom

E-MAIL: T.Verhoeff @ TUE.NL | Dept. of Math. & Comp. Science PHONE: +31 40 247 41 25 | Technische Universiteit Eindhoven FAX: +31 40 247 54 04 | PO Box 513, NL-5600 MB Eindhoven http://www.win.tue.nl/~wstomv/ | The Netherlands

Reply by email

Luca Olivetti
to Mattias Gaertner: On Sat, 22 Nov 2008 19:51:10 +0100 Because no one needed general information about them…

En/na Mattias Gaertner ha escrit:

Show quoted text 5 lines
IMO it should go to development documentation, because these files are almost only edited by the IDE itself. I never edited them myself manually. I would even say: If you need to edit/inspect them, then you found a bug.

Then I found a bug ;-)
I reported here before that, when switching lazarus version I ended up mixing bundled components from the old version to the new one, so I had to manually edit those files to fix the paths.

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Felipe Monteiro de Carvalho
to Mattias Gaertner: On Mon, 24 Nov 2008 18:04:38 +0100 Linux, BSD, Solaris: $HOME/.lazarus Windows: depends…
Mattias Gaertner wrote
Linux, BSD, Solaris: $HOME/.lazarus Windows: depends on the installation. I'm not sure if GetAppConfigDir depends on windows version. Maybe Vincent can tell.

It depends on the Windows version and also on the Free Pascal version =)

Some time ago I published my tests here:

http://wiki.lazarus.freepascal.org/Multiplatform_Programming_Guide#Configuration_files

Felipe Monteiro de Carvalho

Reply by email

Graeme Geldenhuys
to Felipe Monteiro de Carvalho
Felipe Monteiro de Carvalho wrote

Thanks for that link. There is some interesting information in that wiki page. It will come in handy for (Delphi) tiOPF users venturing into Free Pascal land... :)

Regards,
- Graeme -

_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/

Reply by email

Luca Olivetti
to Mattias Gärtner: An embedded and charset-unspecified text was scrubbed... Name: not available Url:…

En/na Mattias G?rtner ha escrit:

Show quoted text 15 lines
Zitat von Luca Olivetti : > En/na Mattias Gaertner ha escrit: > >> IMO it should go to development documentation, because these files are >> almost only edited by the IDE itself. I never edited them myself >> manually. >> I would even say: If you need to edit/inspect them, then you found a >> bug. > Then I found a bug ;-) > I reported here before that, when switching lazarus version I ended up > mixing bundled components from the old version to the new one, so I had > to manually edit those files to fix the paths. What components, what paths?

http://news.gmane.org/find-root.php?message_id=%3c48F836DE.2080402%40wetron.es%3e

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Mattias Gaertner
to Luca Olivetti
Show quoted text 18 lines
En/na Mattias G?rtner ha escrit: > Zitat von Luca Olivetti : > >> En/na Mattias Gaertner ha escrit: >> >>> IMO it should go to development documentation, because these >>> files are almost only edited by the IDE itself. I never edited >>> them myself manually. >>> I would even say: If you need to edit/inspect them, then you >>> found a bug. >> Then I found a bug ;-) >> I reported here before that, when switching lazarus version I >> ended up mixing bundled components from the old version to the new >> one, so I had to manually edit those files to fix the paths. > > What components, what paths? http://news.gmane.org/find-root.php?message_id=%3c48F836DE.2080402%40wetron.es%3e

Well, yes and no.
It is not a bug, because to use two different settings the --pcp option exists (See my answer to the above mail).
And yes, lazbuild does not have an option to override the lazarus source directory.
The same is true for many other options.

Sharing a lazarus config directory by two different lazarus versions can give trouble. Better use two different lazarus config directories. I'm not sure what settings you want to share.

Mattias

Reply by email

Luca Olivetti
to Mattias Gaertner

En/na Mattias Gaertner ha escrit:

Show quoted text 12 lines
> http://news.gmane.org/find-root.php?message_id=%3c48F836DE.2080402%40wetron.es%3e Well, yes and no. It is not a bug, because to use two different settings the --pcp option exists (See my answer to the above mail). And yes, lazbuild does not have an option to override the lazarus source directory. The same is true for many other options. Sharing a lazarus config directory by two different lazarus versions can give trouble. Better use two different lazarus config directories. I'm not sure what settings you want to share.

I don't really want to share them, I just want to build lazarus with my selection of components, regardless of the lazarus version I'm using. Suppose I use svn and 0.9.26, suppose also that, as you suggest, I use --pcp to keep the configuration different.
Now, suppose that while I'm using the svn version, I install a component bundled with lazarus, say, rx.
What I want is, when I rebuild 0.9.26, it also has rx installed, but obviously compiling it from the 0.9.26 source directory, and without having to manually install it in the ide.
Most important, when I update to 0.9.28 I also want to rebuild it and have rx included.
Of course, it wouldn't be an issue if you only have a couple of components installed, but it is when you have 10 or 20. As of now, the only way to do it is to copy the configuration files from one version to the other and manually edit the paths of the components that are under the lazarus source directory.

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Mattias Gaertner
to Luca Olivetti
Show quoted text 31 lines
En/na Mattias Gaertner ha escrit: >> http://news.gmane.org/find-root.php?message_id=%3c48F836DE.2080402%40wetron.es%3e > > Well, yes and no. > It is not a bug, because to use two different settings the --pcp > option exists (See my answer to the above mail). > And yes, lazbuild does not have an option to override the lazarus > source directory. > The same is true for many other options. > > Sharing a lazarus config directory by two different lazarus versions > can give trouble. Better use two different lazarus config > directories. I'm not sure what settings you want to share. I don't really want to share them, I just want to build lazarus with my selection of components, regardless of the lazarus version I'm using. Suppose I use svn and 0.9.26, suppose also that, as you suggest, I use --pcp to keep the configuration different. Now, suppose that while I'm using the svn version, I install a component bundled with lazarus, say, rx. What I want is, when I rebuild 0.9.26, it also has rx installed, but obviously compiling it from the 0.9.26 source directory, and without having to manually install it in the ide. Most important, when I update to 0.9.28 I also want to rebuild it and have rx included. Of course, it wouldn't be an issue if you only have a couple of components installed, but it is when you have 10 or 20. As of now, the only way to do it is to copy the configuration files from one version to the other and manually edit the paths of the components that are under the lazarus source directory.

Well, the important point is:
"without having to manually install it in the ide."

If you don't want to use the IDE, then yes, you have to manually edit the config files.
What you need is a (command line) tool to copy some part of the config directory to another config directory (here: the list of installed package names and the paths that are not in the lazarus directory). The IDE allows to save the list of installed package names and load them (Packages / congfigure installed packages / import,export). If this list is extended with the paths then you have a tool. But you have to start the IDE for that. At the moment you have to manually open each new package once.

Keep in mind that sharing one config with two different lazarus versions is not supported. A newer lazarus can read the older configs. But the other way does not work always, so you can loose some settings.

Mattias

Reply by email

Luca Olivetti
to Mattias Gaertner

En/na Mattias Gaertner ha escrit:

Show quoted text 35 lines
On Mon, 01 Dec 2008 09:08:19 +0100 Luca Olivetti wrote: > En/na Mattias Gaertner ha escrit: > >>> http://news.gmane.org/find-root.php?message_id=%3c48F836DE.2080402%40wetron.es%3e >> Well, yes and no. >> It is not a bug, because to use two different settings the --pcp >> option exists (See my answer to the above mail). >> And yes, lazbuild does not have an option to override the lazarus >> source directory. >> The same is true for many other options. >> >> Sharing a lazarus config directory by two different lazarus versions >> can give trouble. Better use two different lazarus config >> directories. I'm not sure what settings you want to share. > I don't really want to share them, I just want to build lazarus with > my selection of components, regardless of the lazarus version I'm > using. Suppose I use svn and 0.9.26, suppose also that, as you > suggest, I use --pcp to keep the configuration different. > Now, suppose that while I'm using the svn version, I install a > component bundled with lazarus, say, rx. > What I want is, when I rebuild 0.9.26, it also has rx installed, but > obviously compiling it from the 0.9.26 source directory, and without > having to manually install it in the ide. > Most important, when I update to 0.9.28 I also want to rebuild it and > have rx included. > Of course, it wouldn't be an issue if you only have a couple of > components installed, but it is when you have 10 or 20. > As of now, the only way to do it is to copy the configuration files > from one version to the other and manually edit the paths of the > components that are under the lazarus source directory. Well, the important point is: "without having to manually install it in the ide."

Actually, without having to *re* install it in the ide. I'm perfectly fine with the ide for the first time I install a new package. After that I simply want to use make to rebuild lazarus.

Show quoted text 5 lines
If you don't want to use the IDE, then yes, you have to manually edit the config files. What you need is a (command line) tool to copy some part of the config directory to another config directory (here: the list of installed package names and the paths that are not in the lazarus directory).

Actually, the paths that *are* in the lazarus directory, adjusting them for the *different* lazarus directory. Components outside of the lazarus tree are no problem.
Maybe the solution could be to simply use relative paths if they are under the lazarus directory.

The IDE allows to save the list of installed package names and load them (Packages / congfigure installed packages / import,export). If this list is extended with the paths then you have a tool.

If it is extended with the path it would probably have the same problem: components outside the lazarus directory will be fine, components in the lazarus directory will point to the old one once imported. Again, maybe the solution could be the use of relative paths.

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Hans-Peter Diettrich
to Luca Olivetti: En/na Mattias Gaertner ha escrit: I don't really want to share them, I just want to build…
Show quoted text 6 lines
> Sharing a lazarus config directory by two different lazarus versions > can give trouble. Better use two different lazarus config directories. > I'm not sure what settings you want to share. I don't really want to share them, I just want to build lazarus with my selection of components, regardless of the lazarus version I'm using.

I want to build lazarus from a different source (SVN), too.

The instructions for a Windows installation look outdated, the directories do not match the current distribution or SVN, and I'm missing the final step: how to build the new

Reply by email

Mattias Gaertner
to Luca Olivetti: En/na Mattias Gaertner ha escrit: Actually, without having to *re* install it in the ide.…
Show quoted text 51 lines
En/na Mattias Gaertner ha escrit: > On Mon, 01 Dec 2008 09:08:19 +0100 > Luca Olivetti wrote: > >> En/na Mattias Gaertner ha escrit: >> >>>> http://news.gmane.org/find-root.php?message_id=%3c48F836DE.2080402%40wetron.es%3e >>> Well, yes and no. >>> It is not a bug, because to use two different settings the --pcp >>> option exists (See my answer to the above mail). >>> And yes, lazbuild does not have an option to override the lazarus >>> source directory. >>> The same is true for many other options. >>> >>> Sharing a lazarus config directory by two different lazarus >>> versions can give trouble. Better use two different lazarus config >>> directories. I'm not sure what settings you want to share. >> I don't really want to share them, I just want to build lazarus >> with my selection of components, regardless of the lazarus version >> I'm using. Suppose I use svn and 0.9.26, suppose also that, as you >> suggest, I use --pcp to keep the configuration different. >> Now, suppose that while I'm using the svn version, I install a >> component bundled with lazarus, say, rx. >> What I want is, when I rebuild 0.9.26, it also has rx installed, >> but obviously compiling it from the 0.9.26 source directory, and >> without having to manually install it in the ide. >> Most important, when I update to 0.9.28 I also want to rebuild it >> and have rx included. >> Of course, it wouldn't be an issue if you only have a couple of >> components installed, but it is when you have 10 or 20. >> As of now, the only way to do it is to copy the configuration files >> from one version to the other and manually edit the paths of the >> components that are under the lazarus source directory. > > Well, the important point is: > "without having to manually install it in the ide." Actually, without having to *re* install it in the ide. I'm perfectly fine with the ide for the first time I install a new package. After that I simply want to use make to rebuild lazarus. > If you don't want to use the IDE, then yes, you have to > manually edit the config files. > What you need is a (command line) tool to copy some part of the > config directory to another config directory (here: the list of > installed package names and the paths that are not in the lazarus > directory). Actually, the paths that *are* in the lazarus directory, adjusting them for the *different* lazarus directory. Components outside of the lazarus tree are no problem.

;)
Actually lazarus knows the paths to the packages inside the lazarus sources, because they have packager/globallinks/*.lpl files. When you setup a second config directory it needs to know the outside packages.

Maybe the solution could be to simply use relative paths if they are under the lazarus directory.

Yes, but that would make using packages from other lazarus source directories impossible. So it is not that simple.

Show quoted text 9 lines
> The IDE allows to save the list of installed package names and load > them (Packages / congfigure installed packages / import,export). If > this list is extended with the paths then you have a tool. If it is extended with the path it would probably have the same problem: components outside the lazarus directory will be fine, components in the lazarus directory will point to the old one once imported. Again, maybe the solution could be the use of relative paths.

Yes, you need a filter option for the import/export.

Mattias

Reply by email

Luca Olivetti
to Mattias Gaertner

En/na Mattias Gaertner ha escrit:

Show quoted text 5 lines
;) Actually lazarus knows the paths to the packages inside the lazarus sources, because they have packager/globallinks/*.lpl files. When you setup a second config directory it needs to know the outside packages.

Well, when I switched from svn to 0.9.28, and built it with lazbuild, I ended up with components and the lcl from svn instead of 0.9.28.

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Luca Olivetti
to Luca Olivetti

En/na Luca Olivetti ha escrit:

Show quoted text 10 lines
En/na Mattias Gaertner ha escrit: > ;) > Actually lazarus knows the paths to the packages inside the lazarus > sources, because they have packager/globallinks/*.lpl files. > When you setup a second config directory it needs to know the outside > packages. Well, when I switched from svn to 0.9.28, and built it with lazbuild, I ended up with components and the lcl from svn instead of 0.9.28.

I meant 0.9.26 ;-)

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Mattias Gaertner
to Hans-Peter Diettrich: I want to build lazarus from a different source (SVN), too. The instructions for a…
Show quoted text 15 lines
Luca Olivetti schrieb: >> Sharing a lazarus config directory by two different lazarus >> versions can give trouble. Better use two different lazarus config >> directories. I'm not sure what settings you want to share. > > I don't really want to share them, I just want to build lazarus > with my selection of components, regardless of the lazarus version > I'm using. I want to build lazarus from a different source (SVN), too. The instructions for a Windows installation look outdated, the directories do not match the current distribution or SVN, and I'm missing the final step: how to build the new ?

I will add it.

Mattias

Reply by email

Mattias Gaertner
to Luca Olivetti: En/na Mattias Gaertner ha escrit: Well, when I switched from svn to 0.9.28, and built it…
Show quoted text 10 lines
En/na Mattias Gaertner ha escrit: > ;) > Actually lazarus knows the paths to the packages inside the lazarus > sources, because they have packager/globallinks/*.lpl files. > When you setup a second config directory it needs to know the > outside packages. Well, when I switched from svn to 0.9.28, and built it with lazbuild, I ended up with components and the lcl from svn instead of 0.9.28.

This happens when you use only one config directory instead of two.

Mattias

Reply by email

Mattias Gaertner
to Hans-Peter Diettrich
Show quoted text 11 lines
Mattias Gaertner schrieb: >> The instructions for a Windows installation look outdated, the >> directories do not match the current distribution or SVN, and I'm >> missing the final step: how to build the new Lazarus at all. > > Where? E.g.: http://wiki.lazarus.freepascal.org/index.php/Getting_Lazarus

This page should be renamed to something like how to get the development sources of lazarus. And the other hints should be moved to the installation page:
http://wiki.lazarus.freepascal.org/Installing_Lazarus

There the compilation of the IDE is described.

> I will add it. Fine :-)

I added link.

Mattias

Reply by email

Luca Olivetti
to Mattias Gaertner: On Mon, 01 Dec 2008 14:45:55 +0100 This happens when you use only one config directory…

En/na Mattias Gaertner ha escrit:

Show quoted text 14 lines
On Mon, 01 Dec 2008 14:45:55 +0100 Luca Olivetti wrote: > En/na Mattias Gaertner ha escrit: > >> ;) >> Actually lazarus knows the paths to the packages inside the lazarus >> sources, because they have packager/globallinks/*.lpl files. >> When you setup a second config directory it needs to know the >> outside packages. > Well, when I switched from svn to 0.9.28, and built it with lazbuild, > I ended up with components and the lcl from svn instead of 0.9.28. This happens when you use only one config directory instead of two.

Well, yes, but had I used a different config directory I would have had to manually reinstall the components.
Besides, while switching from svn to a release isn't so common, upgrading from one version to the next is.

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Luca Olivetti
to Mattias Gärtner

En/na Mattias G?rtner ha escrit:

The installation packages install Lazarus always in the same location. There was no need yet to auto update paths. Can you explain what the problem is when upgrading?

To have the extra packages/components installed in the previous version available in the new one.
Hey, I already know how to do that by editing the configuration files, it's you that's saying that it shouldn't be necessary ;-)

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Hans-Peter Diettrich
to Mattias Gaertner: On Mon, 01 Dec 2008 23:49:04 +0100 This page should be renamed to something like how to…
Show quoted text 8 lines
> http://wiki.lazarus.freepascal.org/index.php/Getting_Lazarus This page should be renamed to something like how to get the development sources of lazarus. And the other hints should be moved to the installation page: http://wiki.lazarus.freepascal.org/Installing_Lazarus There the compilation of the IDE is described.

Thanks, this page seems to match my needs better :-)

In detail the USB drive instructions look very interesting, for having Lazarus installed in both the release and trunk versions.

Nonetheless I wonder:

- When I want to have multiple Lazarus installations on the same machine, why can't that be done from an existing Lazarus installation? Lazarus already can rebuild itself, to include required packages. What would be required to use that existing feature to rebuild Lazarus after changes to the Lazarus source code? [I already have 2 Lazarus icons on my desktop, one for the "naked" (distributed) version, and one for the rebuilt one.]

- Similar for applications, developed with fpc/Lazarus. When I e.g. work on PasDoc, I want to have both the "official" and trunk/branch versions available, for reference purposes. I'm absolutely lost (on Linux), how the test suites find their corresponding program file.

- Why is a Lazarus installation so different from the installation of Windows applications, conforming to the Windows guidelines? The proper use of the defined application and user directories would allow for multiple (common or user-specific) installations, and more. Please note that I understand the advantages of an installation that bypasses common Windows policies, but many users would be happy with a "standard" installation, as appropriate for every OS (not only for Windows).

- I'm missing a GUI tool for managing the Lazarus installation(s). The intended audience certainly are GUI people, not command line freaks! I understand that such a tool must be platform specific, to some degree, but it might be easier to provide such tools, instead of writing detailed command line procedures for the different platforms. If somebodey can provide a platform independent skeleton for such a tool, I'm willing to add the Windows specific part to it.

DoDi

Reply by email

Mattias Gärtner
to Luca Olivetti: En/na Mattias G?rtner ha escrit: To have the extra packages/components installed in the…

Zitat von Luca Olivetti :

Show quoted text 9 lines
En/na Mattias G?rtner ha escrit: > The installation packages install Lazarus always in the same location. There was > no need yet to auto update paths. > Can you explain what the problem is when upgrading? To have the extra packages/components installed in the previous version available in the new one.

Just start the IDE, compile and restart it. This will install the last package set.

Hey, I already know how to do that by editing the configuration files, it's you that's saying that it shouldn't be necessary ;-)

Yes.
I bet I'm not the only one.

Mattias

Reply by email

Felipe Monteiro de Carvalho
to Hans-Peter Diettrich: Thanks, this page seems to match my needs better :-) In detail the USB drive instructions…
Hans-Peter Diettrich wrote
- When I want to have multiple Lazarus installations on the same machine

Read this:

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

- Why is a Lazarus installation so different from the installation of Windows applications, conforming to the Windows guidelines?

Why do you think that Lazarus doesn't conform to Windows guidelines? Can you show a concrete guideline it is breaking?

The only thing I see is that multiple versions share the same configuration file, but I don't know if this is against any guideline.

Maybe the default configuration directory should contain the lazarus version in it.

Felipe Monteiro de Carvalho

Reply by email

JoshyFun
to Felipe Monteiro de Carvalho

Hello Felipe,

Tuesday, December 2, 2008, 5:17:23 PM, you wrote:

FMdC> Maybe the default configuration directory should contain the lazarus FMdC> version in it.

I think (as proposed long time ago) that at least in windows (I'm not used to *nix styles) should ask at some point in the installation procedure to use the user configuration folder (default) or a different one, as new releases or trunk version may kill older config files due changes in the behavior.

Best regards, JoshyFun

Reply by email

Vincent Snijders
to JoshyFun
JoshyFun wrote
different one, as new releases or trunk version may kill older config files due changes in the behavior.

This rather unlikely, because newer Lazarus versions can read older config files.

Vincent

Reply by email

JoshyFun
to Vincent Snijders

Hello Vincent,

Tuesday, December 2, 2008, 9:28:55 PM, you wrote:

VS> JoshyFun wrote
> different one, as new releases or trunk version may kill older config > files due changes in the behavior. >

VS> This rather unlikely, because newer Lazarus versions can read older VS> config files.

No, the other way... I'm using in example 0.9.24, and install 0.9.25 in order to test it and evaluate if an upgrade is interesting. Once installed I run it but some things do not work as expected with my code so I must still work with 0.9.24 meanwhile I do not fix my problems to run in 0.9.25, but... Ooops, 0.9.24 is not working as expected anymore, even the project do not load in 0.9.24 (fortunatly I backup it before test it with new release), finally I get 0.9.24 working again but installed 0.9.26 and again, same story (you know, human, the same stone two time...). Finally I found the --primary-config-path setting and everything is solved for me, but it does not look as a "safe" mode, at least from my POV.

Best regards, JoshyFun

Reply by email

Hans-Peter Diettrich
to Felipe Monteiro de Carvalho: On Tue, Dec 2, 2008 at 1:29 PM, Hans-Peter Diettrich Read this:…
> - Why is a Lazarus installation so different from the installation of > Windows applications, conforming to the Windows guidelines? Why do you think that Lazarus doesn't conform to Windows guidelines?

Executable files should reside in the Programs directory (read-only), Data in the AppData and UserData directories. Settings should reside in the registry.

Not that I (personally) like that separation, but it will make sense to administrators.

Can you show a concrete guideline it is breaking?

Good point - no, I can't just now, most MSDN entries address .NET.

Show quoted text 5 lines
The only thing I see is that multiple versions share the same configuration file, but I don't know if this is against any guideline. Maybe the default configuration directory should contain the lazarus version in it.

I'll try to figure out a viable solution, when I really start working with multiple Lazarus versions myself.

DoDi

Reply by email

Luca Olivetti
to Felipe Monteiro de Carvalho: On Tue, Dec 2, 2008 at 1:29 PM, Hans-Peter Diettrich Read this:…

En/na Felipe Monteiro de Carvalho ha escrit:

Why do you think that Lazarus doesn't conform to Windows guidelines? Can you show a concrete guideline it is breaking?

Not strictly a lazarus problem (it's an fpc one), but for user preferences it should use CSIDL_APPDATA, not CSIDL_LOCAL_APPDATA. At least all other programs I know puts their preferences there.

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Luca Olivetti
to Mattias Gärtner: Zitat von Luca Olivetti : Just start the IDE, compile and restart it. This will install…

En/na Mattias G?rtner ha escrit:

Show quoted text 13 lines
Zitat von Luca Olivetti : > En/na Mattias G?rtner ha escrit: > >> The installation packages install Lazarus always in the same location. > There was >> no need yet to auto update paths. >> Can you explain what the problem is when upgrading? > To have the extra packages/components installed in the previous version > available in the new one. Just start the IDE, compile and restart it. This will install the last package set.

I normally use lazbuild, but as a test I followed your advice:

1) I copied my c:\lazarus-0.9.26 directory to to a new directory c:\laztest
2) "make clean bigide" in c:\laztest
3) start the new lazarus, change environment options to point to c:\laztest (otherwise the ide "build lazarus" would build the old one)
4) Add a bogus property to TChart in the new directory (tchart is shipped with lazarus but it isn't installed by default)
5) Tools->Configure Build Lazarus->Build Ide With Packages->Build
6) Put a TChart on a form to check in the object inspector if the new bogus property is there
7) The new property isn't there, unsurprisingly since lazarus compiled the component from the old directory

QED

Here's a a diff between idemake.cfg from the old and the newly built ide. As you can see lazarus adjusted the paths only for synedit,ideintf,lcl,codetools and packager, but it used the same as before for all other components.

--- lazarus.save/idemake.cfg 2008-11-17 15:38:40.544913600 +0100 +++ lazarus/idemake.cfg 2008-12-03 08:58:50.537998400 +0100 @@ -1,33 +1,33 @@
--FEC:\lazarus-0.9.26
+-FEc:\laztest
-olazarus.new.exe
-FlC:\lazextra\libnodave-0.8.4.4\DelphiComponent\
-FuC:\lazextra\zeosdbo\trunk\packages\lazarus\build\ +-FuC:\lazarus-0.9.26\components\rtticontrols\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\printers\design\lib\i386-win32\ +-FuC:\lazarus-0.9.26\components\cgi\ide\lib\i386-win32\ +-FuC:\lazarus-0.9.26\components\memds\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\fpcunit\ide\lib\i386-win32\ +-FuC:\lazarus-0.9.26\components\projecttemplates\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\sqldb\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\tdbf\lib\i386-win32\win32\ -FuC:\lazextra\rx\lib\i386-win32\
-FuC:\lazextra\RackCtls\lib\i386-win32\
--FuC:\lazarus-0.9.26\components\tdbf\lib\i386-win32\win32\ --FuC:\lazarus-0.9.26\components\sqldb\lib\i386-win32\win32\ --FuC:\lazarus-0.9.26\components\projecttemplates\lib\i386-win32\win32\ --FuC:\lazarus-0.9.26\components\fpcunit\ide\lib\i386-win32\ --FuC:\lazarus-0.9.26\components\memds\lib\i386-win32\win32\ --FuC:\lazarus-0.9.26\components\cgi\ide\lib\i386-win32\ --FuC:\lazarus-0.9.26\components\printers\design\lib\i386-win32\ --FuC:\lazarus-0.9.26\components\rtticontrols\lib\i386-win32\win32\ -FuC:\lazarus-0.9.26\components\daemon\lib\i386-win32\win32\ -FuC:\lazcustom\animacion\lib\i386-win32\
--FuC:\lazarus-0.9.26\components\synedit\units\i386-win32\ --FuC:\lazarus-0.9.26\ideintf\units\i386-win32\
--FuC:\lazextra\libnodave-0.8.4.4\DelphiComponent\lib\ --FuC:\lazarus-0.9.26\components\tachart\lib\i386-win32\win32\ --FuC:\lazarus-0.9.26\components\turbopower_ipro\units\i386-win32\ --FuC:\lazarus-0.9.26\components\sdf\lib\i386-win32\win32\ --FuC:\lazarus-0.9.26\components\cgi\lib\i386-win32\win32\ +-Fuc:\laztest\components\synedit\units\i386-win32\ +-Fuc:\laztest\ideintf\units\i386-win32\
-FuC:\lazarus-0.9.26\components\printers\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\cgi\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\sdf\lib\i386-win32\win32\ +-FuC:\lazarus-0.9.26\components\turbopower_ipro\units\i386-win32\ +-FuC:\lazarus-0.9.26\components\tachart\lib\i386-win32\win32\ +-FuC:\lazextra\libnodave-0.8.4.4\DelphiComponent\lib\ -FuC:\lazarus-0.9.26\components\rx\lib\
-FuC:\lazcustom\myspin\lib\i386-win32\
--FuC:\lazarus-0.9.26\lcl\units\i386-win32\
--FuC:\lazarus-0.9.26\lcl\units\i386-win32\win32\
--FuC:\lazarus-0.9.26\components\codetools\units\i386-win32\ --FuC:\lazarus-0.9.26\packager\units\i386-win32\
+-Fuc:\laztest\lcl\units\i386-win32\
+-Fuc:\laztest\lcl\units\i386-win32\win32\
+-Fuc:\laztest\components\codetools\units\i386-win32\ +-Fuc:\laztest\packager\units\i386-win32\
-Fu.
-dLCL
-dLCLwin32

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

Graeme Geldenhuys
to JoshyFun: VS> This rather unlikely, because newer Lazarus versions can read older VS> config files.…
JoshyFun wrote 6 lines
No, the other way... I'm using in example 0.9.24, and install 0.9.25 in order to test it and evaluate if an upgrade is interesting. Once installed I run it but some things do not work as expected with my code so I must still work with 0.9.24 meanwhile I do not fix my problems to run in 0.9.25, but... Ooops, 0.9.24 is not working as

I do that often under Linux and have always handled that by specifying a new config location as a parameter when I start up Lazarus. Why can't Windows or any other platform users do the same! The command line doesn't bite. ;-)

You are experimenting with new software, so I would assume you know what you are doing!

eg:
I have setup two desktop icons with the following details. I can easily switch between Lazarus versions and they don't affect each others settings.

--------[ stable Lazarus 0.9.26 ]------------------ [Desktop Entry]
Version=1.0
Encoding=UTF-8
Name=Lazarus IDE 0.9.26
Type=Application
Terminal=false
Exec=/opt/laz_git_copy/lazarus --pcp=/home/graemeg/.lazarus-0.9.26 Comment=Lazarus v0.9.26 release
Icon=/opt/laz_git_copy/images/splash_logo.xpm
GenericName[en_GB]=The stable Lazarus v0.9.26 release

--------[ development Lazarus svn ]------------------ [Desktop Entry]
Version=1.0
Encoding=UTF-8
Name=Lazarus IDE svn
Type=Application
Terminal=false
Exec=/opt/lazarus_svn/lazarus --pcp=/home/graemeg/.lazarus-svn Comment=Lazarus unstable
Icon=/opt/lazarus_svn/images/splash_logo.xpm

As you can see, I specify the config path with the --pcp parameter.

Which reminds me. Lazarus should really conform to the FreeDesktop.org requirements. By default any application's config or custom settings should live in $HOME/.config/<appname./ directory. Why does Lazarus IDE still use the old $HOME/.<appname>/ location?

Regards,
- Graeme -

_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/

Reply by email

Graeme Geldenhuys
to Hans-Peter Diettrich: Executable files should reside in the Programs directory (read-only), Data in the AppData…
Hans-Peter Diettrich wrote
Executable files should reside in the Programs directory (read-only), Data in the AppData and UserData directories. Settings should reside in the registry.

I fully agree with that, except for the last option. Please, oh please don't use the registry!!! The registry has no added benefits compared to .ini files. INI files are easy to maintain, can be edited manually with any text editor and you can easily transfer or backup your custom settings by simply copying the INI files.

The worst mistake Microsoft could have done was introduce the Registry concept! Unix is much older that Windows, and they still use plain text config files similar to INI files. They work perfectly to this day and are very easy to maintain and specially backup. Whenever windows programs give me a choice of registry or INI files, I always choose the latter.

I'll try to figure out a viable solution, when I really start working with multiple Lazarus versions myself.

I don't see the need. See my previous post. Simply create two icons on the desktop. People that use Lazarus are not "end users", they are more technical minded "developers" and should know how to create icons and custom settings. If you experiment with new versions of software, you should know what you are doing.

Regards,
- Graeme -

_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/

Reply by email

Mattias Gaertner
to Luca Olivetti: En/na Mattias G?rtner ha escrit: I normally use lazbuild, but as a test I followed your…
Show quoted text 20 lines
En/na Mattias G?rtner ha escrit: > Zitat von Luca Olivetti : > >> En/na Mattias G?rtner ha escrit: >> >>> The installation packages install Lazarus always in the same >>> location. >> There was >>> no need yet to auto update paths. >>> Can you explain what the problem is when upgrading? >> To have the extra packages/components installed in the previous >> version available in the new one. > > Just start the IDE, compile and restart it. This will install the > last package set. I normally use lazbuild, but as a test I followed your advice: 1) I copied my c:\lazarus-0.9.26 directory to to a new directory c:\laztest 2) "make clean bigide" in c:\laztest

There is a misunderstanding.

Upgrading: replace old version with a newer one. One config directory is enough.

Multiple lazarus: one config per version is recommended.

Show quoted text 11 lines
3) start the new lazarus, change environment options to point to c:\laztest (otherwise the ide "build lazarus" would build the old one) 4) Add a bogus property to TChart in the new directory (tchart is shipped with lazarus but it isn't installed by default) 5) Tools->Configure Build Lazarus->Build Ide With Packages->Build 6) Put a TChart on a form to check in the object inspector if the new bogus property is there 7) The new property isn't there, unsurprisingly since lazarus compiled the component from the old directory QED

It proves, that multiple lazarus versions requires multiple config directories and that it is not enough to copy a config directory and change *only one* path. As I said, it would be nice if there is a tool to help change some more paths.

Here's a a diff between idemake.cfg from the old and the newly built ide. As you can see lazarus adjusted the paths only for synedit,ideintf,lcl,codetools and packager, but it used the same as before for all other components.

Yes. These are the at the moment hard coded packages. It is planned to change this. And to add some mechanism to load all used packages from the other source directory.

You get the same problem with all package collections.

[...]

Mattias

Reply by email

Luca Olivetti
to Mattias Gaertner

En/na Mattias Gaertner ha escrit:

It proves, that multiple lazarus versions requires multiple config directories and that it is not enough to copy a config directory and change *only one* path. As I said, it would be nice if there is a tool to help change some more paths.

Oh, but such a tool is there: "sed" and/or "perl -pi -e" ;-)

Bye

Luca Olivetti Wetron Automatizaci?n S.A. http://www.wetron.es/ Tel. +34 93 5883004 Fax +34 93 5883007

Reply by email

JoshyFun
to Graeme Geldenhuys: I do that often under Linux and have always handled that by specifying a new config…

Hello Graeme,

you wrote 5 lines
> No, the other way... I'm using in example 0.9.24, and install 0.9.25 > in order to test it and evaluate if an upgrade is interesting. Once > installed I run it but some things do not work as expected with my > code so I must still work with 0.9.24 meanwhile I do not fix my > problems to run in 0.9.25, but... Ooops, 0.9.24 is not working as

GG> I do that often under Linux and have always handled that by specifying GG> a new config location as a parameter when I start up Lazarus. Why GG> can't Windows or any other platform users do the same! The command GG> line doesn't bite. ;-)

That's not the problem, I'm very confortable with command line, in fact I'm using 4NT much more than file explorer. But in pre 0.9.26 versions the config is tied to each installation, since 0.9.26 Lazarus starts to use the user config path, the same for each installation, so suddenly new installations share the same config. Also a simple "Lazarus --help" does not "help" too much ;) and navigating around wiki looking for "config folder" does not help also. It could be solved using a simple question, I think.

GG> You are experimenting with new software, so I would assume you know GG> what you are doing!

That's a nice assumption ;-)

GG> I have setup two desktop icons with the following details. I can GG> easily switch between Lazarus versions and they don't affect each GG> others settings.

That's fine when you know that the command line accepts the "--pcp" parameter. Had you tried to find that information in the wiki using a problem description ? Even using primary-config-path as keyword, one of the good matches appears at position 15.

It's not a problem for me anymore ;)

Best regards, JoshyFun

Reply by email

Graeme Geldenhuys
to JoshyFun
JoshyFun wrote
fact I'm using 4NT much more than file explorer. But in pre 0.9.26 versions the config is tied to each installation, since 0.9.26 Lazarus

So let the pre-0.9.26 lazarus continue using it's default location (seeing that you can't change it). And for all newer Lazarus releases, use your own custom locations. Maybe config dir which contains a version number.

That's fine when you know that the command line accepts the "--pcp" parameter. Had you tried to find that information in the wiki using a problem description ? Even using primary-config-path as keyword, one of the good matches appears at position 15.

To be honest, I never even thought of going to the wiki site. I simply ran './azarus --help' and read the on-screen instructions.

--------------------------------------------
graemeg at graeme:lazarus$ ./lazarus --help
lazarus [options] <project-filename>

IDE Options:

--help or -?
this help message

--primary-config-path=
<path>
or
--pcp=
<path>
primary config directory, where Lazarus stores its config files. Default is /home/graemeg/.lazarus

--secondary-config-path=
<path>
or
--scp=
<path>
secondary config directory, where Lazarus searches for config template files. Default is /etc/lazarus [...]
--------------------------------------------

The above messages were pretty clear to me, and told me exactly what I wanted to know.

Regards,
- Graeme -

_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/

Reply by email

JoshyFun
to Graeme Geldenhuys

Hello Graeme,

Wednesday, December 3, 2008, 2:09:16 PM, you wrote:

GG> So let the pre-0.9.26 lazarus continue using it's default location GG> (seeing that you can't change it). And for all newer Lazarus releases, GG> use your own custom locations. Maybe config dir which contains a GG> version number.

I'm doing just that, but that's not the "problem", nor my problem at all now. A Delphi user expect that each version run it's own config (at least up to D7, where I stop using it).

> That's fine when you know that the command line accepts the "--pcp" > parameter. Had you tried to find that information in the wiki using a > problem description ? Even using primary-config-path as keyword, one > of the good matches appears at position 15.

GG> To be honest, I never even thought of going to the wiki site. I simply GG> ran './azarus --help' and read the on-screen instructions. [...]
GG> The above messages were pretty clear to me, and told me exactly what I GG> wanted to know.

Remember that I'm talking about Windows version ? ;) And my smile at the end of the "not very help"...

C:\lazarus_0.9.26\lazarus.exe --help

Windows window showing "File not open". It works fine in 0.9.27 version, well if you can follow the attached capture ;)

Best regards, JoshyFun -------------- next part -------------- A non-text attachment was scrubbed... Name: laz--help.png Type: image/png Size: 17435 bytes Desc: not available Url : http://www.lazarus.freepascal.org/pipermail/lazarus/attachments/20081203/75fba2ce/attachment-0001.png

Reply by email