Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread Honza
2012/4/3 Michael Van Canneyt mich...@freepascal.org:


 On Tue, 3 Apr 2012, waldo kitty wrote:

 On 4/3/2012 09:57, michael.vancann...@wisa.be wrote:

 On Tue, 3 Apr 2012, fred f wrote:

 I need to set up LIBOVERLAY_SCROLLBAR=0 on Ubuntu 64bit, but there LIBC
 is not
 supported and therefore I am looking for SetEnv which I can use on 64bit
 Linux.

 SysUtils contains only GetEnvironmentVariable, but not Set...


 That's not how it works on Unix/Linux.

 You must always set up environment variables before a program starts.
 When starting a process, the environment for that process is started and
 is
 then immutable for the duration of the process.


 ewww... so no fancy capabilities like we could do in the old DOS days
 where we could change the base environment as well as cloning it with
 changes for child processes??? if so, that's blows several of my porting
 projects up :? :(


 Not possible on Posix platforms.

Now I'm confused. AFAICS
(http://pubs.opengroup.org/onlinepubs/007904975/functions/setenv.html)
Posix setenv() allows a process to mutate its environment variables.

I probably misunderstood something, can someone enlighten me please?

-- jan

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Strange dependency of units

2012-04-04 Thread Michael Schnell

On 04/03/2012 04:26 PM, Bart wrote:
I have learned over the past years, that it makes sense to use 
sepreate units (or ifdef them) for GUI (and thus possibly widgetset) 
related code and pure pascal (as in: non-GUI non-LCL).


The separating GUI and business code paradigm is under permanent 
discussion in the software industry since years.


Separation is very advantages for large and/or professional projects.



But it contradicts the idea of RAD (Rapid Application Development) 
that initially drove the invention of Delphi.


Same is very useful for projects dedicated to starting, 
learning/teaching, prototyping, testing Pascal code, testing attached 
devices, staying small, etc. IMHO this is true by far the most projects 
ever started.




Very unfortunately many 3rd party products available for free or payed 
don't adhere to the separating GUI and business code paradigm.


Unfortunately many projects start small and at some point get so big 
that separating GUI and business code  would be appropriate, but with an 
advanced project, the effort is a lot harder to do.


This is especially true if it it turns out that the final product needs 
to be used as a service/daemon.


Here the upcoming Custom Drawn Widget set some day might help to allow 
for some kind of GUI remoting, and by simply switching the Lazarus 
Widget Type the GUI can be cut off.


-Michael

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Michael Schnell

On 04/03/2012 03:31 PM, Mattias Gaertner wrote:


What part of offline wiki do you want to help with?
Those that I can be sure of being included in the online help by some 
automated mechanism. Here of course my theme would be Queued Mainthread 
Events, Threads-communication, and friends.


-Michael
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Michael Schnell

On 04/04/2012 10:38 AM, Michael Schnell wrote:

On 04/03/2012 03:31 PM, Mattias Gaertner wrote:


What part of offline wiki do you want to help with?
Those that I can be sure of being included in the online help by some 
automated mechanism.

Grr. Of course I meant to write offline help.

I was confused by your mentioning offline Wiki. What do you mean by 
this ?


-Michael
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Michael Schnell

On 04/03/2012 04:26 PM, Felipe Monteiro de Carvalho wrote:
Or I am missing something? 
AFAIU, some parts of the online documentation can't be included in the 
offline help yet. (There should be help (at least) on the topics:  
Using the help system, IDE, FPC Language, RTL functions LCL 
functions.)


To me the biggest problem is, that there is no automatic process (yet), 
and seemingly not even agreed upon, to create all these topics of the 
offline help - that have been updated by helpful contributors, and 
included into some svn by the powers - by means of an (at least 
partly) automated command.


I really don't want to discuss this here (again), but I'd like to stay 
tuned in case the powers decide upon such a process.


-Michael


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 04 Apr 2012 10:38:13 +0200
Michael Schnell mschn...@lumino.de wrote:

 On 04/03/2012 03:31 PM, Mattias Gaertner wrote:
 
  What part of offline wiki do you want to help with?
 Those that I can be sure of being included in the online help by some 
 automated mechanism. Here of course my theme would be Queued Mainthread 
 Events, Threads-communication, and friends.

All normal pages and images will be included in the offline wiki.
Special pages, like help, random, category, user, user_talk will not be
included.
All translated pages will be included as well.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 04 Apr 2012 10:40:49 +0200
Michael Schnell mschn...@lumino.de wrote:

 On 04/04/2012 10:38 AM, Michael Schnell wrote:
  On 04/03/2012 03:31 PM, Mattias Gaertner wrote:
 
  What part of offline wiki do you want to help with?
  Those that I can be sure of being included in the online help by some 
  automated mechanism.
 Grr. Of course I meant to write offline help.
 
 I was confused by your mentioning offline Wiki. What do you mean by 
 this ?

A snapshot of the wiki with a search.


Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread michael . vancanneyt



On Wed, 4 Apr 2012, Honza wrote:


2012/4/3 Michael Van Canneyt mich...@freepascal.org:



On Tue, 3 Apr 2012, waldo kitty wrote:


On 4/3/2012 09:57, michael.vancann...@wisa.be wrote:


On Tue, 3 Apr 2012, fred f wrote:


I need to set up LIBOVERLAY_SCROLLBAR=0 on Ubuntu 64bit, but there LIBC
is not
supported and therefore I am looking for SetEnv which I can use on 64bit
Linux.

SysUtils contains only GetEnvironmentVariable, but not Set...



That's not how it works on Unix/Linux.

You must always set up environment variables before a program starts.
When starting a process, the environment for that process is started and
is
then immutable for the duration of the process.



ewww... so no fancy capabilities like we could do in the old DOS days
where we could change the base environment as well as cloning it with
changes for child processes??? if so, that's blows several of my porting
projects up :? :(



Not possible on Posix platforms.


Now I'm confused. AFAICS
(http://pubs.opengroup.org/onlinepubs/007904975/functions/setenv.html)
Posix setenv() allows a process to mutate its environment variables.

I probably misunderstood something, can someone enlighten me please?


You can always modify them (it's just data in memory), but modifying them 
will only change your private view of the variables. 
The changes you make will not propagate to libraries or newly started processes.


Therefor it makes no sense to change them, and the FPC runtime does not allow
it. If we did allow it, people would expect DOS/Windows like behaviour, which
we simply cannot provide.

If you read the second part of the provided URL, you'll see that the POSIX
group recognises that the behaviour of setenv() is problematical.

The URL points - for restrictions - to the exec function

http://pubs.opengroup.org/onlinepubs/007904975/functions/exec.html

Where it says:

For those forms not containing an envp pointer ( execl(), execv(), execlp(),
and execvp()), the environment for the new process image shall be taken from
the external variable environ in the calling process.

Etc etc etc.

Michael.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Michael Schnell

On 04/04/2012 11:02 AM, Mattias Gaertner wrote:

All normal pages and images will be included in the offline wiki.

Does this mean that the offline Wiki is the upcoming Offline Help ?

Will it be possible to press F1 on a word and the appropriate offline 
Wiki page will be displayed ? (I understand that it is possible to 
create a help plugin for the Lazarus IDE that might be able to perform 
this task)


-Michael

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Rimmert Ooink
I'm sorry to mix in a discussion, but I wonder, whats the point of having
an offline copy of the wiki by default?

Why  not simply a OpenURL(online-wiki-url); when the user presses F1?

And in de menu help - help a simple form stating the help can only be
viewed when there is a active internet connection.
That simple form may also contain two links (Clickable labels) 1 being a
link to the wiki and 2 being a link to the wikipage explaining how to
download a copy of the help and modify your lazarus to use it.

On Wed, Apr 4, 2012 at 12:09 PM, Michael Schnell mschn...@lumino.de wrote:

 On 04/04/2012 11:02 AM, Mattias Gaertner wrote:

 All normal pages and images will be included in the offline wiki.

 Does this mean that the offline Wiki is the upcoming Offline Help ?

 Will it be possible to press F1 on a word and the appropriate offline
 Wiki page will be displayed ? (I understand that it is possible to create
 a help plugin for the Lazarus IDE that might be able to perform this task)

 -Michael


 --
 __**_
 Lazarus mailing list
 Lazarus@lists.lazarus.**freepascal.orgLazarus@lists.lazarus.freepascal.org
 http://lists.lazarus.**freepascal.org/mailman/**listinfo/lazarushttp://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 04 Apr 2012 12:09:27 +0200
Michael Schnell mschn...@lumino.de wrote:

 On 04/04/2012 11:02 AM, Mattias Gaertner wrote:
  All normal pages and images will be included in the offline wiki.
 Does this mean that the offline Wiki is the upcoming Offline Help ?

No. The offline wiki is just the possibility to browse the wiki
offline.

Maybe it will eventually be integrated with the fpdoc help and
some more helps. But without the basic offline wiki that's just a
dream.

 
 Will it be possible to press F1 on a word and the appropriate offline 
 Wiki page will be displayed ? (I understand that it is possible to 
 create a help plugin for the Lazarus IDE that might be able to perform 
 this task)

There is no 1:1 mapping between word and wiki page.

At the moment there are two searches for the offline wiki pages. Both
have their pros and cons.

Mattias


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 4 Apr 2012 12:21:28 +0200
Rimmert Ooink laza...@ooink.net wrote:

 I'm sorry to mix in a discussion, but I wonder, whats the point of having
 an offline copy of the wiki by default?
 
 Why  not simply a OpenURL(online-wiki-url); when the user presses F1?

That's the current implementation.
Some users do not have a 24/7 good internet connection.

 
 And in de menu help - help a simple form stating the help can only be
 viewed when there is a active internet connection.
 That simple form may also contain two links (Clickable labels) 1 being a
 link to the wiki and 2 being a link to the wikipage explaining how to
 download a copy of the help and modify your lazarus to use it.

Yes, once the offline wiki is available some hints where to get it
will be added.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread Honza
2012/4/4  michael.vancann...@wisa.be:

Thank you for the help. Unfortunately I'm now confused even more. I
believe it's my fault, not yours.

 You can always modify them (it's just data in memory), but modifying them
 will only change your private view of the variables. The changes you make
 will not propagate to libraries or newly started processes.

If library means a .so (or .dll, but Windows are not that much of a
Posix system), then it is in in-process space, so I would think the
change *does* propagate, i.e. the change is observable by a call to
getenv() from inside a library function. About started processes see
below.


 Therefor it makes no sense to change them, and the FPC runtime does not
 allow
 it. If we did allow it, people would expect DOS/Windows like behaviour,
 which
 we simply cannot provide.

 If you read the second part of the provided URL, you'll see that the POSIX
 group recognises that the behaviour of setenv() is problematical.

 The URL points - for restrictions - to the exec function

 http://pubs.opengroup.org/onlinepubs/007904975/functions/exec.html

 Where it says:

 For those forms not containing an envp pointer ( execl(), execv(),
 execlp(),
 and execvp()), the environment for the new process image shall be taken from
 the external variable environ in the calling process.

The extrn char **environ (just environ from now on) points to the
environment variables of the executing process. Setenv may mutates
this environment. The various forms of exec do have either explicit
envp, so one can create any required environment vars set, or pass the
current environ, effectively enabling the inheritance of the (posibly
mutated) environment as an option.

The other forms, w/o envp, are defined to do exactly that, i.e. they
will use the current environ as their environment vars pointer,
effectively forcing the inheritance of the (possibly mutated)
environment. (the environment for the new process image shall be
taken from the external variable environ in the calling process)

I honestly presume I'm extra dumb today, anyway it still seems to me
like the opposite of what was said in this thread is true:

Environment variables can be mutated, the changes are visible in a
library (.so or and maybe in a .dll too) and with exec() one can
choose if to pass a new environment or if the current one is to be
inherited.

Apologies, I don't want to sound like a troll, I just want to figure
out why the same Posix specs can be seen/interpreted in two mutually
exclusive ways and naturally - which one is the correct
interpretation.

PS: I've just cross-checked with some other language (Go if you are
curious) and its std library and there seems to work all like I think
the Posix specs says (http://golang.org/pkg/os/#Setenv and
http://golang.org/pkg/os/exec/#Cmd) and I think the high level (and
cross platform, Go programs should behave identically on Linux and
Windows) wrapper of the Go 'os' package just reiterates the standard
Posix behavior in a libc independent way.

-- jan

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread michael . vancanneyt



On Wed, 4 Apr 2012, Honza wrote:


2012/4/4  michael.vancann...@wisa.be:

Thank you for the help. Unfortunately I'm now confused even more. I
believe it's my fault, not yours.


You can always modify them (it's just data in memory), but modifying them
will only change your private view of the variables. The changes you make
will not propagate to libraries or newly started processes.


If library means a .so (or .dll, but Windows are not that much of a
Posix system), then it is in in-process space, so I would think the
change *does* propagate, i.e. the change is observable by a call to
getenv() from inside a library function. About started processes see
below.


Typically, libraries will read the environment variables at startup.
Any subsequent change to the environment will not have any effect.


Therefor it makes no sense to change them, and the FPC runtime does not
allow
it. If we did allow it, people would expect DOS/Windows like behaviour,
which
we simply cannot provide.

If you read the second part of the provided URL, you'll see that the POSIX
group recognises that the behaviour of setenv() is problematical.

The URL points - for restrictions - to the exec function

http://pubs.opengroup.org/onlinepubs/007904975/functions/exec.html

Where it says:

For those forms not containing an envp pointer ( execl(), execv(),
execlp(),
and execvp()), the environment for the new process image shall be taken from
the external variable environ in the calling process.


The extrn char **environ (just environ from now on) points to the
environment variables of the executing process. Setenv may mutates
this environment. The various forms of exec do have either explicit
envp, so one can create any required environment vars set, or pass the
current environ, effectively enabling the inheritance of the (posibly
mutated) environment as an option.

The other forms, w/o envp, are defined to do exactly that, i.e. they
will use the current environ as their environment vars pointer,


Not the current.

The EXTERNAL variable environ, i.e. the one that the kernel passed on,
which cannot be modified. You can only modify your local copy.

Michael.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Martin

On 04/04/2012 11:26, Mattias Gaertner wrote:

There is no 1:1 mapping between word and wiki page.

At the moment there are two searches for the offline wiki pages. Both
have their pros and cons.




There are mappings between some IDE windows and wiki though

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread Honza
2012/4/4  michael.vancann...@wisa.be:
 Not the current.

 The EXTERNAL variable environ, i.e. the one that the kernel passed on,
 which cannot be modified. You can only modify your local copy.

14:00 myname@tux64:~/tmp/c$ ls
a.c  b.c
14:00 myname@tux64:~/tmp/c$ cat a.c
#include stdlib.h
#include stdio.h
#include unistd.h

main() {
char *e = getenv(MYVAR);
printf(a1: %s\n, e);
setenv(MYVAR, MYVALUE, 1);
e = getenv(MYVAR);
printf(a2: %s\n, e);
execv(./b.out, NULL);
}
14:00 myname@tux64:~/tmp/c$ cat b.c
#include stdlib.h
#include stdio.h

main() {
char *e = getenv(MYVAR);
printf(b: %s\n, e);
}

14:00 myname@tux64:~/tmp/c$ gcc -o a.out a.c  gcc -o b.out b.c  ls
a.c  a.out  b.c  b.out
14:00 myname@tux64:~/tmp/c$ ./a.out
a1: (null)
a2: MYVALUE
b: MYVALUE
14:00 myname@tux64:~/tmp/c$

-- jan

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner

Martin laza...@mfriebe.de hat am 4. April 2012 um 13:43 geschrieben:

 On 04/04/2012 11:26, Mattias Gaertner wrote:
  There is no 1:1 mapping between word and wiki page.
 
  At the moment there are two searches for the offline wiki pages. Both
  have their pros and cons.
 
 

 There are mappings between some IDE windows and wiki though


Yes. But he asked about F1 on a word, which I guess is about a word in the
source editor.

When the offline wiki works, I will check what needs to be done in the IDE to
switch.

Mattias
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread michael . vancanneyt



On Wed, 4 Apr 2012, Honza wrote:


2012/4/4  michael.vancann...@wisa.be:

Not the current.

The EXTERNAL variable environ, i.e. the one that the kernel passed on,
which cannot be modified. You can only modify your local copy.


14:00 myname@tux64:~/tmp/c$ ls
a.c  b.c
14:00 myname@tux64:~/tmp/c$ cat a.c
#include stdlib.h
#include stdio.h
#include unistd.h

main() {
char *e = getenv(MYVAR);
printf(a1: %s\n, e);
setenv(MYVAR, MYVALUE, 1);
e = getenv(MYVAR);
printf(a2: %s\n, e);
execv(./b.out, NULL);
}
14:00 myname@tux64:~/tmp/c$ cat b.c
#include stdlib.h
#include stdio.h

main() {
char *e = getenv(MYVAR);
printf(b: %s\n, e);
}

14:00 myname@tux64:~/tmp/c$ gcc -o a.out a.c  gcc -o b.out b.c  ls
a.c  a.out  b.c  b.out
14:00 myname@tux64:~/tmp/c$ ./a.out
a1: (null)
a2: MYVALUE
b: MYVALUE
14:00 myname@tux64:~/tmp/c$


Output of strace:

brk(0)  = 0x21a5000 
brk(0x21c6000)  = 0x21c6000 
write(1, a2: MYVALUE\n, 12a2: MYVALUE 
)   = 12 
execve(./b.out, [0], [/* 57 vars */]) = 0 
brk(0)  = 0x189e000 
access(/etc/ld.so.nohwcap, F_OK)  = -1 ENOENT (No such file or

directory)

As you can see, it uses execve() behind the scenes to be able to pass the 
modified
local environment.

This is libc-specific behaviour.

Michael.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread Honza
2012/4/4  michael.vancann...@wisa.be:
 Output of strace:

 brk(0)                                  = 0x21a5000 brk(0x21c6000)
                = 0x21c6000 write(1, a2: MYVALUE\n, 12a2: MYVALUE )
   = 12 execve(./b.out, [0], [/* 57 vars */]) = 0 brk(0)
                = 0x189e000 access(/etc/ld.so.nohwcap, F_OK)      = -1
 ENOENT (No such file or
 directory)

 As you can see, it uses execve() behind the scenes to be able to pass the
 modified
 local environment.

 This is libc-specific behaviour.

I think I cannot agree. IMO its a POSIX specified behavior. libc, at
least in this case, just implements the POSIX specs:
http://pubs.opengroup.org/onlinepubs/007904975/functions/exec.html

And as the ouptut of executing a.out shows, libc implements it
correctly: For those forms not containing an envp pointer ( execl(),
execv(), execlp(), and execvp()), the environment for the new process
image shall be taken from the external variable environ in the calling
process., which libc achieves by calling execve() with the current
environ, effectively just filling the prescribed default.

'extern **char environ' is no [kernel] magic*, it's just an ordinary
pointer variable sitting in the process address space, it's only
special in that it gets set (by means which are not important to this
discussion) before main() starts executing.

-- jan

(*) One can e.g. happily set it directly to any other value:
14:41 myname@tux64:~/tmp/c$ cat a.c
#include stdlib.h
#include stdio.h
#include unistd.h

extern char **environ;

main() {
char *e = getenv(MYVAR);
printf(a1: %s\n, e);
setenv(MYVAR, MYVALUE, 1);
e = getenv(MYVAR);
printf(a2: %s\n, e);
environ = NULL;
e = getenv(MYVAR);
printf(a3: %s\n, e);
}
14:41 myname@tux64:~/tmp/c$ gcc a.c  ./a.out
a1: (null)
a2: MYVALUE
a3: (null)
14:41 myname@tux64:~/tmp/c$

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread michael . vancanneyt



On Wed, 4 Apr 2012, Honza wrote:


2012/4/4  michael.vancann...@wisa.be:

Output of strace:

brk(0)                                  = 0x21a5000 brk(0x21c6000)
               = 0x21c6000 write(1, a2: MYVALUE\n, 12a2: MYVALUE )
  = 12 execve(./b.out, [0], [/* 57 vars */]) = 0 brk(0)
               = 0x189e000 access(/etc/ld.so.nohwcap, F_OK)      = -1
ENOENT (No such file or
directory)

As you can see, it uses execve() behind the scenes to be able to pass the
modified
local environment.

This is libc-specific behaviour.


I think I cannot agree. IMO its a POSIX specified behavior. libc, at
least in this case, just implements the POSIX specs:
http://pubs.opengroup.org/onlinepubs/007904975/functions/exec.html

And as the ouptut of executing a.out shows, libc implements it
correctly: For those forms not containing an envp pointer ( execl(),
execv(), execlp(), and execvp()), the environment for the new process
image shall be taken from the external variable environ in the calling
process., which libc achieves by calling execve() with the current
environ, effectively just filling the prescribed default.


I do not agree with this interpretation.

First of all, you are calling execv() in your code, not execve(). 
That libc changes this to execve() is IMHO not permissible.

So all bets and conclusions are off from that point onwards.

Secondly, we interpret differently 'external variable environ'. (note the
'external'). For me this clearly means the original environment as passed 
on to the current process. Which probably is what happens if you'd call the 
execv() kernel function, although that would need testing.


Thirdly, the 2 referenced pages clearly indicate that the whole environment
handling is hairy at best in corner cases like this.

And lastly: We on purpose do not follow Libc; 
Otherwise we'd simply have built the whole RTL on top of it. 
So we are not under any obligation to mimic its behaviour.


Michael.--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread waldo kitty

On 4/4/2012 08:02, Honza wrote:

2012/4/4michael.vancann...@wisa.be:

Not the current.

The EXTERNAL variable environ, i.e. the one that the kernel passed on,
which cannot be modified. You can only modify your local copy.


14:00 myname@tux64:~/tmp/c$ ls
a.c  b.c

[trim]

14:00 myname@tux64:~/tmp/c$ ./a.out
a1: (null)
a2: MYVALUE
b: MYVALUE
14:00 myname@tux64:~/tmp/c$


your example shows a shell... i may have added to the confusion because a trick 
i recall us doing in the DOS days was to change the master environment... after 
running ./a.out, do you see your MYVAR in the environment via set | more or 
export | more or whatever?? most likely you will not see your MYVAR at that 
point after a.out finishes execution... i believe this is what was being pointed 
to as not supported...


my apologies if i added confusion...

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] offline Wiki Help

2012-04-04 Thread Michael Schnell
(Moving this discussion out of the inappropriate  Lazarus 1.0 is 
branched topic.)


Seemingly there are efforts to introduce an offline Wiki type of 
offline help, thus providing a maybe more versatile alternative are an 
addition to the currently available variants such as the CHM help and 
the DocView add-on.


I think this is a very interesting move.

Is it easy to get and install a standard local Wiki reader ? Or is 
somebody creating one in Pascal code ?


It would be great to have a wiki page about this.

I'd like to see comments about this issue from those who drove the 
recent huge discussion on offline help (Graeme, DoDi, Mattias, Sven, 
Marco, Michael vC...)


-Michael



Martin laza...@mfriebe.de hat am 4. April 2012 um 13:43 geschrieben:

 On 04/04/2012 11:26, Mattias Gaertner wrote:
  There is no 1:1 mapping between word and wiki page.
 
  At the moment there are two searches for the offline wiki pages. Both
  have their pros and cons.
 
 

 There are mappings between some IDE windows and wiki though

Yes. But he asked about F1 on a word, which I guess is about a word in 
the source editor.


When the offline wiki works, I will check what needs to be done in the 
IDE to switch.


Mattias



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread Honza
2012/4/4  michael.vancann...@wisa.be:
 I do not agree with this interpretation.

 First of all, you are calling execv() in your code, not execve(). That libc
 changes this to execve() is IMHO not permissible.
 So all bets and conclusions are off from that point onwards.

Why not permissible? The POSIX specs describe what the semantics
and/or effects of executing a defined function are. The semantics and
effects of libc's execv() are what is said about it in POSIX. I don't
see any 'off' conclusion derivable ;-)

 Secondly, we interpret differently 'external variable environ'. (note the
 'external'). For me this clearly means the original environment as passed on
 to the current process.

From the moment main() starts executing, environ is the process
current environment. Initially, as it was passed, after any mutation
well, that mutated state. No copy of the original environment of a
process exists anywhere in the process nor in the kernel. A copy might
still exists, though not necessarily, in the originating process, but
that is anyway not accessible by the new/now executing process (modulo
shmem etc.).

Also the 'external variable' is just a reference to the C
specification, i.e. that's the way C says to the linker to find the
variable defined elsewhere, not in this compilation unit/produced
object code.

 Which probably is what happens if you'd call the
 execv() kernel function, although that would need testing.

I can perhaps save someone's time, as there's no execv() kernel call.
There's only execve() and that's why a POSIX compliant libc calls
execve() with the current value of environ.

 Thirdly, the 2 referenced pages clearly indicate that the whole environment
 handling is hairy at best in corner cases like this.

Perhaps, not relevant to us, IMO.

 And lastly: We on purpose do not follow Libc; Otherwise we'd simply have
 built the whole RTL on top of it. So we are not under any obligation to
 mimic its behaviour.

No one said so. Actually that's just fine. The discussion went about
various claims from various people that in POSIX the environment is
either immutable at all, or the mutations are not visible in
libraries, or not inherited on exec() - we (you and me) were not
discussing FPC at all, IMO.

AFAICS, all the above claims were not true. Actually it's the first
time ever I saw such claims, as mutating environment in a POSIX
program, because of child process inherits that by default, is so
common, that I have never even thought before of a possibility it
could be otherwise, so I wanted to verify, to my own benefit, how
that stuff I never really looked into actually works ;-)

-- jnml

PS: I think there's no reason why a SetEnv should not by available in
sysutils (or system, or ...) on POSIX systems, and as other languages
demonstrate, such call can work seamlessly on Windows too. And as FPC
is a cross platform compiler Actually I think if there is GetEnv
somewhere and its natural counterpart SetEnv is nowhere, then it's
quite surprising - don't know about a similar example with some other
language.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] offline Wiki Help

2012-04-04 Thread Mattias Gaertner
On Wed, 04 Apr 2012 15:30:38 +0200
Michael Schnell mschn...@lumino.de wrote:

 (Moving this discussion out of the inappropriate  Lazarus 1.0 is 
 branched topic.)
 
 Seemingly there are efforts to introduce an offline Wiki type of 
 offline help, thus providing a maybe more versatile alternative are an 
 addition to the currently available variants such as the CHM help and 
 the DocView add-on.
 
 I think this is a very interesting move.
 
 Is it easy to get and install a standard local Wiki reader ? Or is 
 somebody creating one in Pascal code ?

All readers are pascal code.

 
 It would be great to have a wiki page about this.

All are currently only in proof of concept phase.
We have to find someone to work on this.

 
 I'd like to see comments about this issue from those who drove the 
 recent huge discussion on offline help (Graeme, DoDi, Mattias, Sven, 
 Marco, Michael vC...)


Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] offline Wiki Help

2012-04-04 Thread Michael Schnell

On 04/04/2012 03:40 PM, Mattias Gaertner wrote:
All readers are pascal code. 

Great, but seems like a lot of work

This would enable using the IDE's help viewer interface to launch it. 
Great again.


Maybe this enables seamlessly using the online and offline Wiki content. 
Another Great added.



Obviously adding a kind of Keywords to the Wiki content would enable 
F1-search for words in the Editor and keywords translated Types from 
variable/implementation names.


Obviously it's a lot easier to automatically translate FPDoc content to 
Wiki than vice-versa.


Obviously this would make common users more likely to be help contributors.

-Michael

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Make unreadable names into bunary

2012-04-04 Thread Kjow
Hi all,

I would make unreadable functions/components/classes/etc names into
the binary built.
I noticed that with an hex editor I can see things like TButton,
width, heigh etc.
Avoiding this, could make also more difficul a reverse engeneering
with the binary.

Is there an option to enable this in compiling?

Thank you,
Kjow

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Make unreadable names into bunary

2012-04-04 Thread Reinier Olislagers
On 4-4-2012 16:10, Kjow wrote:
 Hi all,
 
 I would make unreadable functions/components/classes/etc names into
 the binary built.
 I noticed that with an hex editor I can see things like TButton,
 width, heigh etc.
 Avoiding this, could make also more difficul a reverse engeneering
 with the binary.
 
 Is there an option to enable this in compiling?

That's called obfuscating the code.
See tools/options/jcf format settings/obfuscate to see what that does.
Haven't tried it, probably requires codetools/jedi code format packages...

Regards,
Reinier

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread michael . vancanneyt



On Wed, 4 Apr 2012, Honza wrote:


2012/4/4  michael.vancann...@wisa.be:

I do not agree with this interpretation.

First of all, you are calling execv() in your code, not execve(). That libc
changes this to execve() is IMHO not permissible.
So all bets and conclusions are off from that point onwards.


Why not permissible? The POSIX specs describe what the semantics
and/or effects of executing a defined function are. The semantics and
effects of libc's execv() are what is said about it in POSIX. I don't
see any 'off' conclusion derivable ;-)





