Recent

Author Topic: Indy 10 installation instructions on Wiki needs clarification/reorganisation  (Read 44929 times)

JD

  • Hero Member
  • *****
  • Posts: 1848

Hmmm, I do remember that IdStreamVCL.pas was a difficult problem. The compiler was saying something about not being able to find it. I had to add the directory to the package's Unit path before it worked.

Afaik removing duplicate include files helps too.

It worked! Finally! Thanks for reminding me of the duplicate files, marcov. I used my tried and tested system i.e copy all necessary files (*.pas, *.lrs, *.inc) from the \Lib\Core, \Lib\Protocols, \Lib\System directories into a directory of my choice taking care not to duplicate already existing files. I then copied the modified IdRegisterCore.lrs and IdRegister.lrs (but not the modified IndyLaz.lpk) created by ChrisF into the directory I created. I then compiled the package twice, rebuilt the Lazarus IDE & I now have the Indy icons in 256 colors.  :D Where there's a will, there's always a way.

Thanks marcov and ChrisF.

JD
« Last Edit: May 06, 2013, 04:06:30 pm by JD »
Windows - Lazarus 2.1/FPC 3.2 (built using fpcupdeluxe),
Linux Mint - Lazarus 2.1/FPC 3.2 (built using fpcupdeluxe)

mORMot; Zeos 8; SQLite, PostgreSQL & MariaDB; VirtualTreeView

MISV

  • Hero Member
  • *****
  • Posts: 783
Could anyone of you maybe eigh in on the issue I have encountered with Indy and OSX here:
http://forum.lazarus.freepascal.org/index.php/topic,28476.0.html

My setup works on Windows/Lazarus (1.4) but on OSX I have problems.

I have compiled and installed the indylaz with "-Ur"

When compiling a package that requires indylaz + has a unit from it in "uses" clause I get error
Quote
Can not find "idFTP used by "UmisvMyPackage", incompatible ppu = /Users/%myname%/MISV/LazarusComponents/indy_lazarus/Lib/lib/i386-darwin/idFTP.ppu, package indylaz -- You tried to use a unit of which the PPU file isn't found by the compiler. Check your configuration file for the unit paths

If I try compile a new fresh app where I e.g. drop TidFTP and ass idFTP unit to uses clause I get
Quote
Can not find "idFTP used by "UmisvMyApplication", Make sure all ppu files of a package are in its output directory = /Users/%myname%/MISV/LazarusComponents/indy_lazarus/Lib/lib/i386-darwin/idFTP.ppu, package indylaz -- You tried to use a unit of which the PPU file isn't found by the compiler. Check your configuration file for the unit paths

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11383
  • FPC developer.
MISV:

I notice something I didn't notice before; "Incompatible PPU" means different version or architecture.

So somehow either the fpc compiler that is being executed is not what you think AND/OR the ppu's don't match it.

Earlier I thought it was some minor gotcha that forced recompile but then the message is "Interface CRC not matching, recompiling' or something similar.

MISV

  • Hero Member
  • *****
  • Posts: 783
Hi Marcow,

I appreciate all the help you try give me.

I have tried to delete all .ppu files in the indylaz Lib/lib/i386-darwin/ folder before compiling something that requires/uses the package - i.e. a dependent package (the error message about incompatible) or application (where the error is slightly different)

If I e.g. compile a free new application in Lazarus/OSX, it runs in OSX. But if I add idFTP component to it, it fails. (So I think that means FPC/Lazarus/Sources compiler are correct?)

However, maybe there are source files from elsewhere? It is correct I moved my Indy Lazarus/Windows installing to OSX when I started the work on porting, but since I have tried removing all the PPU files then I am not sure what there if left to try? Could there be some option in a apckage file that survived the move from LAzarus/Windows to Lazarus/OSX?

ChrisF

  • Hero Member
  • *****
  • Posts: 542
It may sound obvious (i.e. you've probably already verify it), but:

- have you looked at the messages output when compiling Indy before installing it? Especially the concerned unit i.e. IdFtp ? Is it compiled correctly ? Without any error or warning ?

- have you looked at the IdFtp.ppu file in the concerned Indy subdirectory ? Is it present and with the same date/time that the other ppu files ?

- do you have any other idFtp.ppu  file somewhere else ? In your package ? Or in any path of your package ? Anywhere else ?

Have you installed any other package than Indy (and your package) ?


It's not clear to me if you've done this test: testing IdFtp, but without your own package. I mean, a fresh FPC/lazarus installation + the Indy package only ?


What version of Indy are you using ? A recent one, from http://indy.fulgan.com ?


Is any other component of Indy working properly ? An idHttp component, for instance, within a simple test project ?


And finally: do you remember what kind of files you have transferred EXACTLY from Windows to OSX for your package ?

I guess one of them could be a problem (not necessarily a .ppu file). Theoretically, the whole ...Lib/lib/i386-win32 (or x86_64-win64) subdirectory should have be omitted during the copy. 

It's also possible that there are some differences from "standard" Windows package files and "standard" OSX ones - i.e. options added/removed or different by default (sorry, I can't tell for this part).


