<?xml version="1.0" encoding="utf-16"?><html><head><style type="text/css"><![CDATA[#x555d9622cec04ce185f79b305d544ed9{
        font-family:Tahoma;
        font-size:12pt;
}]]><!--blockquote.cite2
{margin-left: 5px; margin-right: 0px; padding-left: 10px; padding-right: 0px; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); margin-top: 3px; padding-top: 0px;}
body
{font-family: Tahoma; font-size: 12pt;}
--></style></head><body><div>Well.</div><div><br /></div><div>All files that are needed by the linker, have to be found by the linker.</div><div>The osxcrosstools use a findfile process that is a bit peculiar. And not fully understood by me. Perhaps you can help.</div><div><br /></div><div>c++ code.</div><div><br /></div><div>findFile(path):</div><div>Options::FileInfo Options::findFile(const std::string &path) const</div><div>calls:</div><div><span style="font-size: 12pt;">if ( findFile(path, {".tbd"}, result) )</span></div>              return result;<div><br /><div><div id="x555d9622cec04ce185f79b305d544ed9"><div><div>findFile(path,{...},result):</div></div></div><div>bool Options::findFile(const std::string &path, const std::vector<std::string> &tbdExtensions, FileInfo& result) const</div><div>calls</div><div>for ( const auto &ext : tbdExtensions ) {</div><div>auto newPath = replace_extension(path, ext);</div><div>bool found = tbdInfo.checkFileExists(*this, newPath.c_str());</div><div>}</div><div><br /></div><div><br /></div><div>So, as far as I understand correctly, if a fpc abc.o file is presented towards the linker, it replaces the extension with tbd and goes looking for abc.tbd.</div><div>I checked: if I add a dummy abc.tbd in the same location, all goes well.</div><div><br /></div><div>That why I patched the search-process. But this very rude patch only took care of .o files.</div><div>I forgot about the .or files.</div><div><br /></div><div>Trying new patches at the moment to no avail unfortunately.</div><div><br /></div><div><br /></div><div><br /></div>
<div>------ Origineel bericht ------</div>
<div>Van: "Sven Barth" <<a href="mailto:pascaldragon@googlemail.com">pascaldragon@googlemail.com</a>></div>
<div>Aan: "Alfred" <<a href="mailto:alfred@consulab.nl">alfred@consulab.nl</a>>; "FPC developers' list" <<a href="mailto:fpc-devel@lists.freepascal.org">fpc-devel@lists.freepascal.org</a>></div>
<div>Verzonden: 21-11-2016 11:17:30</div>
<div>Onderwerp: Re: [fpc-devel] Crosscompiling win towards darwin</div><div><br /></div>
<div id="x2718b8f34625432"><blockquote cite="CAFMUeB-B7aNpbMFU+U0fg3kWqT=iO5ovzgpfjHJ2sWX07hmVcQ@mail.gmail.com" type="cite" class="cite2">
<p>Am 21.11.2016 10:15 schrieb "Alfred" <<a href="mailto:alfred@consulab.nl">alfred@consulab.nl</a>>:<br />
><br />
> Please skip my previous mail.<br />
><br />
> I think I found the problem.<br />
> I had to patch osxcross-tools to work with FPC.<br />
> Now I need a new patch to include .or files !</p>
<p>In how far did you have to patch the tools? The .or file should already be part of the linker script that FPC generates (you can get that with -sh, it's the link.res file).</p>
<p>Regards,<br />
Sven</p>
</blockquote></div>
</div></div></body></html>