httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William A. Rowe, Jr." <wr...@rowe-clan.net>
Subject RE: [patch 2.0] hook linkage, take 2
Date Wed, 11 Oct 2000 14:12:30 GMT
> From: Greg Stein [mailto:gstein@lyra.org]
> Sent: Wednesday, October 11, 2000 3:46 AM
> 
> Ah. I missed it the first time, and almost missed it this time. The
> dllexport vs dllimport thang. Blarg. That isn't clear.
> 
> How about this: (with appropriate grandfathering)
> 
> AP_DECLARE(type)    /* or maybe AP_DECL */
> AP_DECLARE_NONSTD(type)
> AP_DECLARE_VAR
> AP_IMPL(type)       /* maybe AP_DEFINE / AP_DEFN, but that's 
> a bit too */
> AP_IMPL_VAR         /* close to AP_DECLARE / AP_DECL */
> 
> The above would be a bit more obvious what is going on.
> 
> And to be clear: only Apache needs to use these, right? Third 
> party modules would never use the above macros?
> [ although they would use a variant to export syms to other 
> modules, such as mod_dav's needs ]

Ok... what if a bit of magic was used to declare entire matching sets.
If I can nest the macro declaration... one macro would declare the macros 
of all three flavors...

  _DECLARE_VAR               prefixes a data declaration
  _DECLARE_NONSTD(type) fn() is a portable (potentially pascal)
                             non-varargs compatible fn.
  _DECLARE(type) fn()        harry c (e.g. varargs) incompatable fn

for all platforms and compiler symbol tests with the simple syntax:

AP_LINKAGE_DECLARATION(prefix)

On to prefixes:

  EXPORT_  just what it says
  APR_     our favorite portability dll
  AP_      our favorite core server dll
  DAV_     modules, such as DAV_ would get their own symbol set out of
           calling a single macro to set things up.

Would this make things cleaner?  [The reason AP_ was not used for the core
in the first place was this lingering ap library.  It looks like it will
rear it's head again.  Can we do so with a clean, new name e.g. APF, if it
will be an external library?]

I'm going on with the first issue, the patch at hand.  Feel free to debate
this a while, although I will proceed to build that macro now.


Mime
View raw message