www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From strobe anarkhos <anark...@mac.com>
Subject Re: mod_mime/7531: Apache lacks OSType <-> mime magic
Date Mon, 16 Apr 2001 06:46:27 GMT
>
>Since this is very platform specific, I suggest that the
>
>best way to deal with this is with a new module that
>
>would be used like mod_mime_magic only on Mac OSX.
>

The changes could be encapsulated by #ifdef _APPLE_. so they don't effect anybody else. (or
was that __APPLE__). Thus I can use the same module which can check the type and if null revert
to the filename extension mapping, or use the reverse logic where the file type mapping is
only used when the filename extension mapping fails.

The former behavior is the same logic OS X uses when opening files.

There are various Apache build instructions directed specifically at OS X users and they all
say to download the official release from you guys thus I would like it included with the
official source.

>
>This module would probably need to be distributed apart
>
>from Apache, since it would not be applicable to most
>
>users.  However, I will "suspend" this problem report
>
>for future consideration.
>

Most mods aren't used by 'most users' either.

The problem is when people build and install the official source it will replace the file
type wary mod_mime_magic with the 'official' version which would disable such features.

>
>Thanks for the suggestion.

If I get around to downloading the Apache source over my 288 slowdem and make a patch could
you submit it? It should be around three lines of new code and maybe a couple #ifdef _APPLE_
macros. You just pass the vnode or whatever of the file in question to a Darwin-specific function
and you have the 32bit OSType unit which you would match using a mime mapping flat file just
like the filename extension mime mapping flat file. What could be easier?

Mime
View raw message