Sign in Join

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

Mailing lists / lazarus / 2011-03

Lazbuild and configuration files

4 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

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

Mark Morgan Lloyd

I've got a handful of systems here where, for various reasons, I run lazbuild rather than the IDE when I want to compile a project for test purposes. In general this works well.

A couple of days ago I ran lazbuild on a system where I do occasionally run the IDE, but found myself in trouble because I had changed the name of the Lazarus directory.

In a situation like this, the options appear to be (i) run the IDE or (ii) edit the XML configuration file by hand. Is there a (iii), e.g. a parameter to lazbuild that tells it to update a configuration file before it uses its contents?

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email

Mattias Gaertner
to Mark Morgan Lloyd
Show quoted text 12 lines
I've got a handful of systems here where, for various reasons, I run lazbuild rather than the IDE when I want to compile a project for test purposes. In general this works well. A couple of days ago I ran lazbuild on a system where I do occasionally run the IDE, but found myself in trouble because I had changed the name of the Lazarus directory. In a situation like this, the options appear to be (i) run the IDE or (ii) edit the XML configuration file by hand. Is there a (iii), e.g. a parameter to lazbuild that tells it to update a configuration file before it uses its contents?

Not yet.

Mattias

Reply by email

Marcos Douglas
to Mark Morgan Lloyd: I've got a handful of systems here where, for various reasons, I run lazbuild rather than…
Mark Morgan Lloyd wrote 12 lines
I've got a handful of systems here where, for various reasons, I run lazbuild rather than the IDE when I want to compile a project for test purposes. In general this works well. A couple of days ago I ran lazbuild on a system where I do occasionally run the IDE, but found myself in trouble because I had changed the name of the Lazarus directory. In a situation like this, the options appear to be (i) run the IDE or (ii) edit the XML configuration file by hand. Is there a (iii), e.g. a parameter to lazbuild that tells it to update a configuration file before it uses its contents?

I use my Lazarus in my PC, of course, and from HD external too. This HD always have to execute in W: driver, on Windows. So, I made a BAT to not have config files errors:
@echo off

set mypath=%cd%
set mylaz=%mypath%\ide\laz\0.9.29

cd \

if /i %cd% equ W:\ (
cd %mylaz%
start lazarus --pcp=%mypath%\ide\laz\config
) else (
echo "invalid driver"
pause
)

Marcos Douglas

Reply by email

Mark Morgan Lloyd
to Marcos Douglas
Marcos Douglas wrote 32 lines
On Fri, Mar 18, 2011 at 7:39 PM, Mark Morgan Lloyd wrote: > I've got a handful of systems here where, for various reasons, I run > lazbuild rather than the IDE when I want to compile a project for test > purposes. In general this works well. > > A couple of days ago I ran lazbuild on a system where I do occasionally run > the IDE, but found myself in trouble because I had changed the name of the > Lazarus directory. > > In a situation like this, the options appear to be (i) run the IDE or (ii) > edit the XML configuration file by hand. Is there a (iii), e.g. a parameter > to lazbuild that tells it to update a configuration file before it uses its > contents? I use my Lazarus in my PC, of course, and from HD external too. This HD always have to execute in W: driver, on Windows. So, I made a BAT to not have config files errors: @echo off set mypath=%cd% set mylaz=%mypath%\ide\laz\0.9.29 cd \ if /i %cd% equ W:\ ( cd %mylaz% start lazarus --pcp=%mypath%\ide\laz\config ) else ( echo "invalid driver" pause )

I've got several different versions of Lazarus, each with its preferred version of FPC and each started with --pcp. That works fine, but then I went and changed a directory name from \usr\local\share\lazarus-testing to \usr\local\share\lazarus-newstable and recompiled, whereupon all the binaries were fine but the configuration file needed changing.

Now it happens that on that machine I could have run the IDE to make the changes, but on a couple of others doing that would be inconvenient or impossible.

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email