View Issue Details

IDProjectCategoryView StatusLast Update
0018569LazarusOtherpublic2011-08-06 23:10
Reporterbr_Klaus Assigned ToMaxim Ganetsky  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version0.9.29 (SVN) 
Fixed in Version0.9.31 (SVN) 
Summary0018569: many uncorrect filepaths in the automatically written files on installin Lazarus-FPC-Snapshots (FPC 2.4.2)
DescriptionWhen installing automatically Lazarus-Snapshots, there are always the same files that have "wrong" indications in it (wrong File path or wrong version).
Perhaps this could be corrected in newer editions.
(used snapshot: Lazarus-0.9.31-29088-fpc-2.4.2-20110118-win32.exe )




I found these files (mainly in the \examples-folder):


\doceditor\fpcdocupdater:
    mainunit.lfm --> D:\Projects\lazarus\...
    mainunit.pas --> E:\lazarus.. and E:\lazarus\fpc\2.2.1\..

\examples\codepageconverter\
    mainunit.lfm ---> i:\FPC\Lazarus\examples...

\examples\database\dblookup
    project1.lpi --> \fpc\2.2.3 and \fpc\2.2.5

\examples\dbeditmask\
    unit1.lfm --> D:\repositories\examples...
                C:\LazarusProjects\DBLookupTest\data\


some indications of paths seem to come from the program authors:

\components\lazreport\samples\barcode\cbunit.lfm
 object Dbf1: TDbf
    FilePath = 'C:\Documents and Settings\javiVF\Escritorio\lazarus\Proyectos\cb\db\/\'
    IndexDefs = <>
    TableName = 'disco.dbf'
    TableLevel = 3
  end
  

\components\jcf2\IdePlugin\lazarus\jcfidelazarus.lpk
     <IncludeFiles Value="..\..\Include\;C:\programming\lazarus\components\jcf2\Ui\Settings\"/>

\components\jcf2\CommandLine\jcf.dof
    RunParams=-config=C:\Code\CodeFormat\Jcf2\Test\TestCases

\JCFTestSettings.cfg -out -F C:\Code\CodeFormat\Jcf2\Test\TestCas\EmptyTest1.pas

similarly in \ == \D11\jcf.bdsproj und ==\D12\jcf.bdsproj


\components\jcf2\Contributions\StyleEditor\JCFStyle.cfg
    -LE"C:\Documents and Settings\Anthony\My Documents\Borland Studio Projects\Bpl"
    -LN"C:\Documents and Settings\Anthony\My Documents\Borland Studio Projects\Bpl"

\components\jcf2\JcfGui\D11\fcfGui.bdsproj and ...\D12\....
    <Language Name="RootDir">C:\Code\JcfCheckout\CodeFormat\Jcf2\CommandLine\</Language>


    similarly in ...\D11\JcFNotePad.bdsproj and ...\D12\...


\debugger\test\Gdbmi\TestGdbmi.lpi
       <Filename Value="C:\FPC\SVN\trunc\.... (many times)


\doceditor\fpcdocupdater\mainunit.lfm
    FileName = 'c:\fpcbeta\bin\i386-win32\makeskel'

\docs\html\build_html.bat
    PATH=C:\Programas\lazarus22\fpc\2.2.0\bin\i386-win32

  wouldn't it be possible to fix these paths automatically when installing


\examples\affinetransforms\project1.lpi
    C:\fpc\2.2.4\source\rtl\objpas\types.pp"/>
    C:\lazarusSVN\... (many times)


\examples\dockmanager\toolbar\test1.lpi
   <DestinationDirectory Value="D:\SourceForge\lazarus\examples\dockmanager\toolbar"/>


\examples\postscript\usamplepostscriptcanvas.pas
    C:\Program Files\Ghostgum\gsview\gsview32


\examples\SynEdit\Completion\SynCompletionSample.lpi
    C:\FPC\SVN\trunc\... (many times)


