issue-#58 fixes in HostPackedFiles

Post Reply
User avatar
Josef Templ
Posts: 2047
Joined: Tue Sep 17, 2013 6:50 am

issue-#58 fixes in HostPackedFiles

Post by Josef Templ »

The fixes of HostPackedFiles are in topic branch issue-#58. This is the last sub-issue of
CPC 1.7 change list number 27.

For the issue and for the associated changes for every single commit see http://redmine.blackboxframework.org/issues/58.
For the list of all changes see http://redmine.blackboxframework.org/pr ... 7b8db5a5b5.

The changes are as proposed in CPC 1.7 rc5. Except for the fixes res codes there are no
differences observable by the user.

- Josef
User avatar
Josef Templ
Posts: 2047
Joined: Tue Sep 17, 2013 6:50 am

Re: issue-#58 fixes in HostPackedFiles

Post by Josef Templ »

Zinn wrote:
Josef Templ wrote:It's a cosmetic change without any difference in the behavior.
Except for linking. Kernel is in the link list anyway, but you have to add Math and Strings when you introduced Strings in your module.

Here is an example: In BB 1.6 I can link
DevLinker.Link Abgleich.exe :=
Kernel$+ Files HostFiles HostPackedFiles StdLoader
1 Applogo.ico 2 Doclogo.ico 3 SFLogo.ico 4 CFLogo.ico 5 DtyLogo.ico
6 folderimg.ico 7 openimg.ico 8 leafimg.ico
1 Move.cur 2 Copy.cur 3 Link.cur 4 Pick.cur 5 Stop.cur 6 Hand.cur 7 Table.cur

But in BB 1.7 I have to add Math and Strings in the above list because HostPackedFiles uses Strings instead of Kernel.

Here is an open point for discussion. I'm not sure which way to prefer - using Kernel or String. It is an internal translation.
I was not aware of this particular problem in HostPackedFiles so I did a more careful analysis.
It turned out that there is a hidden dependency with DevDependencies, which uses the knowledge
that HostPackedFiles does not import anything except Kernel and Files.
This dependency can be seen in the CreateTool command, which generates a link command
that contains HostPackedFiles. It generates it in a hard-coded way, i.e. without looking at the
existing dependencies but assumes that there are none to be cared for.

So a possible simple solution would be to use Kernel instead of Strings here and to add a comment
that makes it explicit that there must not be any other imports because of this connection with
DevDependencies. Here we have a strong argument to bypass Strings indeed.

In order not to mix up issues, this fix should to be assigned to #19, of course.

- Josef
Post Reply