<html><head></head><body style="zoom: 0%;"><div dir="auto">Have restarted the lazarus just recompiled?<br><br></div>
<div dir="auto"><!-- tmjah_g_1299s -->Ottieni <!-- tmjah_g_1299e --><a href="http://www.bluemail.me/r?b=15997"><!-- tmjah_g_1299s -->BlueMail per Android<!-- tmjah_g_1299e --></a><!-- tmjah_g_1299s --> <!-- tmjah_g_1299e --></div>
<div class="gmail_quote" >Il giorno 27 Ago 2020, alle ore 22:51, Bo Berglund via lazarus <<a href="mailto:lazarus@lists.lazarus-ide.org" target="_blank">lazarus@lists.lazarus-ide.org</a>> ha scritto:<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<pre class="blue">I am (again) trying to port a Delphi application to Lazarus/FPC.<br>This time I need a customized version of TListView, which I converted<br>to use in Lazarus back in 2018.<br>See thread titled:<br>"Converting a component package Delphi->Lazarus using built-in<br>converter?"<br><br>I found the files for the converted component on my disk as:<br>easylistview.lpk THis is the package file <br>EasyListView.pas<br>EasyListView.dcr<br><br>No using Lazarus 2.0.8 and FPC 3.0.4 I did the following:<br>- Started Lazarus<br>- Told it to start a new project (to not interfere with my current<br>project)<br>- Package/Open package file<br>- Navigated to the easylistview.lpk file<br>- Clicked the Compile button. Finished successfully.<br>- Use/Install. Lazarus started to rebuild itself<br>- No visible errors shown<br>- Lazarus restarted<br><br>Now, how do I find the component I just installed so I can use it?<br>I expected a new tab named AGI to appear with the component inside of<br>it but I cannot find it...<br><br>This is what is (or rather was, see below) in the register procedure<br>in EasyListView.pas:<br><br>procedure Register;<br>begin<br> RegisterComponents('AGI', [TEasyListView]);<br>end;<br><br>And this is the lpk file content after the compile/install:<br><br><?xml version="1.0" encoding="UTF-8"?><br><CONFIG><br> <Package Version="4"><br> <PathDelim Value="\"/><br> <Name Value="EasyListView"/><br> <Type Value="RunAndDesignTime"/><br> <CompilerOptions><br> <Version Value="11"/><br> <PathDelim Value="\"/><br> <SearchPaths><br> <UnitOutputDirectory Value="lib\$(TargetCPU)-$(TargetOS)"/><br> </SearchPaths><br> </CompilerOptions><br> <Files Count="1"><br> <Item1><br> <Filename Value="EasyListView.pas"/><br> <UnitName Value="EasyListView"/><br> </Item1><br> </Files><br> <RequiredPkgs Count="1"><br> <Item1><br> <PackageName Value="IDEIntf"/><br> </Item1><br> </RequiredPkgs><br> <UsageOptions><br> <UnitPath Value="$(PkgOutDir)"/><br> </UsageOptions><br> <PublishOptions><br> <Version Value="2"/><br> </PublishOptions><br> <CustomOptions Items="ExternHelp" Version="2"><br> <_ExternHelp Items="Count"/><br> </CustomOptions><br> </Package><br></CONFIG><br><br>Now the strangest thing is that in this process Lazarus has completely<br>mangled the EasyListView.pas source file so it now only has this<br>content wheras the original was 27 kbytes....:<br><br><br>{ This file was automatically created by Lazarus. Do not edit!<br> This source is only used to compile and install the package.<br> }<br><br>unit EasyListView;<br><br>{$warn 5023 off : no warning about unused units}<br>interface<br><br>uses<br> LazarusPackageIntf;<br><br>implementation<br><br>procedure Register;<br>begin<br>end;<br><br>initialization<br> RegisterPackage('EasyListView', @Register);<br>end.<br><br><br>So it is overwriting the source file for the component with a<br>basically empty file, which it successfully installs and is nowhere to<br>be found....<br><br>Apparently I am doing something completely wrong here, but what?<br><br></pre></blockquote></div></body></html>