...\bin\i386-win32\cygwin1.dll
    C:\CYGWIN_SYSLOG.TXT


,,\source\packages\ptc\docs\INSTALL
      set FPCDIR=c:\fpc\2.0.0

    this seems to be o very old file. Is it still up to date?


..\source\rtl\palmos\m68k\prto.pas
    c:\FPC\FIXES\RTL\PALMOS\CRT..... (many times)

\mingw\bin\libexpat-1.dll
    C:\MinGW\src\gccbf\mingw32\libgc...


\test\testlpi.pas
    ScriptEngine := 'C:\Program Files\AutoHotkey\AutoHotKey.exe';
bhook'


If the Unins000.dat already exists (with earlier version), it is not overwritten! (so you can no more uninstall, because of wrong paths)


When starting Lazarus, the program uses still the options (file paths with older version) of the prior version.
I have to correct this manually.


TagsNo tags attached.
Fixed in Revision31896, 31897, 31898, 31899, 31900, 31901, 31902, 31903, 31904
LazTarget0.99.0
WidgetsetWin32/Win64
Attached Files

Relationships

parent of 0018470 closedMaxim Ganetsky Example dbeditmask contains absolute Paths. 

Activities

Vincent Snijders

2011-01-20 18:31

manager   ~0045336

A think a lot of them are "won't fix" or "not fixable", don't you think?

lainz

2011-01-21 03:29

reporter   ~0045356

Knowing that lazarus changes every day and examples too making an installer fixing paths isn't the best way.

If you export the project as "Publish project..." you can set a relative path for "<DestinationDirectory Value=$(ProjPath)\published\>"

"When starting Lazarus, the program uses still the options (file paths with older version) of the prior version.
I have to correct this manually."

First uninstall Lazarus (Settings are never uninstalled: you can remove those from your AppData user folder) and then install newest lazarus (like you do with other "big" software), all the path settings will be restored.

AppData (Win Vista / 7):
C:\Users\USERNAME\AppData\Local\lazarus

2011-08-04 22:47

 

0018569.patch (9,117 bytes)   
Index: components/lazreport/samples/barcode/cbunit.lfm
===================================================================
--- components/lazreport/samples/barcode/cbunit.lfm	(revision 31862)
+++ components/lazreport/samples/barcode/cbunit.lfm	(working copy)
@@ -45,7 +45,7 @@
     TabOrder = 2
   end
   object Dbf1: TDbf
-    FilePath = 'C:\Documents and Settings\javiVF\Escritorio\lazarus\Proyectos\cb\db\/\'
+    FilePath = ''
     IndexDefs = <>
     TableName = 'disco.dbf'
     TableLevel = 3
Index: doceditor/fpdocupdater/mainunit.lfm
===================================================================
--- doceditor/fpdocupdater/mainunit.lfm	(revision 31862)
+++ doceditor/fpdocupdater/mainunit.lfm	(working copy)
@@ -1,7 +1,7 @@
 object FormMain: TFormMain
   Left = 253
   Height = 528
-  Top = 156
+  Top = 138
   Width = 598
   HorzScrollBar.Page = 597
   VertScrollBar.Page = 527
@@ -14,6 +14,7 @@
   OnCreate = FormCreate
   OnDestroy = FormDestroy
   OnShow = FormShow
+  LCLVersion = '0.9.31'
   object LabelDocs: TLabel
     Left = 12
     Height = 14
@@ -66,27 +67,27 @@
   end
   object EditDocs: TDirectoryEdit
     Left = 180
-    Height = 23
+    Height = 21
     Top = 12
     Width = 359
-    Directory = 'D:\Projects\Lazarus\Docs\xml\lcl\'
+    ShowHidden = False
     ButtonWidth = 45
     NumGlyphs = 1
     Anchors = [akTop, akLeft, akRight]
-    ParentColor = False
+    MaxLength = 0
     TabOrder = 0
     OnChange = EditDocsChange
   end
   object EditUnits: TDirectoryEdit
     Left = 180
