[fpc-devel] using gorc on win64 as resource compiler

2007-07-02 Thread vsnijders
Hi,

Thanks for fixing the coff loading on win64.

Attached patch enables the use of gorc on win64 in the compiler: adding {$R 
lazarus.rc} includes this resource into the Lazarus executable, giving it a 
main icon and a XP look.

Vincent
Index: systems.pas
===
--- systems.pas	(revision 7919)
+++ systems.pas	(working copy)
@@ -188,6 +188,7 @@
 ,res_m68k_palmos,res_m68k_mpw
 ,res_powerpc_mpw,res_elf
 ,res_gnu_wince_windres
+,res_win64_gorc
);
 
tdbg = (dbg_none
Index: systems/i_win.pas
===
--- systems/i_win.pas	(revision 7919)
+++ systems/i_win.pas	(working copy)
@@ -105,7 +105,7 @@
 asmext   : '.s';
 objext   : '.o';
 resext   : '.res';
-resobjext: '.or';
+resobjext: '.obj';
 sharedlibext : '.dll';
 staticlibext : '.a';
 staticlibprefix : 'libp';
@@ -122,7 +122,7 @@
 link : nil;
 linkextern   : nil;
 ar   : ar_gnu_ar;
-res  : res_gnu_windres;
+res  : res_win64_gorc;
 dbg  : dbg_stabs;
 script   : script_dos;
 endian   : endian_little;
Index: systems/t_win.pas
===
--- systems/t_win.pas	(revision 7919)
+++ systems/t_win.pas	(working copy)
@@ -124,7 +124,16 @@
   rccmd  : '--include $INC -O res -o $RES $RC';
 );
 
+res_win64_gorc_info : tresinfo =
+(
+  id : res_win64_gorc;
+  resbin : 'gorc';
+  rescmd : '/machine x64 /nw /ni /o /fo $OBJ $RES';
+  rcbin  : 'gorc';
+  rccmd  : '/machine x64 /nw /ni /r /fo $RES $RC';
+);
 
+
   Procedure GlobalInitSysInitUnitName(Linker : TLinker);
 var
   hp   : tmodule;
@@ -1767,7 +1776,7 @@
   RegisterImport(system_x86_64_win64,TImportLibWin);
   RegisterExport(system_x86_64_win64,TExportLibWin);
   RegisterDLLScanner(system_x86_64_win64,TDLLScannerWin);
-  RegisterRes(res_gnu_windres_info,TWinResourceFile);
+  RegisterRes(res_win64_gorc_info,TWinResourceFile);
   RegisterTarget(system_x64_win64_info);
 {$endif x86_64}
 {$ifdef arm}
___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] using gorc on win64 as resource compiler

2007-07-02 Thread vsnijders


- Original Message -
From: Yury Sidorov [EMAIL PROTECTED]
Date: Monday, July 2, 2007 1:00 pm
Subject: Re: [fpc-devel] using gorc on win64 as resource compiler

 From: [EMAIL PROTECTED]
  Hi,
 
  Thanks for fixing the coff loading on win64.
 
  Attached patch enables the use of gorc on win64 in the compiler: 
  adding {$R lazarus.rc} includes this resource into the Lazarus 
  executable, giving it a main icon and a XP look.
 
 Applied. Thanks.

Can the GoRC executable be added to the fpcbuild repository?

Vincent


___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] using gorc on win64 as resource compiler

2007-07-02 Thread Yury Sidorov

From: [EMAIL PROTECTED]

- Original Message -
From: Yury Sidorov [EMAIL PROTECTED]
Date: Monday, July 2, 2007 1:00 pm
Subject: Re: [fpc-devel] using gorc on win64 as resource compiler


From: [EMAIL PROTECTED]
 Hi,

 Thanks for fixing the coff loading on win64.

 Attached patch enables the use of gorc on win64 in the compiler:
 adding {$R lazarus.rc} includes this resource into the Lazarus
 executable, giving it a main icon and a XP look.

Applied. Thanks.


Can the GoRC executable be added to the fpcbuild repository?


It is ok to me, but what other core developers think?

Yury. 
___

fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] using gorc on win64 as resource compiler

