Re: [cc65] [ca65] Include dir behaviour change between 2.13.3 and 2.13.9

From: Spiro Trikaliotis <ml-cc651trikaliotis.net>
Date: 2012-07-29 13:29:57
Hello Uz,

* On Fri, Jul 27, 2012 at 10:08:02PM +0200 Ullrich von Bassewitz wrote:
> 
> On Fri, Jul 27, 2012 at 07:39:02PM +0200, Spiro Trikaliotis wrote:
> > wenn including files from a ca65 source file, the behaviour of where the
> > file is searched has changed between 2.13.3 and a recent build of 2.13.9.
> 
> This has been discussed several times, for example here:
> 
>   http://www.cc65.org/mailarchive/2005-08/5178.html
> 
> The change was made on user request. You might want to study the "CBM file
> type mega thread" to learn that it is not easy to satisfy everybodies
> desires:-)

Indeed, I understand. I do not say that I want it the old way, I was
just confused (and bitten ;)) by the new behaviour. I can rearrange my
compilation, that is not a problem in itself.

However, IMHO, you are not completely consistent now, either. For ca65,
from some tests I did, I would conclude that the rules are as follows:

1. Look in the directory where the current assembled file lies, and try
   to include relative from here.

2. If we did not find anything, look in the directory that was current
   directory when ca65 was called, and look relative from here.

3. If we did not find anything until now, go through all the specified
   include directories and look from here.

Thus, it seems rule #1 was added in 2.13.9 compared to 2.13.3 (or was
the order of #1 and #2 changed?). Wouldn't it make more sense to
completely remove rule #2 then? This way, it would seem more consistent
to me.

Additionally, #2 can be added by the user simply by adding "-I ./" on
the command-line, so I do not see so much sense to have that rule there.

Even worse, even --forget-inc-paths does not change anything on #1 and
#2, only on #3. So, one cannot prevent rule #2 from happening.

In all the discussions in the ML I found (I even particpated in one, cf.
http://www.cc65.org/mailarchive/2010-01/index.html#7748), I always saw
people wanting #1, but noone saying that #2 should be preserved.

BTW: Will you document this change for 2.14? ;)

Regards,
Spiro.

-- 
Spiro R. Trikaliotis
http://www.trikaliotis.net/
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun Jul 29 13:30:22 2012

This archive was generated by hypermail 2.1.8 : 2012-07-29 13:30:27 CEST