Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: Linker throwing error LIB266 - any idea what does it means?



Permlink Replies: 4 - Last Post: Apr 6, 2018 7:47 AM Last Post By: Rodrigo Gomez C...
Rodrigo Gomez C...

Posts: 32
Registered: 3/16/00
Linker throwing error LIB266 - any idea what does it means?
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 4, 2018 3:50 PM
Hello,

Trying to use the latest RemObjects SDK (version 9.4, but this also happened with version 9.3) produces a linker error, LIB266:

ilink32 command line
c:\program files (x86)\embarcadero\studio\19.0\bin\ilink32.exe -G8 -L.\Win32\Debug;"c:\program files (x86)\embarcadero\studio\19.0\lib\Win32\debug";
"Test-ro";"c:\program files (x86)\embarcadero\studio\19.0\lib\win32\release";"c:\program files (x86)\embarcadero\studio\19.0\lib\win32\release\psdk";
"C:\Program Files (x86)\RemObjects Software\RemObjects SDK for Delphi\Dcu\D25\Win32";"C:\Program Files (x86)\RemObjects Software\Data Abstract for 
Delphi\Dcu\D25\win32";"C:\Program Files (x86)\RemObjects Software\Data Abstract for Delphi\Source";
C:\Users\Public\Documents\Embarcadero\Studio\19.0\DCP -j.\Win32\Debug;"c:\program files (x86)\embarcadero\studio\19.0\lib\Win32\debug";"Test-ro";
"c:\program files (x86)\embarcadero\studio\19.0\lib\win32\release";"c:\program files (x86)\embarcadero\studio\19.0\lib\win32\release\psdk";
"C:\Program Files (x86)\RemObjects Software\RemObjects SDK for Delphi\Dcu\D25\Win32";"C:\Program Files (x86)\RemObjects Software\Data Abstract for 
Delphi\Dcu\D25\win32";"C:\Program Files (x86)\RemObjects Software\Data Abstract for Delphi\Source";
C:\Users\Public\Documents\Embarcadero\Studio\19.0\DCP -lC:\Users\Public\Documents\Embarcadero\Studio\19.0\DCP -v -Gi -aa -V5.0 -GBPackage1 -Tpp 
c0pkg32w rtl.bpi dbrtl.bpi designide.bpi IndyCore.bpi IndyProtocols.bpi IndySystem.bpi RemObjects_Core_D25.bpi RemObjects_Indy_D25.bpi vcl.bpi 
vclactnband.bpi vclimg.bpi vclx.bpi xmlrtl.bpi memmgr.lib sysinit.obj .\Win32\Debug\Package1.obj .\Win32\Debug\Unit1.obj , 
C:\Users\Public\Documents\Embarcadero\Studio\19.0\BPL\Package1.bpl , C:\Users\Public\Documents\Embarcadero\Studio\19.0\BPL\Package1.map , 
import32.lib cp32mti.lib , , Package1.res 
[ilink32 Warning] Warning: CODE : 0x00000267 / 0x01000000
[ilink32 Warning] Warning: DATA : 0x00000125 / 0x01000000
[ilink32 Warning] Warning: DEBSYM : 0x0000000e / 0x01000000
[ilink32 Warning] Warning: Extdef flags : 0x00000026 / 0x00008000
[ilink32 Warning] Warning: Extdefs : 0x00000098 / 0x00008000
[ilink32 Warning] Warning: Import symbols : 0x00000000 / 0x00100000
[ilink32 Warning] Warning: OBJ symbols : 0x00000d34 / 0x00400000
[ilink32 Warning] Warning: Public GSX : 0x00003250 / 0x000c0000
[ilink32 Warning] Warning: Publics : 0x0001c4d0 / 0x000c0000
[ilink32 Warning] Warning: SegRelocs : 0x00000708 / 0x00800000
[ilink32 Warning] Warning: StringBlock : 0x0000002b / 0x01000000
[ilink32 Warning] Warning: Virdefs : 0x00000008 / 0x00020000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilc: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ild: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilf: 0x00020000 / 0x0a000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ils: 0x00660000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.tds: 0x00010000 / 0x09400000
[ilink32 Warning] Warning: Extdef flags : 0x00000000 / 0x00008000
[ilink32 Warning] Warning: Extdefs : 0x00000000 / 0x00008000
[ilink32 Warning] Warning: Import symbols : 0x00000000 / 0x00100000
[ilink32 Warning] Warning: OBJ symbols : 0x00000000 / 0x00400000
[ilink32 Warning] Warning: Public GSX : 0x00000360 / 0x000c0000
[ilink32 Warning] Warning: Publics : 0x00001e60 / 0x000c0000
[ilink32 Warning] Warning: StringBlock : 0x00000012 / 0x01000000
[ilink32 Warning] Warning: Virdefs : 0x00000000 / 0x00020000
[ilink32 Warning] Warning: unknown heap name : 0x08000000 / 0x08000000
[ilink32 Warning] Warning: Error detected (LIB266)
[ilink32 Warning] Warning: Unable to perform incremental link - performing full link...
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilc: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ild: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilf: 0x00020000 / 0x0a000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ils: 0x00660000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.tds: 0x00010000 / 0x09400000
[ilink32 Warning] Warning: CODE : 0x00000267 / 0x01000000
[ilink32 Warning] Warning: DATA : 0x00000125 / 0x01000000
[ilink32 Warning] Warning: DEBSYM : 0x0000000e / 0x01000000
[ilink32 Warning] Warning: Extdef flags : 0x00000026 / 0x00008000
[ilink32 Warning] Warning: Extdefs : 0x00000098 / 0x00008000
[ilink32 Warning] Warning: Import symbols : 0x00000000 / 0x00100000
[ilink32 Warning] Warning: OBJ symbols : 0x00000d34 / 0x00400000
[ilink32 Warning] Warning: Public GSX : 0x00003250 / 0x000c0000
[ilink32 Warning] Warning: Publics : 0x0001c4d0 / 0x000c0000
[ilink32 Warning] Warning: SegRelocs : 0x00000708 / 0x00800000
[ilink32 Warning] Warning: StringBlock : 0x0000002b / 0x01000000
[ilink32 Warning] Warning: Virdefs : 0x00000008 / 0x00020000
[ilink32 Warning] Warning: unknown heap name : 0x08000000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilc: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ild: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilf: 0x00020000 / 0x0a000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ils: 0x00660000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.tds: 0x00010000 / 0x09400000
[ilink32 Warning] Warning: Extdef flags : 0x00000000 / 0x00008000
[ilink32 Warning] Warning: Extdefs : 0x00000000 / 0x00008000
[ilink32 Warning] Warning: Import symbols : 0x00000000 / 0x00100000
[ilink32 Warning] Warning: OBJ symbols : 0x00000000 / 0x00400000
[ilink32 Warning] Warning: Public GSX : 0x00000360 / 0x000c0000
[ilink32 Warning] Warning: Publics : 0x00001e60 / 0x000c0000
[ilink32 Warning] Warning: StringBlock : 0x00000012 / 0x01000000
[ilink32 Warning] Warning: Virdefs : 0x00000000 / 0x00020000
[ilink32 Warning] Warning: unknown heap name : 0x08000000 / 0x08000000
[ilink32 Warning] Warning: Error detected (LIB266)
[ilink32 Error] Error: Unable to perform link
Failed


