x11/nvidia-driver incompatible with portmaster?

b. f. bf1783 at googlemail.com
Tue Jul 5 05:58:55 UTC 2011


On 7/3/11, Kostik Belousov <kostikbel at gmail.com> wrote:
> On Sun, Jul 03, 2011 at 12:45:50PM +0000, b. f. wrote:
>> On 7/3/11, Kostik Belousov <kostikbel at gmail.com> wrote:
>> > On Sun, Jul 03, 2011 at 03:54:15AM +0000, b. f. wrote:
>> >> On 7/3/11, Stephen Montgomery-Smith <stephen at missouri.edu> wrote:
>> >> > On 07/02/2011 09:02 PM, Stephen Montgomery-Smith wrote:
>> >> >> On 07/02/2011 08:39 PM, b. f. wrote:
>> ...
>> >
>> > That said, there is absolutely no need in any static linker tricks,
>> > esp. a heavy one like filters or linker scripts. A symlink named
...
>>
>> > libGL.so would be enough for the static linker, pointing to any
>> > of two libraries. And symlink libGL.so.1 would be also enough
>> > for dynamic linker.
>> >
>> > The real issue with xorg-server, mesa and nvidia driver is only
>> > the overwrite of extensions/libglx.so and lib/libGL.so.1. If
>> > this can be somewhat solved by the packaging system, that would
>> > be great. On my hybrid laptop I have to manually manage the
>> > said symlinks (actually, with the rc script that verifies
>> > the list of pci devices and arranges the symlinks).
>>
>> So basically, you would prefer that we:
>>
>> patch xorg-server so that it installs, e.g.,
>> ${PREFIX}/lib/xorg/modules/extensions/libglx-xorg.so.1 instead of
>> ${PREFIX}/lib/xorg/modules/extensions/libglx.so.1, and points the
>> symlink ${PREFIX}/lib/xorg/modules/extensions/libglx-xorg.so at the
>> former;
>>
>> patch libGL so that it installs, e.g., ${PREFIX}/lib/libGL-mesa.so.1
>> instead of ${PREFIX}/lib/libGL.so.1, and points the symlink
>> ${PREFIX}/lib/libGL.so at the former;
>>
>> and patch nvidia-driver so that it installs, e.g.,
>> ${PREFIX}/lib/xorg/modules/extensions/libglx-nvidia.so.1 instead of
>> ${PREFIX}/lib/xorg/modules/extensions/libglx.so.1, and
>> ${PREFIX}/lib/libGL-nvidia.so.1 instead of ${PREFIX}/lib/libGL.so.1;
>> and during installation it overwrites the
>> ${PREFIX}/lib/xorg/modules/extensions/libglx-xorg.so and
>> ${PREFIX}/lib/libGL.so symlinks, redirecting them to the corresponding
>> nvidia libraries; while during deinstallation it changes them to point
>> to the mesa/xorg libraries?
> Yes.
>
>>
>> And corresponding redirection to handle the libtool archive file?
> I do not think this is needed. First, I believe .la files are only
> installed by the Xorg ports. Second, as I described, libGL.so from
> Xorg and from NVidia should be replacable for the static linking
> purposes. Third, libglx.la is not used at all.
...
> On Sun, Jul 03, 2011 at 01:33:09PM +0000, b. f. wrote:
>> On second thought the renaming of these libraries is not very
>> convenient, since they are built by nvidia, and not necessary if their
>> mesa/xorg counterparts already have different names.
>
> As I said, it is useful for me on the hybrid laptop, where a switch
> selects the GPU attached to the panel. The startup script then would
> only need to create proper symlink, instead of delicate renaming
> of the libraries.

Please consider the attached patch.  Small unrelated clean-ups to
x11-servers/xorg-server and bsd.mesalib.mk are included with the
changes that remove the collisions, and add the necessary symlinks.
The renaming in the xorg-server post-install target is a bit ugly, but
much easier than dissecting the libtool build and installation of the
glx convenience library.  I used sed rather than patches for some of
the changes in libGL and nvidia-driver because of the multiple
distfiles involved.

b.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: nvidia_conflict.diff
Type: application/octet-stream
Size: 13059 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-x11/attachments/20110705/6045e6f8/nvidia_conflict.obj


More information about the freebsd-x11 mailing list