[VDPAU] Should we export these functions ? (Re: Exporting the flash workaround functions)
Reimar Döffinger
Reimar.Doeffinger at gmx.de
Wed Jul 2 18:01:34 PDT 2014
On 23.06.2014, at 23:05, Aaron Plattner <aplattner at nvidia.com> wrote:
> Correct, those symbols should not be exported. -fvisiblity=hidden or equivalent options sound like the right way to go there on sufficiently new compilers, though there are also no prototypes for them in the public API headers so it should be obvious that they're not part of the exported ABI...
Just for information/consideration: personally I always prefer version scripts.
They are/can be made compatible with other unix linkers, they also allow specifying versioning information, they can be converted to .def files for Windows (ok, probably not relevant here) and they collect the information in one file, without having to modify source files.
But I know some people prefer the -fvisibility approach, which is fine as well.
> On 06/23/2014 01:25 PM, Jose Soltren wrote:
>> Hi Emil:
>>
>> As far as we can tell, all of the _vdp_cap_init_planes_adapt_surface_*
>> functions in libvdpau_trace should be static. There is no good reason to export
>> them. Please feel free to submit patches against trace/vdpau_trace.cpp for
>> review if you'd like.
>>
>> As for the DRI2 functions referenced in src/vdpau_wrapper.c: I don't see a
>> reason for these to be non-static either. We implement our own mesa_dri2.c in
>> libvdpau and only use this internally. I've CC'd Aaron who might be able to
>> comment further. You are probably correct here as well.
>>
>> Thanks,
>> --José
>>
>> On 06/23/2014 02:52 PM, Emil Velikov wrote:
>>> The original title is a bit off, as I've originally assumed that the functions
>>> were introduced with the flash workarounds commits.
>>>
>>> -Emil
>>>
>>> On 23/06/14 20:33, Emil Velikov wrote:
>>>> Hi all,
>>>>
>>>> Just noticed that a few functions are non-static, thus in some cases we end up
>>>> exporting them.
>>>>
>>>> libvdpau:
>>>> _vdp_DRI2Connect
>>>> _vdp_DRI2QueryExtension
>>>> _vdp_DRI2QueryVersion
>>>> _vdp_DRI2RemoveExtension
>>>>
>>>> libvdpau_trace:
>>>> _vdp_cap_init_planes_adapt_surface_video
>>>> _vdp_cap_init_planes_adapt_surface_bitmap
>>>> _vdp_cap_init_planes_adapt_surface_output
>>>>
>>>> AFAICS the former ones cannot be annotated as static, although we can add the
>>>> appropriate compiler attributes, while the latter are most likely just missed
>>>> out in the orignal codedump. Are any of the above intended to be exported ?
>>>>
>>>> Cheers
>>>> Emil
>
> --
> Aaron
> _______________________________________________
> VDPAU mailing list
> VDPAU at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/vdpau
More information about the VDPAU
mailing list