Edit:
I'm not sure bout what you mean with "I have tried to delete all .ppu files in the indylaz Lib/lib/i386-darwin/ folder before compiling something that requires/uses the package".

What is it just to check something (I mean the compilation can't succeed any longer, anyway) ?

To see if there is a different error message ?

Why not having just delete the IdFtp.ppu file to check the error message, in this case ?


Edit2:
Would it be possible that you have any other idftp.ppu file with a different case orthography (i.e. case sensitive problem - I don't know how your system is configured) ?  Or that your package use a different case orthography for this unit ?

See: http://wiki.freepascal.org/User_Changes_2.4.0#Case_sensitivity_for_unit_names
Quote
...
New behaviour: All file systems are now treated as case-sensitive by default. The result is that the compiler will no longer always find units whose filename does not exactly match the unit name as it appears in the uses clause, even if the unit is located on a case-insensitive file system.
...
« Last Edit: May 24, 2015, 03:10:17 pm by ChrisF »

MISV

  • Hero Member
  • *****
  • Posts: 783
His Chris,

I can answer all of your questions / to-list items. I have tried them all :(


- I just use "idFTP as an example - it is whatever indy unit that is first placed in uses section. (So nothing from Indy compiles when used from anywhere.)

- I do not have any win32 folder in my OSX indy installation (only darwin)

- I have tried searching system for duplicate ppu file.

- I tried delete all ppu files to make sure they were all built / generated "fresh" again

- I am using an Indy version a couple of months old. (I only installed two other packages - lclextensions and virtualtreeview, none of which interact with Indy AFAIK)

- I have manually inspected the lpk file to see if anything appears wrong, but it does not appear so. (If anyone has a working Indy installation on OSX - do please upload it so I can compare?)

- I have tried checking case sensitivty. The .pas, .ppu file, compilter output error/log all use the same case.

ChrisF

  • Hero Member
  • *****
  • Posts: 542
So, if I'm correctly understanding you, you can compile correctly and install the Indy package (BTW, do you see its icons in your IDE ?), but you can't use it in any way.

In this case, could you check your indylaz.lpk file on OSX. Be sure to have this option:
Code: [Select]
<Type Value="RunAndDesignTime"/>
and especially not this one (at least one release of Indy has been done with an incorrect package file):
Code: [Select]
<Type Value="DesignTime"/>

MISV

  • Hero Member
  • *****
  • Posts: 783
Correct. Yes, I see icons, but I can't compile anything that uses it.

Everything looks correct to me, but I have attached the indylaz.lpk file here.


ChrisF

  • Hero Member
  • *****
  • Posts: 542
I can't see anything obvious in your package file, though there is one or two things a bit "strange".

Have you called it "indylaz.txt" instead of "indylaz.lpk" for a good reason (may be to upload it) ? Are you sure that it is this file which is used during your package installation, and not an "old" .lpk file still present ?

Apparently, the version is not the latest one, though it's still a recent one, indeed. What I find a bit strange is that I've never seen a recent Indy file build this way: may be because you've changed some options in your IDE for this package and re-saved it ?

What I find strange, for instance, is that you have only 13 files count in your package file: in the past it was 15, and since a while it's 14 AFAIK: IdDsnCoreResourceStrings.pas is missing. Why ? And I've got 14 both for my Indy 10.6.0 (build 5141) and 10.6.2 (build 5273), while yours is 10.6.1 (build 5238): just between the two of them.

So, where did you get your whole Indy package, exactly ?


Just to be sure, have you checked inside your IDE that your package has really been installed as "RunAndDesign" in its option: see attached capture for my own version.


Sorry, I can't see any other "good" reason explaining your problem. As a last chance, you can eventually make a try with the current version of Indy, i.e:
- uninstall your current Indy package, then remove all the Indy files currently present (sources, binary, config...) into your Indy package subdirectory,
- download the latest version from http://indy.fulgan.com/ (in ZIP directory - currently "Indy10_5274.zip");
- install it without any modification (you still need to compile it twice before rebuilding your IDE for it's final installation step).


BTW, have you also made a try with a simple test project by adding the absolute path of your Indy binaries into the search path of this project (-Fu compiler option):
Project - > Project Options - > Compiler options - > Paths - > Other unit files

« Last Edit: May 25, 2015, 05:21:09 am by ChrisF »

MISV

  • Hero Member
  • *****
  • Posts: 783
I renamed it .txt, so it could be uploaded.

If anyone has a working lpk file on OSX - please upload it.

Yes, design and runtime :)

I originally changed file paths in my lpk because I wanted the paths to match. So I did not have those red cross over the filenames like in your screenshot. I believe this was necessary for the fulgan package to install, but I can not remember the specifics any longer.

I will try a reinstall, but my hopes are pretty low.

I have tried pointing "other files" to the ppu directory of Indy - does not work either :(
« Last Edit: May 25, 2015, 01:04:23 pm by MISV »

MISV

  • Hero Member
  • *****
  • Posts: 783
Same problem with a fresh untouched Indy installation. (I even deleted the old Indy directory and installed the new one in a complete new directory to make sure there were no leftover references)

Anyone here got Indy working on OSX / Lazarus 1.4?

ChrisF

  • Hero Member
  • *****
  • Posts: 542
I'm afraid there is an issue relative to the OSX environment: sorry...

Eventually, you can try to make a test directly with the Free Pascal compiler (i.e. not using Lazarus); with only a sample program and calling directly fpc.

A sample program: test.pas
Code: [Select]
program test;

uses
  IdFTP;

var MyFTP: TIdFTP;

begin
  MyFTP := TIdFTP.Create(nil);
  MyFTP.UserName := 'anonymous';
  MyFTP.Free;
  WriteLn('Done');
end.

Compilation call for Windows, to adapt according to the proper configuration : comp.bat
Code: [Select]
dir C:\lazarus\components\indy\Lib\lib\i386-win32\IdFTP.*
C:\lazarus\fpc\2.6.4\bin\i386-win32\fpc -FuC:\lazarus\components\indy\Lib\lib\i386-win32\ test.pas

I'm not familiar with Mac OSX, but I guess it should be (more or less) equivalent to the following commands: to run into the OSX terminal
Code: [Select]
ls -l /path_for_Indy_binaries/IdFTP.*
/path_for_fpc_binaries/fpc -Fu/path_for_Indy_binaries/ test.pas

The aim of the dir/ls commands is to verify that the proper path and the proper filenames are correct for the Indy binary files (and eventually the corresponding permissions, too). It could be interesting to know if you really can "see" them, while fpc can't.


*** Edit ***
I just noticed that the Ftp unit for my Windows version of Indy are called IdFTP.* (as for in the zip file of Indy), while you are always referring to idFTP.* everywhere (especially in your error messages). Of course Windows doesn't care, but it could be the case for OSX: strange...

If it's really the case, you'll have to modify the test program and commands: IdFTP -> idFTP.
« Last Edit: May 25, 2015, 07:21:54 pm by ChrisF »

balazsszekely

  • Guest
@MISV
My configuration:
   - OSX 10.8.5(Mountain Lion)
   - Indy 10.6.2.5274(the latest from http://indy.fulgan.com - downloaded on 25.05.2015)
   - Lazarus 1.5 SVN version(r49172 - 26.05.2015)
*I can run a few tests on OSX 10.10(Yosemite) if is necessary, but I prefer not to, because I have a few project under development(Lazarus 1.2.6)

I have no problem compiling/installing Indy, then building/running applications.
1. Remove all previous indy installation
2. Download the following package(10.6.2.5274) from: http://www.2shared.com/file/eCHHk96r/Indy_1062.html
3. Extract the zip to $(LazarusDir)/Components/ directory
4. Open the package file, compile twice
5. Install Indy
6. Create a new project, add a few indy components(IdFTP for example) then go to Project/Options, add indy directory to Search Paths(http://i1269.photobucket.com/albums/jj581/balazsszekely/Indy%2010_1_zpsq0ydkwxb.png)
7. Build then Run (http://i1269.photobucket.com/albums/jj581/balazsszekely/Indy%2010_2_zpszknc3fwb.png)

JD

  • Hero Member
  • *****
  • Posts: 1848
6. Create a new project, add a few indy components(IdFTP for example) then go to Project/Options, add indy directory to Search Paths(http://i1269.photobucket.com/albums/jj581/balazsszekely/Indy%2010_1_zpsq0ydkwxb.png)
7. Build then Run (http://i1269.photobucket.com/albums/jj581/balazsszekely/Indy%2010_2_zpszknc3fwb.png)

Did you make the Indy About form yourself. It looks great!

Seeing your screenshots gives me assurance that Indy10 works in a Mac environment. I use it in Windows & Linux but the Mac was the final frontier for me. I can now say my Indy 10 apps work on all PC platforms.

JD
« Last Edit: May 26, 2015, 09:54:01 am by JD »
Windows - Lazarus 2.1/FPC 3.2 (built using fpcupdeluxe),
Linux Mint - Lazarus 2.1/FPC 3.2 (built using fpcupdeluxe)

mORMot; Zeos 8; SQLite, PostgreSQL & MariaDB; VirtualTreeView

balazsszekely

  • Guest
Quote
@JD
Did you make the Indy About form yourself. It looks great!
No! It's the original Indy About form since 2014. Install the latest indy, drop a component to your form, right click-->About Internet Direct(Indy).
« Last Edit: May 26, 2015, 10:13:17 am by GetMem »

 

TinyPortal © 2005-2018