Secondly, we interpret differently 'external variable environ'. (note the
'external'). For me this clearly means the original environment as passed on
to the current process.



From the moment main() starts executing, environ is the process

current environment. Initially, as it was passed, after any mutation
well, that mutated state. No copy of the original environment of a
process exists anywhere in the process nor in the kernel.


I think you'll find that the environment block is copied as soon as you
add a new environment variable.

Since the original environment as passed by the kernel is not in the heap, 
so how could you add something to it, except by copying the array

of pointers and enlarging it ?

What happens to it in a library, is currently open for speculation.


 A copy might
still exists, though not necessarily, in the originating process, but
that is anyway not accessible by the new/now executing process (modulo
shmem etc.).

Also the 'external variable' is just a reference to the C
specification, i.e. that's the way C says to the linker to find the
variable defined elsewhere, not in this compilation unit/produced
object code.


I agree a C person might interpret it like that.




Which probably is what happens if you'd call the
execv() kernel function, although that would need testing.


I can perhaps save someone's time, as there's no execv() kernel call.
There's only execve() and that's why a POSIX compliant libc calls
execve() with the current value of environ.


I stand corrected on this front.




Thirdly, the 2 referenced pages clearly indicate that the whole environment
handling is hairy at best in corner cases like this.


Perhaps, not relevant to us, IMO.


