How to handle Case-sensitive files?
Joshua Root
jmr at macports.org
Wed Jun 23 13:39:31 PDT 2010
On 2010-6-24 03:22 , Michael Dickens wrote:
> Related to tickets #22119 (supposedly fixed) and #22046 (still open), it
> seems as though qt4 4.6.3 and 4.7.0b1 both still have 2 sets of files
> that are different only in caps (content of all 4 is the same):
>
> {{{
> qt4-mac/include/phonon/Phonon
> qt4-mac/include/phonon/phonon
> }}}
>
> and (not surprisingly):
>
> {{{
> qt4-mac/lib/phonon.framework/Versions/4/Headers/Phonon
> qt4-mac/lib/phonon.framework/Versions/4/Headers/phonon
> }}}
>
> I will be the first to say that I think the use of only-Caps-different
> filenames is poor programming practice, and at least in this case I can
> make sure that just one of each set is installed. Non-withstanding my
> opinion, there will be ports that provide such files, without the
> Portfile developer's knowledge, and I think it's important for MacPorts
> to handle them correctly (whatever that ends up being); right now, they
> are not being robustly handled:
>
> When these files are activated, it looks like all are added to the
> MacPorts' "database" of installed files (e.g., for just the former set):
>
> {{{
> DEBUG: activating file:
> /opt/local/libexec/qt4-mac-devel/include/phonon/Phonon
> DEBUG: activating file:
> /opt/local/libexec/qt4-mac-devel/include/phonon/phonon
> DEBUG: Adding file to file_map:
> /opt/local/libexec/qt4-mac-devel/include/phonon/Phonon for:
> qt4-mac-devel
> DEBUG: Adding file to file_map:
> /opt/local/libexec/qt4-mac-devel/include/phonon/phonon for:
> qt4-mac-devel
> }}}
>
> But, when I deactivate the port, only the Uppercase version is
> deactivated; the lowercase version is left behind (again, just the
> former set):
>
> {{{
> DEBUG: deactivating file:
> /opt/local/libexec/qt4-mac-devel/include/phonon/Phonon
> DEBUG: Removing entry from file_map:
> /opt/local/libexec/qt4-mac-devel/include/phonon/Phonon
> }}}
>
> Now, if I activate this port again, port errors out with:
>
> {{{
> DEBUG: Image error: /opt/local/libexec/qt4-mac/include/phonon/phonon
> already exists and does not belong to a registered port. Unable to
> activate port qt4-mac. Use 'port -f activate qt4-mac' to force the
> activation.
> while executing
> "_activate_contents $name $imagefiles $imagedir"
> (procedure "portimage::activate" line 110)
> invoked from within
> "portimage::activate $portname $composite_version [array get options]"
> }}}
This is a known problem with the flat registry,
<http://trac.macports.org/ticket/14123>. Try switching to sqlite.
- Josh
More information about the macports-dev
mailing list