-    Height = 23
+    Height = 21
     Top = 48
     Width = 359
-    Directory = 'D:\Projects\Lazarus\LCL\'
+    ShowHidden = False
     ButtonWidth = 45
     NumGlyphs = 1
     Anchors = [akTop, akLeft, akRight]
-    ParentColor = False
+    MaxLength = 0
     TabOrder = 1
     OnChange = EditUnitsChange
   end
@@ -122,6 +123,7 @@
     Caption = 'Update New'
     Font.Color = clRed
     OnClick = ButtonUpdateNewClick
+    ParentFont = False
     TabOrder = 4
   end
   object ButtonRefresh: TButton
@@ -141,16 +143,17 @@
     Top = 156
     Width = 409
     Anchors = [akTop, akLeft, akRight, akBottom]
+    ItemHeight = 0
     MultiSelect = True
     OnDrawItem = ListBoxDrawItem
     Style = lbOwnerDrawFixed
     TabOrder = 6
   end
   object CheckBoxBackup: TCheckBox
-    Left = 426
-    Height = 19
+    Left = 437
+    Height = 17
     Top = 222
-    Width = 120
+    Width = 109
     Anchors = [akTop, akRight]
     Caption = 'Backup FPDoc files'
     Checked = True
@@ -159,7 +162,7 @@
   end
   object EditBackup: TEdit
     Left = 444
-    Height = 23
+    Height = 21
     Top = 276
     Width = 80
     Anchors = [akTop, akRight]
@@ -168,7 +171,7 @@
   end
   object EditPackage: TEdit
     Left = 444
-    Height = 23
+    Height = 21
     Top = 186
     Width = 80
     Anchors = [akTop, akRight]
@@ -177,39 +180,42 @@
   end
   object EditMakeSkel: TFileNameEdit
     Left = 180
-    Height = 23
+    Height = 21
     Top = 120
     Width = 359
-    FileName = 'D:\Projects\fpcbeta\bin\i386-win32\makeskel'
+    DialogOptions = []
+    FilterIndex = 0
+    HideDirectories = False
     ButtonWidth = 45
     NumGlyphs = 1
     Anchors = [akTop, akLeft, akRight]
-    ParentColor = False
+    MaxLength = 0
     TabOrder = 10
   end
   object EditInclude: TDirectoryEdit
     Left = 180
-    Height = 23
+    Height = 21
     Top = 84
     Width = 360
-    Directory = 'D:\Projects\Lazarus\LCL\Include'
+    ShowHidden = False
     ButtonWidth = 45
     NumGlyphs = 1
     Anchors = [akTop, akLeft, akRight]
-    ParentColor = False
+    MaxLength = 0
     TabOrder = 11
   end
   object StatusBar: TStatusBar
+    Left = 0
     Height = 20
     Top = 508
     Width = 598
     Panels = <>
   end
   object CheckBoxShowSummary: TCheckBox
-    Left = 426
-    Height = 19
+    Left = 431
+    Height = 17
     Top = 312
-    Width = 97
+    Width = 92
     Anchors = [akTop, akRight]
     Caption = 'Show summary'
     Checked = True
Index: doceditor/fpdocupdater/mainunit.pas
===================================================================
--- doceditor/fpdocupdater/mainunit.pas	(revision 31862)
+++ doceditor/fpdocupdater/mainunit.pas	(working copy)
@@ -208,10 +208,10 @@
 begin
   XMLConfig := TXMLConfig.Create('FPDocUpdater.xml');
 