And lastly: We on purpose do not follow Libc; Otherwise we'd simply have
built the whole RTL on top of it. So we are not under any obligation to
mimic its behaviour.


No one said so. Actually that's just fine. The discussion went about
various claims from various people that in POSIX the environment is
either immutable at all, or the mutations are not visible in
libraries, or not inherited on exec() - we (you and me) were not
discussing FPC at all, IMO.


Yes. I was sloppy in my terminology.



AFAICS, all the above claims were not true. Actually it's the first
time ever I saw such claims, as mutating environment in a POSIX
program, because of child process inherits that by default, is so
common, that I have never even thought before of a possibility it
could be otherwise, so I wanted to verify, to my own benefit, how
that stuff I never really looked into actually works ;-)


I think the confusion came from the original posters request to 
modify the 'global environment', which - I hope you'll agree -
is not possible on Posix, as the environment is passed on from 
process to process using execve.


So, my conclusions:

* The SetEnvironment() call on windows will do something totally
  different than what happens under Posix, and the Windows behaviour
  cannot be mimicked. Which is why it isn't in sysutils.

* A posixy SetEnv() could be implemented for the Unix layer, to mimic
  Libc. But I think it would not be usable for libraries, since the
  environment copy of the RTL would not be shareable with the library
  without pulling in the C memory manager.
  At best it could be used to be passed on to a new process.

