Upgrading to
Indy 10
Delphi 7 ships with
Indy 9. Since the only documentation on the
Indy website is now based on release 10, and some examples won't work with older releases, you must remove
Indy 9 from the
IDE, and install release 10.
There are two possibilities, but both require your uninstalling
Indy 9 yourself before installing
Indy 10:
upgrade manually following thoses instructions: How do I install
Indy into Borland Delphi?, Upgrading to
Indy 10, [D7] Upgrade propre des composants
Indy vers
Indy 10.1.5?, [D7 Ent] How to upgrade
Indy properly?,
Indy 10 in Delphi 2006
run the upgrader
Indy Plus Install, free for personal or educational users, while commercial projects require buying the
Indy Plus
package
Removing Indy9:
Close the Borland Delphi
IDE if it is open.
If you are using the version of
Indy included in Delphi 6 or 7, use the
MSI installer to remove
Indy: In "Program Files", click on the drop-down list before
Indy, and select Do Not Install. If you didn't install Corba, uncheck "Use Visibrocker/CORBA Support" before proceeding with the uninstall
Remove all
Indy files from the Delphi directory, including dclIndy*.bpl,
Indy*.bpl, the Id*.pas, and the Id*.dcu's. Take care that you only remove the old
Indy files and not something else. Be sure that you also remove any
Indy*.bpl from your Windows\System32 directory (IndyCore70.bpl, IndyProtocols70.bpl, and IndySystem70.bpl)
When restarting Delphi, it will fail loading the
Indy 9
BPL: "Error/Can't load
package c:\program files\borland\delphi\Bin\dclindy70.bpl. The specified module could not be found. Do you want to attempt to load the
package the next time a project is loaded?" Just tell it not to try reloading this
package the next time.
Manually installing Indy10
Place the new version of
Indy in a directory of your choice. When unzipping, please keep the \source directory for the archive intact because that is used by some build batch files.
In the source directory, there are several batch files. Run the appropriate one for your version of
Indy:
FULLD4.BAT - Delphi 4
FULLD5.BAT - Delphi 5
FULLD6.BAT - Delphi 6
FULLD7.BAT - Delphi 7
These batch files create subdirectories in the main
Indy directory folder. They are (D4 for Delphi 4, D5 for Delphi 5, D6 for Delphi 6, and D7 for Delphi 7). These directories contain:
The
Indy .DCU's
The
Indy Design-Time .BPL
In your Delphi
IDE, add the
Indy design-time package with Component|Install
Package...|Add... Go to the subdirectory where the
Indy .DCU's and
Design-Time .BPL was placed by the batch file. Add the
Design-Time .BPL that is listed. It usually is named dclIndy followed by the Borland Delphi version and an 0
Add the path where the .DCU's are located to your environment. Do this with Tools|Environment Options...|Library...|Library Path...
(Difference with above instructions?) Compiling and installing manually:
Note: All packages are followed by X0 (Where X is your Delphi verison). Example: For Delphi 6, the IndySystem
package would be named: IndySystem60.dpk
Download the latest source code
Open and compile .dpk files in the following order:
Lib\System\IndySystemX0.dpk
Lib\Core\IndyCoreX0.dpk
Lib\Protocols\IndyProtocolsX0.dpk
Lib\SuperCore\IndySuperCoreX0.dpk
If you are not using SuperCore, then you do not need to compile this
package.
Now open these .dpk files and click install in the following order:
Lib\Core\dclIndyCoreX0.dpk
Lib\Protocols\dcl\IndyProtocolsX0.dpk
Lib\SuperCore\dcl\SuperCoreX0.dpk
Only install this if you have compiled SuperCore.
After installing
Indy 10, you might get the following error when adding a IdUDPServer widget and code for the UDPRead event: "[Error] Unit1.pas(15): Undeclared identifier: 'TBytes'"
=> "That is a known Delphi bug, not an
Indy one. The bug is that Delphi parses the signature wrong when generating the event handler. As for why TIdBytes is used in the event, it is because the Intercept system in
Indy 10 is based on TIdBytes to begin with. It
Indy 9, it was based on Streams instead."