-  EditDocs.Directory := XMLConfig.GetValue('FPDocsPath/Value', 'E:\lazarus\docs\xml\lcl\');
-  EditUnits.Directory := XMLConfig.GetValue('UnitsPath/Value', 'E:\lazarus\lcl\');
-  EditInclude.Directory := XMLConfig.GetValue('IncludePath/Value', 'E:\lazarus\lcl\include\');
-  EditMakeSkel.FileName := XMLConfig.GetValue('MakeSkelPath/Value', 'E:\lazarus\fpc\2.2.1\bin\i386-win32\makeskel.exe');
+  EditDocs.Directory := XMLConfig.GetValue('FPDocsPath/Value', 'Please set path to <Docs\xml\lcl\>');
+  EditUnits.Directory := XMLConfig.GetValue('UnitsPath/Value', 'Please set path to <LCL\>');
+  EditInclude.Directory := XMLConfig.GetValue('IncludePath/Value', 'Please set path to <LCL\Include\>');
+  EditMakeSkel.FileName := XMLConfig.GetValue('MakeSkelPath/Value', 'Please set path to <FPC\bin\i386-win32\makeskel.exe>');
   CheckBoxBackup.Checked := XMLConfig.GetValue('BackupFPDocs/Value', True);
   EditBackup.Text := XMLConfig.GetValue('BackupExt/Value', 'bak');
   EditPackage.Text := XMLConfig.GetValue('Package/Value', 'lcl');
Index: examples/codepageconverter/mainunit.lfm
===================================================================
--- examples/codepageconverter/mainunit.lfm	(revision 31862)
+++ examples/codepageconverter/mainunit.lfm	(working copy)
@@ -12,7 +12,7 @@
   Constraints.MinWidth = 578
   OnShow = Form1Show
   Position = poScreenCenter
-  LCLVersion = '0.9.29'
+  LCLVersion = '0.9.31'
   object Panel1: TPanel
     Left = 0
     Height = 200
@@ -124,7 +124,6 @@
     Top = 200
     Width = 578
     Align = alClient
-    Directory = 'i:\FPC\Lazarus\examples\codepageconverter'
     ItemHeight = 13
     PopupMenu = PopupMenu1
     TabOrder = 1
Index: examples/database/dblookup/data/months.dbf
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Index: examples/database/dblookup/unit1.lfm
===================================================================
--- examples/database/dblookup/unit1.lfm	(revision 31862)
+++ examples/database/dblookup/unit1.lfm	(working copy)
@@ -120,7 +120,7 @@
     top = 176
   end
   object Dbf1: TDbf
-    FilePath = 'C:\LazarusProjects\DBLookupTest\data\'
+    FilePath = '.\data\'
     IndexDefs = <    
       item
         IndexFile = 'months.mbf'
@@ -177,7 +177,7 @@
     end
   end
   object Dbf2: TDbf
-    FilePath = 'C:\LazarusProjects\DBLookupTest\data\'
+    FilePath = '.\data\'
     IndexDefs = <    
       item
         IndexFile = 'lookerup.mbf'
Index: examples/dbeditmask/Unit1.lfm
===================================================================
--- examples/dbeditmask/Unit1.lfm	(revision 31862)
+++ examples/dbeditmask/Unit1.lfm	(working copy)
@@ -12,7 +12,7 @@
   Font.Name = 'MS Sans Serif'
   OnCreate = FormCreate
   Position = poScreenCenter
-  LCLVersion = '0.9.29'
+  LCLVersion = '0.9.31'
   object Label3: TLabel
     Left = 8
     Height = 14
@@ -26,16 +26,23 @@
     Height = 273
     Top = 112
     Width = 497
+    Color = clWindow
     Columns = <    
       item
+        Title.Caption = 'ADATE'
+        Title.PrefixOption = poNone
         Width = 180
         FieldName = 'ADATE'
       end    
       item
+        Title.Caption = 'ASTR'
+        Title.PrefixOption = poNone
         Width = 100
         FieldName = 'ASTR'
       end    
       item
+        Title.Caption = 'AINT'
+        Title.PrefixOption = poNone
         Width = 100
         FieldName = 'AINT'
       end>
@@ -50,6 +57,12 @@
     Top = 392
     Width = 497
     BevelOuter = bvNone
+    ChildSizing.EnlargeHorizontal = crsScaleChilds
+    ChildSizing.EnlargeVertical = crsScaleChilds
+    ChildSizing.ShrinkHorizontal = crsScaleChilds
+    ChildSizing.ShrinkVertical = crsScaleChilds
+    ChildSizing.Layout = cclLeftToRightThenTopToBottom
+    ChildSizing.ControlsPerLine = 100
     ClientHeight = 42
     ClientWidth = 497
     DataSource = DataSource1
@@ -64,14 +77,14 @@
     DataSource = DataSource1
     CharCase = ecNormal
     EditMask = '!99/99/00;1;_'
-    MaxLength = 0
+    MaxLength = 8
     TabOrder = 2
   end
   object ShowLongDateCheckBox: TCheckBox
     Left = 270
     Height = 17
     Top = 34
-    Width = 90
+    Width = 92
     Caption = 'Show Full Date'
     OnChange = ShowLongDateCheckBoxChange
     TabOrder = 3
@@ -85,7 +98,7 @@
     DataSource = DataSource1
     CharCase = ecNormal
     EditMask = '!99;1;_'
-    MaxLength = 0
+    MaxLength = 2
     TabOrder = 4
   end
   object Label1: TLabel
@@ -102,11 +115,9 @@
     top = 288
   end
   object Dbf1: TDbf
-    FilePath = 'D:\repositories\lazarus\examples\dbeditmask\'
     IndexDefs = <>
     TableName = 'test.db'
     TableLevel = 4
-    Active = True
     FilterOptions = []
     left = 312
     top = 288
0018569.patch (9,117 bytes)   

samuel herzog

2011-08-04 22:50

developer   ~0050450

I today search all .pas and .lfm files in the lazarus folder for ":\" and fixed most of them. (see attached patch)

This two I could not fix.

SynHighlighterBat.pas -->function TSynBatSyn.GetSampleSource: string;
JcfRegistrySettings.pas -->procedure TJCFRegistrySettings.ReadAll;

Maxim Ganetsky

2011-08-06 23:10

developer   ~0050571

Last edited: 2011-08-07 00:15

I removed absolute paths from all places where it made sense.

Thanks for the patch.

Please test and close if ok.

Issue History

Date Modified Username Field Change
2011-01-20 17:33 br_Klaus New Issue
2011-01-20 17:33 br_Klaus Widgetset => Win32/Win64
2011-01-20 18:31 Vincent Snijders Note Added: 0045336
2011-01-20 18:56 Vincent Snijders Relationship added parent of 0018470
2011-01-21 03:29 lainz Note Added: 0045356
2011-02-08 14:32 Vincent Snijders LazTarget => 1.0
2011-02-08 14:32 Vincent Snijders Status new => acknowledged
2011-02-08 14:32 Vincent Snijders Target Version => 1.0.0
2011-08-04 22:47 samuel herzog File Added: 0018569.patch
2011-08-04 22:50 samuel herzog Note Added: 0050450
2011-08-05 02:28 Maxim Ganetsky LazTarget 1.0 => 0.99.0
2011-08-05 02:28 Maxim Ganetsky Target Version 1.0.0 => 0.99.0
2011-08-06 16:07 Maxim Ganetsky Status acknowledged => assigned
2011-08-06 16:07 Maxim Ganetsky Assigned To => Maxim Ganetsky
2011-08-06 23:10 Maxim Ganetsky Fixed in Revision => 31896, 31897, 31898, 31899, 31900, 31901, 31902, 31903, 31904
2011-08-06 23:10 Maxim Ganetsky Status assigned => resolved
2011-08-06 23:10 Maxim Ganetsky Fixed in Version => 0.9.31 (SVN)
2011-08-06 23:10 Maxim Ganetsky Resolution open => fixed
2011-08-06 23:10 Maxim Ganetsky Note Added: 0050571
2011-08-07 00:15 Maxim Ganetsky Note Edited: 0050571