Michael.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] lazbuild build IDE profiles

2012-04-04 Thread waldo kitty

On 4/2/2012 18:14, Mattias Gaertner wrote:

On Mon, 02 Apr 2012 15:10:18 -0400
waldo kittywkitt...@windstream.net  wrote:


On 3/31/2012 17:44, waldo kitty wrote:

On 3/31/2012 13:01, Mattias Gaertner wrote:

Can you send me the exact commands and
your .lazarus/miscellaneousoptions.xml?
There were a lot of mails and I want to make sure I have the latest
version.


i will send off list...


we're getting closer, i think :)


yes, definitely closer... except that normal ide and optimized ide are 
coming out the same as debug ide :(



C:\freepascaldir laz\lazarus-*.exe
 Volume in drive C has no label.
 Volume Serial Number is 9CAB-2377

 Directory of C:\freepascal\laz

04/04/2012  10:38   76,238,268 lazarus-debug.exe
04/04/2012  10:45   76,238,268 lazarus-normal.exe
04/04/2012  10:54   76,238,268 lazarus-optimized.exe
   3 File(s)228,714,804 bytes


2506 ***
2507 *   Debug IDE
2508 *   CMD: lazbuild.exe --build-ide= --build-mode=debug ide
2509 *
2510 primary config path: C:\Documents and Settings\e3br42x1\Local 
Settings\Application Data\lazarus

2511 Building Lazarus IDE with profile Debug IDE
[...]
2823 Clean Lazarus Source completed
2824 TLazPackageGraph.CheckIfCurPkgOutDirNeedsCompile  Missing state file for 
FCL 1.0.1: C:\freepascal\laz\packager\units\i386-win32\FCL.compiled
2825 [TExternalToolList.Run] 
CmdLine=C:\freepascal\fpc\2.4.5\bin\i386-win32\fpc.exe -B  -MObjFPC -Scghi -O1 
-g -gl -vewnhi -l -FuC:\freepascal\laz\packager\registration\ 
-FUC:\freepascal\laz\packager\units\i386-win32\ -gw -gl -godwarfsets -gh -gt -Co 
-Cr -Ci -Sa -dDebug -dVerbose fcllaz.pas 
WorkDir=C:\freepascal\laz\packager\registration\
2826 Hint: Start of reading config file 
C:\freepascal\fpc\2.4.5\bin\i386-win32\fpc.cfg

2827 Compiling Debug Version
[...]
4228 Linking C:\freepascal\laz\lazarus.new.exe
4229 269773 lines compiled, 189.4 sec , 9361136 bytes code, 4238760 bytes data
4230 2 warning(s) issued


4245 ***
4246 *   Normal IDE
4247 *   CMD: lazbuild.exe --build-ide= --build-mode=normal ide
4248 *
4249 primary config path: C:\Documents and Settings\e3br42x1\Local 
Settings\Application Data\lazarus

4250 Building Lazarus IDE with profile Normal IDE
[...]
4562 Clean Lazarus Source completed
4563 TLazPackageGraph.CheckIfCurPkgOutDirNeedsCompile  Missing state file for 
FCL 1.0.1: C:\freepascal\laz\packager\units\i386-win32\FCL.compiled
4564 [TExternalToolList.Run] 
CmdLine=C:\freepascal\fpc\2.4.5\bin\i386-win32\fpc.exe -B  -MObjFPC -Scghi -O1 
-g -gl -vewnhi -l -FuC:\freepascal\laz\packager\registration\ 
-FUC:\freepascal\laz\packager\units\i386-win32\ -gw -gl -godwarfsets -gh -gt -Co 
-Cr -Ci -Sa -dDebug -dVerbose fcllaz.pas 
WorkDir=C:\freepascal\laz\packager\registration\
4565 Hint: Start of reading config file 
C:\freepascal\fpc\2.4.5\bin\i386-win32\fpc.cfg

4566 Compiling Debug Version
[...]
5967 Linking C:\freepascal\laz\lazarus.new.exe
5968 269773 lines compiled, 196.0 sec , 9361136 bytes code, 4238760 bytes data
5969 2 warning(s) issued


5984 ***
5985 *   Optimized IDE
5986 *   CMD: lazbuild.exe --build-ide= --build-mode=optimized ide
5987 *
5988 primary config path: C:\Documents and Settings\e3br42x1\Local 
Settings\Application Data\lazarus

5989 Building Lazarus IDE with profile Optimized IDE
[...]
6301 Clean Lazarus Source completed
6302 TLazPackageGraph.CheckIfCurPkgOutDirNeedsCompile  Missing state file for 
FCL 1.0.1: C:\freepascal\laz\packager\units\i386-win32\FCL.compiled
6303 [TExternalToolList.Run] 
CmdLine=C:\freepascal\fpc\2.4.5\bin\i386-win32\fpc.exe -B  -MObjFPC -Scghi -O1 
-g -gl -vewnhi -l -FuC:\freepascal\laz\packager\registration\ 
-FUC:\freepascal\laz\packager\units\i386-win32\ -gw -gl -godwarfsets -gh -gt -Co 
-Cr -Ci -Sa -dDebug -dVerbose fcllaz.pas 
WorkDir=C:\freepascal\laz\packager\registration\
6304 Hint: Start of reading config file 
C:\freepascal\fpc\2.4.5\bin\i386-win32\fpc.cfg

6305 Compiling Debug Version
[...]
7706 Linking C:\freepascal\laz\lazarus.new.exe
7707 269773 lines compiled, 298.3 sec , 9361136 bytes code, 4238760 bytes data
7708 2 warning(s) issued


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] SetEnv on Linux 64bit