I haven't found anything at all regarding this error except for an old post (17 years ago) that only mentions as possible cause having Debug and non Debug versions of the projects mixed. I have already reported an issue to Embarcadero's Jira (https://quality.embarcadero.com/browse/RSP-20278) but I would like to know if somebody has ever seen this, or has any idea of what does it mean and directions for a possible workaround.

Reproducing this is very simple but you need to have RO SDK: Just create a new C++Builder Package (or an Application that uses runtime packages), add a form, and drop a RO component in it. Compile and get the linker error.

As I have no idea of what the error means I am unable to even try to create a more compact test case. I am guessing is a very corner case (only 1 other issue ever found by Google!) so not something that could easily be reduced from the code that does produce the error right now. This also minimizes the chances of this being even looked at, unfortunately, but the fact remains that I can't use this library at all because of this.

I have spent two days trying different options in the RO' Packages but nothing has changed the outcome. As the other post indicated, I have compiled them with Debug info, wihtout it, and moved every other thing that comes to mind, but no luck. Without knowing the reason for the error it's just blindly trying things. The only thing that works, or appears to, is to create the Application with the option to use runtime packages disabled. But that is not viable here, to begin with because that's not a setting you can disable for a Package project.

I use Berlin for my programs, but I downloaded a trial version of Tokio (10.2.3) and exactly the same error happens. Actually, all my thinkering has been on that trial installation (as it is a VM which only has that installed).

Any help would be great!
Antonio Estevez

Posts: 665
Registered: 4/12/00
Re: Linker throwing error LIB266 - any idea what does it means?
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 5, 2018 11:25 AM   in response to: Rodrigo Gomez C... in response to: Rodrigo Gomez C...
El 05/04/2018 a las 0:50, Rodrigo Gomez Cordova escribió:
Hello,

Trying to use the latest RemObjects SDK (version 9.4, but this also happened with version 9.3) produces a linker error, LIB266:

[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilc: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ild: 0x00010000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ilf: 0x00020000 / 0x0a000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.ils: 0x00660000 / 0x08000000
[ilink32 Warning] Warning: C:/Users/Public/Documents/Embarcadero/Studio/19.0/BPL/Package1.tds: 0x00010000 / 0x09400000

I use Berlin for my programs, but I downloaded a trial version of Tokio (10.2.3) and exactly the same error happens. Actually, all my thinkering has been on that trial installation (as it is a VM which only has that installed).

Any help would be great!

Try setting "Disable incremental link" to true in project Options --> C++ Linker
Rodrigo Gomez C...

Posts: 32
Registered: 3/16/00
Re: Linker throwing error LIB266 - any idea what does it means?
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 5, 2018 3:16 PM   in response to: Antonio Estevez in response to: Antonio Estevez
Hello,

Antonio Estevez wrote:
Try setting "Disable incremental link" to true in project Options --> C++ Linker

Thanks. I have already tried that, but it's the same. As you can see in the log, the linker (or is it the IDE?) notices that the incremetal linker didn't work and then tries again with it disabled, but the result is the same. I have changed every option I can think in the original packages and the projects using that packages but no luck.
Martin van der ...

Posts: 57
Registered: 7/14/02
Re: Linker throwing error LIB266 - any idea what does it means?
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 5, 2018 11:52 PM   in response to: Rodrigo Gomez C... in response to: Rodrigo Gomez C...
Rodrigo Gomez Cordova wrote:
Hello,

Antonio Estevez wrote:
Try setting "Disable incremental link" to true in project Options --> C++ Linker

Thanks. I have already tried that, but it's the same. As you can see in the log, the linker (or is it the IDE?) notices that the incremetal linker didn't work and then tries again with it disabled, but the result is the same. I have changed every option I can think in the original packages and the projects using that packages but no luck.

Did you do a full rebuild? Sometimes it helps to clean the project, manually remove all .obj and other compiler-generated files, and then do a full rebuild.
Rodrigo Gomez C...

Posts: 32
Registered: 3/16/00
Re: Linker throwing error LIB266 - any idea what does it means?
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 6, 2018 7:47 AM   in response to: Martin van der ... in response to: Martin van der ...
Did you do a full rebuild? Sometimes it helps to clean the project, manually remove all .obj and other compiler-generated files, and then do a full rebuild.

Yes, this fails with a fresh project. It's just needed to add the bpi of the RemObjects_Core package to a package project (in the Requires section), no need to use or do anything else. i.e:
- Create a new C++Builder Package project.
- Add the RemObjects_Core bpi to the requires section.
- Build
-> You get the error.

There is something wrong with the bpi, it seems, that makes the linker crash.
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02