2007-07-02 Thread Florian Klaempfl
Yury Sidorov schrieb:
 From: [EMAIL PROTECTED]
 - Original Message -
 From: Yury Sidorov [EMAIL PROTECTED]
 Date: Monday, July 2, 2007 1:00 pm
 Subject: Re: [fpc-devel] using gorc on win64 as resource compiler

 From: [EMAIL PROTECTED]
  Hi,
 
  Thanks for fixing the coff loading on win64.
 
  Attached patch enables the use of gorc on win64 in the compiler:
  adding {$R lazarus.rc} includes this resource into the Lazarus
  executable, giving it a main icon and a XP look.

 Applied. Thanks.

 Can the GoRC executable be added to the fpcbuild repository?
 
 It is ok to me, but what other core developers think?

Fine with me.
___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] Plans to merge r7789?

2007-07-02 Thread Daniël Mantione


Op Mon, 2 Jul 2007, schreef Joao Morais:

 Jonas Maebe wrote:
  
  On 30 Jun 2007, at 17:38, Joao Morais wrote:
  
   Plans to merge r7789,
   http://www.freepascal.org/mantis/view.php?id=9139
   to the 2.2 fixes?
  
  If someone else can verify it's ok (the patch, not just the tested
  effects).
 
 Thanks for clarifying this.
 
 I am not in a hurry, but please consider fix the 2.2 branch before the 2.2
 release; this would be a show stopper for the beta versions of PressObjects
 SDK.

The patch is rather difficult to understand, while for a merge we need not 
only understand the patch itself, but also be able to understand there are 
no side effects.

Daniël___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


[fpc-devel] MinDateTime is 100 AD ?

2007-07-02 Thread Joost van der Sluis
Hi all,

In sysstrh.inc MinDateTime is defined as follows:

  { For floattodatetime }
  MinDateTime: TDateTime = -657434.0; { 01/01/0100 12:00:00.000 AM }
  MaxDateTime: TDateTime =  2958465.9;{ 12/31/ 11:59:59.999 PM }

Why is that? Datetimes before 100AD works perfectly. Can I change it to
01/01/01 ? (Why does this restriction exist at all?!?)

Regards,
  Joost.

___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] MinDateTime is 100 AD ?

2007-07-02 Thread Joost van der Sluis
On Mon, 2007-07-02 at 22:07 +0200, Michael Van Canneyt wrote:
 
 On Mon, 2 Jul 2007, Joost van der Sluis wrote:
 
  On Mon, 2007-07-02 at 21:48 +0200, Michael Van Canneyt wrote:
   
   On Mon, 2 Jul 2007, Joost van der Sluis wrote:
   
Hi all,

In sysstrh.inc MinDateTime is defined as follows:

  { For floattodatetime }
  MinDateTime: TDateTime = -657434.0; { 01/01/0100 12:00:00.000 AM }
  MaxDateTime: TDateTime =  2958465.9;{ 12/31/ 11:59:59.999 PM }

Why is that? Datetimes before 100AD works perfectly. Can I change it to
01/01/01 ? (Why does this restriction exist at all?!?)
   
   Delphi compatibility, probably. As far as I know, it's not used ?
  
  It is used in cvarutil.VariantToDate and in sysstr.FloatTodateTime. 
 
 Probably to avoid a conversion error ?
 Maybe some Microsoft thing, that's where TDateTime comes from ?
 
 The reason is probably lost in the mists of time :-)

I'll change it to 01/01/01. When it raises problems on windows, the db-
testsuite will detect that. 

Joost.

___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] MinDateTime is 100 AD ?

2007-07-02 Thread Vincent Snijders
On Mon, 02 Jul 2007 22:21:22 +0200
Joost van der Sluis [EMAIL PROTECTED] wrote:

 On Mon, 2007-07-02 at 22:07 +0200, Michael Van Canneyt wrote:
  
  On Mon, 2 Jul 2007, Joost van der Sluis wrote:
  
   On Mon, 2007-07-02 at 21:48 +0200, Michael Van Canneyt wrote:

