Ian Romanick wrote:
Brian Paul wrote:

Ian Romanick wrote:

Currently, the only functions that are aliased like this are both GLX_SGI_make_current_read functions, a few GLX_SGIX_fbconfig functions, and glXGetCurrentDisplayEXT (from GLX_EXT_import_context and GLX 1.2). Since this last function has been supported for so long in XFree86, it's the only one that I'm at all concerned about. In the future, some of the pbuffers functions may get the same treatment.


I guess I'd like to keep the existing "real" GLX extension functions whenever possible. Some apps/libs (like some varients of GLUT) have direct calls to some GLX functions like glXGetFBConfigAttribSGIX(). If those functions don't exist in libGL people may have problems. I see some reports of this kind of problem with NVIDIA's libGL and older copies of GLUT as-is.


I was afraid of that. I really don't want to have a bunch of gunk floating around in either the source or the binary. Would it be okay to use --defsym to have the linker do the aliasing? From the ld man page:

       --defsym symbol=expression
           Create a global symbol in the output file,  containing
           the absolute address given by expression.  You may use
           this option as many times as necessary to define  mul-
           tiple  symbols in the command line.  A limited form of
           arithmetic is supported for  the  expression  in  this
           context:  you  may  give a hexadecimal constant or the
           name of an existing symbol, or use "+" and "-" to  add
           or  subtract hexadecimal constants or symbols.  If you
           need more elaborate expressions,  consider  using  the
           linker  command  language  from a script.  Note: there
           should be no white space between  symbol,  the  equals
           sign (``=''), and expression.

We could add something like the following to the command-line to get the same effect as the aliasing in the GLX_functions table:

   --defsym glXMakeCurrentReadSGI=glXMakeContextCurrent \
   --defsym glXGetCurrentReadDrawableSGI=glXGetCurrentReadDrawable \
   --defsym glXGetCurrentDisplayEXT=glXGetCurrentDisplay \
   --defsym glXGetFBConfigAttribSGIX=glXGetFBConfigAttrib \
   --defsym glXChooseFBConfigSGIX=glXChooseFBConfig \
   --defsym glXGetVisualFromFBConfigSGIX=glXGetVisualFromFBConfig

That would work, but would it be acceptable?

Is that going to work on all platforms that libGL may be compiled on? That approach would probably also require some Imake hacking.

Otherwise, I'd prefer to just keep the functions as-is. I don't see them as "gunk". Maybe moving them all into a new file would make things cleaner?

-Brian



-------------------------------------------------------
This SF.net email is sponsored by Dice.com.
Did you know that Dice has over 25,000 tech jobs available today? From
careers in IT to Engineering to Tech Sales, Dice has tech jobs from the
best hiring companies. http://www.dice.com/index.epl?rel_code=104
_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to