2012-04-04 Thread Marco van de Voort
On Wed, Apr 04, 2012 at 04:22:24PM +0200, michael.vancann...@wisa.be wrote:
 
 I think you'll find that the environment block is copied as soon as you
 add a new environment variable.

Afaik BSD copies it in the startup code before main() executes.
 

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Make unreadable names into bunary

2012-04-04 Thread Marco van de Voort
On Wed, Apr 04, 2012 at 04:10:46PM +0200, Kjow wrote:
 I would make unreadable functions/components/classes/etc names into
 the binary built.
 I noticed that with an hex editor I can see things like TButton,
 width, heigh etc.

Yes. These are needed to stream forms.

 Avoiding this, could make also more difficul a reverse engeneering
 with the binary.

On Windows, use tools that encrypt the whole binary. They usually allow
resources to keep working. (at least they do with delphi)

 Is there an option to enable this in compiling?

No, the form based streaming is a corner stone of the designer.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Keys attached to IDE functions

2012-04-04 Thread Jürgen Hestermann
In the IDE Options the key mappings can be searched (and changed) very 
convenient. But when I filter for breakpoint I only get 3 functions 
listed. It took me quite a while to find out that the other breakpoint 
related functions are named break point (with a space in the middle). 
I think that this word should be written in the same way (without space) 
for all cases.


Yet another issue that stroke me:
When searching for a key I often don't know how it is actually named. 
But I know which key invokes it. So I search for the function with find 
key combination. That's fine so far. Having read it's name I often want 
do see other related keys with similar names and do another search by 
name. But this does not work anymore. I have to exit from the options 
dialog and reinvoke it to do another search by name. Is that intended? 
It's a bit annoying.


And yet another one: When I want to assign a new key and this key is 
already assigned to another function I get a message telling me whether 
I still want to assign to this key. If I answer no, the whole assignment 
dialog is closed. Often I want to try another key but first I have to 
find my entry (it's not even highlighted anymore!) and double click on 
it again. This repeats for each unsuccessful try of keys. I am not sure 
whether this can be changed easily but if yes I (and hopefully others 
too) would appreciate if someone does.


And a last one: What is the difference between Toggle Breakpoint and 
Toggle view Breakpoints? The names sound identical but Toggle view 
Breakpoints only shows the list of breakpoints. And it does not toggle 
anything. Once called it does not close when I use the related key 
again. Shouldn't this be named Show Breakpoints or something like this?



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Reinier Olislagers
On 4-4-2012 18:02, Jürgen Hestermann wrote:
 In the IDE Options the key mappings can be searched (and changed) very
 convenient. But when I filter for breakpoint I only get 3 functions
 listed. It took me quite a while to find out that the other breakpoint
 related functions are named break point (with a space in the middle).
 I think that this word should be written in the same way (without space)
 for all cases.
Good point.

I'm sure patches for this would be welcome... and they would not be that
hard to create.

Regards,
Reinier

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Martin

On 04/04/2012 17:02, Jürgen Hestermann wrote:
In the IDE Options the key mappings can be searched (and changed) very 
convenient. But when I filter for breakpoint I only get 3 functions 
listed. It took me quite a while to find out that the other breakpoint 
related functions are named break point (with a space in the 
middle). I think that this word should be written in the same way 
(without space) for all cases.

+1



Yet another issue that stroke me:
When searching for a key I often don't know how it is actually named. 
But I know which key invokes it. So I search for the function with 
find key combination. That's fine so far. Having read it's name I 
often want do see other related keys with similar names and do another 
search by name. But this does not work anymore. I have to exit from 
the options dialog and reinvoke it to do another search by name. Is 
that intended? It's a bit annoying.


After searching for a key, the button has that key's name as caption.
Click the button, dialog will say unknown confirm  all are shown

Could be more intuitive with a clear button.




And yet another one: When I want to assign a new key and this key is 
already assigned to another function I get a message telling me 
whether I still want to assign to this key. If I answer no, the whole 
assignment dialog is closed. Often I want to try another key but first 
I have to find my entry (it's not even highlighted anymore!) and 
double click on it again. This repeats for each unsuccessful try of 
keys. I am not sure whether this can be changed easily but if yes I 
(and hopefully others too) would appreciate if someone does.



Are you on trunk?

the warning now has 3 buttons. And can return to the assign dialog

And a last one: What is the difference between Toggle Breakpoint and 
Toggle view Breakpoints? The names sound identical but Toggle view 
Breakpoints only shows the list of breakpoints. And it does not 
toggle anything. Once called it does not close when I use the related 
key again. Shouldn't this be named Show Breakpoints or something 
like this?


2nd needs to be renamed

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Jürgen Hestermann

Martin schrieb:

Are you on trunk?

No, what's this? Is it SVN?
Although  I would realy like to contribute more to Lazarus there are 2 
obstacles that are not easy to remove:


1.) Time. I would have to invest much more time which I currently can't 
afford.


2.) Knowledge. This is quite related to 1.) of course. Before I can do 
changes I need to know much more about the internals I think.



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Strange dependency of units