On Mon, 2 Jul 2007, Joost van der Sluis wrote:

 Hi all,
 
 In sysstrh.inc MinDateTime is defined as follows:
 
   { For floattodatetime }
   MinDateTime: TDateTime = -657434.0; { 01/01/0100 12:00:00.000 
 AM }
   MaxDateTime: TDateTime =  2958465.9;{ 12/31/ 11:59:59.999 
 PM }
 
 Why is that? Datetimes before 100AD works perfectly. Can I change it 
 to
 01/01/01 ? (Why does this restriction exist at all?!?)

Delphi compatibility, probably. As far as I know, it's not used ?
   
   It is used in cvarutil.VariantToDate and in sysstr.FloatTodateTime. 
  
  Probably to avoid a conversion error ?
  Maybe some Microsoft thing, that's where TDateTime comes from ?
  
  The reason is probably lost in the mists of time :-)
 
 I'll change it to 01/01/01. When it raises problems on windows, the db-
 testsuite will detect that. 

Just an idea, what happens if you assign '01/01/01' (the string) to a variant 
and then assign the variant to a tdatetime?

Is it a date from the year 1901 or not?

Vincent
___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] MinDateTime is 100 AD ?

2007-07-02 Thread Micha Nelissen
Joost van der Sluis wrote:
 I'll change it to 01/01/01. When it raises problems on windows, the db-
 testsuite will detect that. 

Isn't 01/01/01 just as arbitrary ?

Micha
___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] MinDateTime is 100 AD ?

2007-07-02 Thread Joost van der Sluis
On Mon, 2007-07-02 at 22:32 +0200, Vincent Snijders wrote:
 On Mon, 02 Jul 2007 22:21:22 +0200
 Joost van der Sluis [EMAIL PROTECTED] wrote:
 
  On Mon, 2007-07-02 at 22:07 +0200, Michael Van Canneyt wrote:
   
   On Mon, 2 Jul 2007, Joost van der Sluis wrote:
   
On Mon, 2007-07-02 at 21:48 +0200, Michael Van Canneyt wrote:
 
 On Mon, 2 Jul 2007, Joost van der Sluis wrote:
 
  Hi all,
  
  In sysstrh.inc MinDateTime is defined as follows:
  
{ For floattodatetime }
MinDateTime: TDateTime = -657434.0; { 01/01/0100 12:00:00.000 
  AM }
MaxDateTime: TDateTime =  2958465.9;{ 12/31/ 11:59:59.999 
  PM }
  
  Why is that? Datetimes before 100AD works perfectly. Can I change 
  it to
  01/01/01 ? (Why does this restriction exist at all?!?)
 
 Delphi compatibility, probably. As far as I know, it's not used ?

It is used in cvarutil.VariantToDate and in sysstr.FloatTodateTime. 
   
   Probably to avoid a conversion error ?
   Maybe some Microsoft thing, that's where TDateTime comes from ?
   
   The reason is probably lost in the mists of time :-)
  
  I'll change it to 01/01/01. When it raises problems on windows, the db-
  testsuite will detect that. 
 
 Just an idea, what happens if you assign '01/01/01' (the string) to a variant 
 and then assign the variant to a tdatetime?
 
 Is it a date from the year 1901 or not?

It'll return 1901. If you supply '01/01/0001' it will return the year
0001 in fpc 2.1.4, and 1901 in fpc 2.0.4.

Joost.
ps: I meant 01/01/0001 for MinDateTime, offcourse.


___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel


Re: [fpc-devel] MinDateTime is 100 AD ?

2007-07-02 Thread Daniël Mantione


Op Mon, 2 Jul 2007, schreef Joost van der Sluis:

 Hi all,
 
 In sysstrh.inc MinDateTime is defined as follows:
 
   { For floattodatetime }
   MinDateTime: TDateTime = -657434.0; { 01/01/0100 12:00:00.000 AM }
   MaxDateTime: TDateTime =  2958465.9;{ 12/31/ 11:59:59.999 PM }
 
 Why is that? Datetimes before 100AD works perfectly. Can I change it to
 01/01/01 ? (Why does this restriction exist at all?!?)

Most probably year 2000 releated. To easy conversions from two digit days 
to four digit years, rules were introduced that years 100 need to be 
interpreted as a two digit years. I am 99% sure that these values have 
been designed with some of these rules in mind. I recommend against 
changing.

Daniël___
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel