[Lazarus] Using a component OBJ file in Lazarus?

Mattias Gaertner nc-gaertnma at netcologne.de
Sun Jun 10 12:58:42 CEST 2018


On Sun, 10 Jun 2018 12:37:32 +0200
Bo Berglund via Lazarus <lazarus at lists.lazarus-ide.org> wrote:

> When converting components to Lazarus (see separate thread) I have
> encountered a problem for a component that interfaces to a software
> protection dongle.
> My component files (pas) need to reference a unit + an obj file from
> the dongle maker. In the maker's pas file is this:
> 
> IMPLEMENTATION
> USES
>    Windows;
> {$L SPROMEPS.OBJ}  { LINK WITH THE SUPERPRO OBJECT FILE }
> 
> The Spromeps.obj file is located in the same directory as the source
> files and in package manager I have added the main component source
> file and checked that it compiles without errors. OK.

Your package must inherit an object search path.

Package editor / Options / Package Options / Add path to dependent
packages / Object

Add '$(PkgDir)' without quotes.


> When the component source file was added PM asked if the path to the
> file should be added to the search path, so I expected it to be
> known...

Pascal sources and object files have different search paths.

 
Mattias


More information about the Lazarus mailing list