2012-04-04 Thread Jürgen Hestermann

Michael Schnell schrieb:
 Unfortunately many projects start small and at some point get so 
big that separating GUI and business code would be appropriate, but 
with an advanced project, the effort is a lot harder to do.


Of course, it would always be better to do it right in the first place. 
But often it is unknown how a project evolves and it may also be unknown 
in which way a project should be splitted (it's not only GUI and the 
rest). So it can be wasted time when investing more than needed to get 
a program running. I don't think that in sum it needs more time to do a 
rebuilt later.


The important think IMO is, that *if* a project grows and *if* one 
realizes that something needs rebuilding that then this time has to be 
available and that a rebuilt has to be done. I often changed complex 
parts of programs in a way I could not foresee at start.


And of course the time for bug fixing should be available too.


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Make unreadable names into bunary

2012-04-04 Thread Hans-Peter Diettrich

Kjow schrieb:

Hi all,

I would make unreadable functions/components/classes/etc names into
the binary built.
I noticed that with an hex editor I can see things like TButton,
width, heigh etc.


These names must match the declarations of the components and properties 
in LCL source code, so that the resource loader can find the registered 
classes and their published properties. This means that you have to use 
an obfuscated LCL, with obfuscated class and property names. The 
component names instead can be choosen freely, but I don't see an 
improvement when e.g. a TButton is renamed from Button1 to something 
else - its class name still will be readable.


Skilled hackers still may get many (type) names from a running 
executable, depending on the platform and widgetset. A decompiler (like 
IDA) also will reveal much of the source code, in all OO languages. This 
is why I never wrote an decompiler for Pascal (Delphi/FPC) binaries, to 
discourage sniffing in other peoples' apps.


In practice it's much easier to use a tool that compresses an executable 
into a self-expanding archive. Then the names can no more be found in 
the files on disk, and the size of the distributed files can become much 
smaller. And use the FPC and LCL *trunk* versions, to build your 
distributed apps, so that no decompiler will succeed in matching parts 
of the code with a *release* version of the libraries.


Graeme may praise fpGUI now again, which AFAIK does not use resources 
for the creation of the components on a form. Newer Delphi versions, in 
contrast, are much more verbose about application details, in the 
extended RTTI that is enabled by default and becomes part of every 
binary; turing it off is very complicated, must be done in every single 
unit, and for many types (classes, records...).


DoDi


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Martin

On 04/04/2012 17:31, Jürgen Hestermann wrote:

Martin schrieb:

Are you on trunk?

No, what's this? Is it SVN?

yes, latest svn (not fixes branch)

Although  I would realy like to contribute more to Lazarus there are 2 
obstacles that are not easy to remove:


1.) Time. I would have to invest much more time which I currently 
can't afford.


2.) Knowledge. This is quite related to 1.) of course. Before I can do 
changes I need to know much more about the internals I think.



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Martin

On 04/04/2012 17:53, Martin wrote:

On 04/04/2012 17:31, Jürgen Hestermann wrote:

Although  I would realy like to contribute more to Lazarus there are 
2 obstacles that are not easy to remove:


1.) Time. I would have to invest much more time which I currently 
can't afford.


2.) Knowledge. This is quite related to 1.) of course. Before I can 
do changes I need to know much more about the internals I think.




Actually this is a simple frame, and changing a resource string is not 
really requiring knowledge.


Open the dialog, select keymaps, and focus a control on the right (not 
the tree)


ctrl-shift F1
- look for the open... button

and you got the unit
(alternatively install package IDE explorer)

Find the button in the form, search in code, where the caption is set.


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Martin

On 04/04/2012 18:01, Martin wrote:

On 04/04/2012 17:53, Martin wrote:

On 04/04/2012 17:31, Jürgen Hestermann wrote:

Although  I would realy like to contribute more to Lazarus there are 
2 obstacles that are not easy to remove:


1.) Time. I would have to invest much more time which I currently 
can't afford.


2.) Knowledge. This is quite related to 1.) of course. Before I can 
do changes I need to know much more about the internals I think.




Actually this is a simple frame, and changing a resource string is not 
really requiring knowledge.


Open the dialog, select keymaps, and focus a control on the right (not 
the tree)


ctrl-shift F1
- look for the open... button

and you got the unit
(alternatively install package IDE explorer)

Find the button in the form, search in code, where the caption is set.


Sorry,

for entries in the list, just search in files for the text

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Strange dependency of units

2012-04-04 Thread Alberto Narduzzi


Separation is very advantages for large and/or professional projects.


separation, as you call it, is simply a good-design practice; no matter 
whether the project is small or big.
I quite don't believe (allow me this simple paragon) you would mix your 
winter and summer clothing in the same bag; and bring the very same bag 
with you to the beach and to the mountains...




But it contradicts the idea of RAD (Rapid Application Development)
that initially drove the invention of Delphi.


That's simply not true. a RAD tool can help you in many ways, but your 
code (your CODE) still needs to be hand-written. And your CODE generally 
is more likely to be NON-GUY (or not so strictly GUY) related.
Just to bring in a name every developer at least one time in his life 
has come across: the unit utils.pas had better be GUY-independent; as 
I doubt you would need a lot of graphic bells-and-whistles just to be 
able to use the function trimRight(s: string): String; Or do you...?




Same is very useful for projects dedicated to starting,
learning/teaching, prototyping, testing Pascal code, testing attached
devices, staying small, etc. IMHO this is true by far the most projects
ever started.


this may indeed be the one and only place where you could at least not 
bother with differences between GUY and NON-GUY environments.
True is that nowadays NON-GUY envs. tend to disappear; but you need to 
remember that FP is meant to be portable to (any) environment, including 
embedded systems; where this difference is still alive and kicking.




Very unfortunately many 3rd party products available for free or payed
don't adhere to the separating GUI and business code paradigm.


Hence I wonder why some people don't complain after having paid for them...



Unfortunately many projects start small and at some point get so big
that separating GUI and business code would be appropriate, but with an
advanced project, the effort is a lot harder to do.


the problem must be approached the other way around... Anyway, 
separating GUY code from NON-GUY is not such a big task; you only need 
to know your tools. Or say, classes... what they do and what not.
The software is your tool, your instrument, and you better know it very 
well... indeed, I'd dare say that it's your due.




This is especially true if it it turns out that the final product needs
to be used as a service/daemon.


Sic. I'd; and probably not only me... ;-) probably kill you (but just 
cutting your hands would probably do as well), shall you implement a 
daemon with some dependencies on text/graphic specific library...




Here the upcoming Custom Drawn Widget set some day might help to allow
for some kind of GUI remoting, and by simply switching the Lazarus
Widget Type the GUI can be cut off.


Sorry, this one I cannot catch... :-O


Cheers, A.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Keys attached to IDE functions

2012-04-04 Thread Sven Barth
Am 04.04.2012 18:02 schrieb Jürgen Hestermann juergen.hesterm...@gmx.de:
 And yet another one: When I want to assign a new key and this key is
already assigned to another function I get a message telling me whether I
still want to assign to this key. If I answer no, the whole assignment
dialog is closed. Often I want to try another key but first I have to find
my entry (it's not even highlighted anymore!) and double click on it again.
This repeats for each unsuccessful try of keys. I am not sure whether this
can be changed easily but if yes I (and hopefully others too) would
appreciate if someone does.

I had already reported this some time ago and it got fixed in the
development version shortly thereafter. Once 1.0 is released you'll find it
fixed.

Regards,
Sven
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Sun, Apr 1, 2012 at 3:44 PM, zel...@holobit.net wrote:

 Hi all,
 As I've already mentioned few weeks ago on lazdevel, today we branched 1.0
 :)

 branch is here:
 http://svn.freepascal.org/svn/lazarus/branches/fixes_1_0/

 wiki with revisions which have to be merged from trunk (also there will be
 links about other 1.0 stuff like changes etc):
 http://wiki.lazarus.freepascal.org/Lazarus_1.0_fixes_branch
 or
 http://wiki.freepascal.org/Lazarus_1.0_fixes_branch

 Current trunk version 0.9.31 is 1.1 as of r36507.

 1.In next days snapshots will be versioned as 1.1
 2.For testers:
 svn co http://svn.freepascal.org/svn/lazarus/branches/fixes_1_0 lazarus
 3.We are planning to release 1.0 in next 3 months, but before that we will
 relese 1..XX RC candidates - you'll be informed about it.

 Happy Lazarus 1.0 !

I updated my Lazarus today, from SVN trunk, and everything works.
But the splash form shows the old version 0.9.31. However if I click
in HelpAbout the info is correct (version 1.1).

Lazarus 1.1 r36566 FPC 2.6.1 i386-win32-win32/win64

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Vincent Snijders
Op 4 april 2012 22:50 heeft Marcos Douglas m...@delfire.net het
volgende geschreven:
 On Sun, Apr 1, 2012 at 3:44 PM, zel...@holobit.net wrote:

 Hi all,
 As I've already mentioned few weeks ago on lazdevel, today we branched 1.0
 :)

 branch is here:
 http://svn.freepascal.org/svn/lazarus/branches/fixes_1_0/

 wiki with revisions which have to be merged from trunk (also there will be
 links about other 1.0 stuff like changes etc):
 http://wiki.lazarus.freepascal.org/Lazarus_1.0_fixes_branch
 or
 http://wiki.freepascal.org/Lazarus_1.0_fixes_branch

 Current trunk version 0.9.31 is 1.1 as of r36507.

 1.In next days snapshots will be versioned as 1.1
 2.For testers:
 svn co http://svn.freepascal.org/svn/lazarus/branches/fixes_1_0 lazarus
 3.We are planning to release 1.0 in next 3 months, but before that we will
 relese 1..XX RC candidates - you'll be informed about it.

 Happy Lazarus 1.0 !

 I updated my Lazarus today, from SVN trunk, and everything works.
 But the splash form shows the old version 0.9.31. However if I click
 in HelpAbout the info is correct (version 1.1).

 Lazarus 1.1 r36566 FPC 2.6.1 i386-win32-win32/win64

Did you recompile startlazarus?

Vincent

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread waldo kitty

On 4/4/2012 16:50, Marcos Douglas wrote:

I updated my Lazarus today, from SVN trunk, and everything works.
But the splash form shows the old version 0.9.31. However if I click
in HelpAbout the info is correct (version 1.1).

Lazarus 1.1 r36566 FPC 2.6.1 i386-win32-win32/win64


i'm on 36559 and my splash shows 1.1 at the bottom... i start my lazarus via 
startlazarus...


i'm pretty sure you've also seen my exchanges concerning compiling from the 
command line instead of svn update and then firing lazarus and compiling a new 
laz from in there? if so, we've learned (in the last months) that we should 
make clean before svn up... then make all (the easy way) to build all the 
new tools and such... then we can lazbuild blah blah to build the new 
lazarus... at least my lazbuild.exe and startlazarus.exe are built every time...




--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Wed, Apr 4, 2012 at 5:55 PM, Vincent Snijders
vincent.snijd...@gmail.com wrote:
 Op 4 april 2012 22:50 heeft Marcos Douglas m...@delfire.net het
 volgende geschreven:
 On Sun, Apr 1, 2012 at 3:44 PM, zel...@holobit.net wrote:

 Hi all,
 As I've already mentioned few weeks ago on lazdevel, today we branched 1.0
 :)

 branch is here:
 http://svn.freepascal.org/svn/lazarus/branches/fixes_1_0/

 wiki with revisions which have to be merged from trunk (also there will be
 links about other 1.0 stuff like changes etc):
 http://wiki.lazarus.freepascal.org/Lazarus_1.0_fixes_branch
 or
 http://wiki.freepascal.org/Lazarus_1.0_fixes_branch

 Current trunk version 0.9.31 is 1.1 as of r36507.

 1.In next days snapshots will be versioned as 1.1
 2.For testers:
 svn co http://svn.freepascal.org/svn/lazarus/branches/fixes_1_0 lazarus
 3.We are planning to release 1.0 in next 3 months, but before that we will
 relese 1..XX RC candidates - you'll be informed about it.

 Happy Lazarus 1.0 !

 I updated my Lazarus today, from SVN trunk, and everything works.
 But the splash form shows the old version 0.9.31. However if I click
 in HelpAbout the info is correct (version 1.1).

 Lazarus 1.1 r36566 FPC 2.6.1 i386-win32-win32/win64

 Did you recompile startlazarus?

 Vincent

To recompile Lazarus I just use the IDE.. I thought the command Build
All recompile everything. If not, how I recompile the startlazarus?

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Wed, Apr 4, 2012 at 7:35 PM, waldo kitty wkitt...@windstream.net wrote:
 On 4/4/2012 16:50, Marcos Douglas wrote:

 I updated my Lazarus today, from SVN trunk, and everything works.
 But the splash form shows the old version 0.9.31. However if I click
 in HelpAbout the info is correct (version 1.1).

 Lazarus 1.1 r36566 FPC 2.6.1 i386-win32-win32/win64


 i'm on 36559 and my splash shows 1.1 at the bottom... i start my lazarus via
 startlazarus...

 i'm pretty sure you've also seen my exchanges concerning compiling from the
 command line instead of svn update and then firing lazarus and compiling a
 new laz from in there? if so, we've learned (in the last months) that we
 should make clean before svn up... then make all (the easy way) to
 build all the new tools and such... then we can lazbuild blah blah to
 build the new lazarus... at least my lazbuild.exe and startlazarus.exe are
 built every time...

I use scripts to compile the FPC but to Lazarus I only use the IDE.
I can't use make all because all configuration, components, etc will gone.

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 4 Apr 2012 21:34:50 -0300
Marcos Douglas m...@delfire.net wrote:

[...]
 To recompile Lazarus I just use the IDE.. I thought the command Build
 All recompile everything. If not, how I recompile the startlazarus?

Compile project ide/startlazarus.lpi.

Or use make clean all.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Wed, Apr 4, 2012 at 9:47 PM, Mattias Gaertner
nc-gaert...@netcologne.de wrote:
 On Wed, 4 Apr 2012 21:34:50 -0300
 Marcos Douglas m...@delfire.net wrote:

[...]
 To recompile Lazarus I just use the IDE.. I thought the command Build
 All recompile everything. If not, how I recompile the startlazarus?

 Compile project ide/startlazarus.lpi.

Maybe the Build command, on IDE, would do this?

 Or use make clean all.


As I said, I can't use make all because all configuration,
components, etc will gone.

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 4 Apr 2012 21:38:03 -0300
Marcos Douglas m...@delfire.net wrote:

[...]
 I can't use make all because all configuration, components, etc will gone.

No. Make does not delete/alter configurations.
In fact it does not even know where your configuration is.
That's why it can only build a default IDE or a default big IDE.

When you start such a default IDE, it will read your configuration. If
you use it to build a new IDE it will install your packages. Then you
get a new IDE with your configuration and your components.

Or you can use lazbuild to build an IDE with your components in a
console.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Wed, Apr 4, 2012 at 9:53 PM, Mattias Gaertner
nc-gaert...@netcologne.de wrote:
 On Wed, 4 Apr 2012 21:38:03 -0300
 Marcos Douglas m...@delfire.net wrote:

[...]
 I can't use make all because all configuration, components, etc will gone.

 No. Make does not delete/alter configurations.
 In fact it does not even know where your configuration is.
 That's why it can only build a default IDE or a default big IDE.

 When you start such a default IDE, it will read your configuration. If
 you use it to build a new IDE it will install your packages. Then you
 get a new IDE with your configuration and your components.

 Or you can use lazbuild to build an IDE with your components in a
 console.

Sorry, I think I did not understand. You're saying I should use Make
to build a default IDE at the first time. After that I should use the
Build command (on IDE) or lazbuild tool to recompile with my own
configurations and components?

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Mattias Gaertner
On Wed, 4 Apr 2012 21:59:08 -0300
Marcos Douglas m...@delfire.net wrote:

 On Wed, Apr 4, 2012 at 9:53 PM, Mattias Gaertner
 nc-gaert...@netcologne.de wrote:
  On Wed, 4 Apr 2012 21:38:03 -0300
  Marcos Douglas m...@delfire.net wrote:
 
 [...]
  I can't use make all because all configuration, components, etc will 
  gone.
 
  No. Make does not delete/alter configurations.
  In fact it does not even know where your configuration is.
  That's why it can only build a default IDE or a default big IDE.
 
  When you start such a default IDE, it will read your configuration. If
  you use it to build a new IDE it will install your packages. Then you
  get a new IDE with your configuration and your components.
 
  Or you can use lazbuild to build an IDE with your components in a
  console.
 
 Sorry, I think I did not understand. You're saying I should use Make
 to build a default IDE at the first time. After that I should use the
 Build command (on IDE) or lazbuild tool to recompile with my own
 configurations and components?

make clean all is the clean way.

In 99,9% of all svn revisions it is enough to rebuild the IDE via the
IDE.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread waldo kitty

On 4/4/2012 20:34, Marcos Douglas wrote:

On Wed, Apr 4, 2012 at 5:55 PM, Vincent Snijders wrote:

Did you recompile startlazarus?


To recompile Lazarus I just use the IDE.. I thought the command Build
All recompile everything. If not, how I recompile the startlazarus?


as mattias and i have been discussing, the easiest way is make clean before 
svn up... then make all after that... then you can use lazbuild to build 
based on profiles (eg: debug ide, normal ide, optimized ide which are all 
defaults) and those would also include your own defined profiles just the same 
as in the IDE... provided that i've been following along and understanding... as 
such, i just reported a bug today wherein lazbuild still builds debug versions 
when it is not supposed to do so... i'm hoping this is fixed and working 
properly when laz v1.0 is released in another few months...


my setup is based off of (your??) wiki instructions for total SVN starting of 
FPC and lazarus... i've been working on an updatelaz script (.bat file on 
winwhatever) which is now working for the basic needs... just to get the above 
mentioned bug fixed and life will be golden again :P ;)



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Wed, Apr 4, 2012 at 10:09 PM, Mattias Gaertner
nc-gaert...@netcologne.de wrote:
 On Wed, 4 Apr 2012 21:59:08 -0300
 Marcos Douglas m...@delfire.net wrote:

 On Wed, Apr 4, 2012 at 9:53 PM, Mattias Gaertner
 nc-gaert...@netcologne.de wrote:
  On Wed, 4 Apr 2012 21:38:03 -0300
  Marcos Douglas m...@delfire.net wrote:
 
 [...]
  I can't use make all because all configuration, components, etc will 
  gone.
 
  No. Make does not delete/alter configurations.
  In fact it does not even know where your configuration is.
  That's why it can only build a default IDE or a default big IDE.
 
  When you start such a default IDE, it will read your configuration. If
  you use it to build a new IDE it will install your packages. Then you
  get a new IDE with your configuration and your components.
 
  Or you can use lazbuild to build an IDE with your components in a
  console.

 Sorry, I think I did not understand. You're saying I should use Make
 to build a default IDE at the first time. After that I should use the
 Build command (on IDE) or lazbuild tool to recompile with my own
 configurations and components?

 make clean all is the clean way.

It's recommended if I have an error, right?
We use make clean all, get a default IDE and recompile again using
pcp param to restart all configurations, components, etc. But I have
to compile twice. Am I right?

 In 99,9% of all svn revisions it is enough to rebuild the IDE via the
 IDE.

OK.
I compiled project ide/startlazarus.lpi and I got an error because the
startlazarus.exe is running... of course. So, I started Lazarus
without use startlazarus and I compiled again. Now I can see the
splash updated.

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread Marcos Douglas
On Wed, Apr 4, 2012 at 10:17 PM, waldo kitty wkitt...@windstream.net wrote:
 On 4/4/2012 20:34, Marcos Douglas wrote:

 On Wed, Apr 4, 2012 at 5:55 PM, Vincent Snijders wrote:

 Did you recompile startlazarus?


 To recompile Lazarus I just use the IDE.. I thought the command Build
 All recompile everything. If not, how I recompile the startlazarus?


 as mattias and i have been discussing, the easiest way is make clean
 before svn up... then make all after that... then you can use lazbuild
 to build based on profiles (eg: debug ide, normal ide, optimized ide
 which are all defaults) and those would also include your own defined
 profiles just the same as in the IDE... provided that i've been following
 along and understanding... as such, i just reported a bug today wherein
 lazbuild still builds debug versions when it is not supposed to do so... i'm
 hoping this is fixed and working properly when laz v1.0 is released in
 another few months...

For FPC I always use make distclean before update from SVN and then
make [...] using my script.
I never used lazbuild. The IDE can do this, why complicate? ;-)

 my setup is based off of (your??) wiki instructions for total SVN starting
 of FPC and lazarus... i've been working on an updatelaz script (.bat file on
 winwhatever) which is now working for the basic needs... just to get the
 above mentioned bug fixed and life will be golden again :P ;)

Yes, I wrote the Installation instructions to use FPC and Lazarus from
SVN to Win32. After someone improved the scripts.

I have a new script that I improved to compile FPC (32 and 64 using
cross) with some optionals parameters etc. But to Lazarus the IDE
works very fine.
Today I saw this little problem in the splash form... well, I can
compile startlazarus some times, that is very simple too.

Marcos Douglas

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread waldo kitty

On 4/4/2012 20:38, Marcos Douglas wrote:

On Wed, Apr 4, 2012 at 7:35 PM, waldo kittywkitt...@windstream.net  wrote:

i'm pretty sure you've also seen my exchanges concerning compiling from the
command line instead of svn update and then firing lazarus and compiling a
new laz from in there? if so, we've learned (in the last months) that we
should make clean before svn up... then make all (the easy way) to
build all the new tools and such... then we can lazbuild blah blah to
build the new lazarus... at least my lazbuild.exe and startlazarus.exe are
built every time...


I use scripts to compile the FPC but to Lazarus I only use the IDE.
I can't use make all because all configuration, components, etc will gone.


ummm... after that, as i wrote in my previous, you run lazbuild to build what 
you really want... make all is the cheap way out... it builds everything 
including a basic default default (yes) lazarus so that one can at least get up 
and running... lazbuild is supposed to then be able to build the same 
lazarus.exe as you do from in the IDE's Tools-build lazarus selection with 
the chosen profile... this is what mattias and i have been working on this last 
week in the lazbuild build IDE profiles thread ;)



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread waldo kitty

On 4/4/2012 20:53, Mattias Gaertner wrote:

Or you can use lazbuild to build an IDE with your components in a
console.


+100~

that's what we're working on :)

when i can keep off the side trips and stick to the main task :P

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus 1.0 is branched

2012-04-04 Thread waldo kitty

On 4/4/2012 21:18, Marcos Douglas wrote:

On Wed, Apr 4, 2012 at 10:09 PM, Mattias Gaertner wrote:

make clean all is the clean way.


It's recommended if I have an error, right?


ummm... n... please see the lazbuild build IDE profiles thread...


We use make clean all, get a default IDE and recompile again using
pcp param to restart all configurations, components, etc. But I have
to compile twice. Am I right?


yes, there is that but if make all is not used, the one must know and call all 
of the necessary make targets without the IDE one to get all the tools built...



In 99,9% of all svn revisions it is enough to rebuild the IDE via the
IDE.


that's what my discussions in the lazbuild build IDE profiles thread are all 
about... why have to manually go into the IDE to build a new IDE after a svn 
update?? i start my updatelaz script which cleans the dirs, updates from svn, 
and then does the building of the tools and lazarus... now that things are 
working better, i can go have a cuppa' joe while everything does all its 
churning and burning... on this particular workstation, that's about 30 minutes 
or so... maybe more... maybe less...



OK.
I compiled project ide/startlazarus.lpi and I got an error because the
startlazarus.exe is running... of course. So, I started Lazarus
without use startlazarus and I compiled again. Now I can see the
splash updated.


hummm... interesting...


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus