From ad3a1d1fbf2f50115514592d6f316c0802d51455 Mon Sep 17 00:00:00 2001 From: kwm Date: Tue, 7 Aug 2012 16:42:38 +0000 Subject: Add the current solution for the pkgng where libGL (libGL.so), xorg-server (libglx.so) and the versions installed by nvidia-driver conflict. This patch is still under review by the nvidia maintainer. git-svn-id: https://trillian.chruetertee.ch/svn/ports/trunk@561 058c260c-8361-11dd-a0ac-aa2bafec7d09 --- x11-servers/xorg-server/Makefile | 23 +++++++++++++++++++---- x11-servers/xorg-server/files/pkg-deinstall.in | 12 ++++++++++++ x11-servers/xorg-server/files/pkg-install.in | 25 +++++++++++++++++++++++++ x11-servers/xorg-server/pkg-plist | 3 +-- 4 files changed, 57 insertions(+), 6 deletions(-) create mode 100644 x11-servers/xorg-server/files/pkg-deinstall.in create mode 100644 x11-servers/xorg-server/files/pkg-install.in (limited to 'x11-servers') diff --git a/x11-servers/xorg-server/Makefile b/x11-servers/xorg-server/Makefile index b713da0..c669b08 100644 --- a/x11-servers/xorg-server/Makefile +++ b/x11-servers/xorg-server/Makefile @@ -22,15 +22,16 @@ RUN_DEPENDS= xkeyboard-config>=2.5:${PORTSDIR}/x11/xkeyboard-config \ xkbcomp:${PORTSDIR}/x11/xkbcomp XORG_CAT= xserver +SLAVE_PORT?= no .if defined(WITH_NEW_XORG) XORG_VERSION= 1.12.3 -XORG_REVISION= 0 +XORG_REVISION= 1 PLIST_SUB+= OLD="@comment " NEW="" EXTRA_PATCHES+= ${FILESDIR}/extra-clang .else XORG_VERSION= 1.7.7 -XORG_REVISION= 4 +XORG_REVISION= 6 PLIST_SUB+= OLD="" NEW="@comment " EXTRA_PATCHES+= ${FILESDIR}/extra-include_eventstr.h \ ${FILESDIR}/extra-os-utils.c \ @@ -58,7 +59,8 @@ CONFIGURE_ARGS?=--disable-dmx --disable-xvfb --disable-xnest \ --localstatedir=/var --without-dtrace --disable-xephyr \ --enable-record=yes -.if !defined(SLAVE_PORT) +.if ${SLAVE_PORT} == "no" +SUB_FILES= pkg-install pkg-deinstall MAN1= Xorg.1 \ Xserver.1 \ cvt.1 \ @@ -153,10 +155,23 @@ pre-everything:: post-patch: @${REINPLACE_CMD} 's/test.*-traditional.*;/true;/' \ ${WRKSRC}/configure +# build libglx.so and manualy install it. + @${REINPLACE_CMD} -e 's|@GLX_TRUE@GLXMODS =|@GLX_BOGUS@GLXMODS =|g' \ + -e 's|^LTLIBRARIES = |LTLIBRARIES = libglx.la |g' \ + ${WRKSRC}/hw/xfree86/dixmods/Makefile.in + +.if ${SLAVE_PORT} == "no" +pre-install: + ${MKDIR} ${PREFIX}/lib/xorg/modules/extensions/xorg + ${INSTALL_LIB} ${WRKSRC}/hw/xfree86/dixmods/.libs/libglx.so \ + ${PREFIX}/lib/xorg/modules/extensions/xorg/ + PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL -.if defined(WITH_NEW_XORG) post-install: +.if defined(WITH_NEW_XORG) @${MKDIR} ${PREFIX}/share/X11/xorg.conf.d .endif + PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL +.endif .include diff --git a/x11-servers/xorg-server/files/pkg-deinstall.in b/x11-servers/xorg-server/files/pkg-deinstall.in new file mode 100644 index 0000000..3f903b1 --- /dev/null +++ b/x11-servers/xorg-server/files/pkg-deinstall.in @@ -0,0 +1,12 @@ +#!/bin/sh +# +# $FreeBSD$ +# + +PREFIX="${PKG_PREFIX-/usr/local}" + +case $2 in + POST-DEINSTALL) + /bin/rm -rf ${PREFIX}/lib/xorg/modules/extensions/libglx.so* + ;; +esac diff --git a/x11-servers/xorg-server/files/pkg-install.in b/x11-servers/xorg-server/files/pkg-install.in new file mode 100644 index 0000000..1ea3f64 --- /dev/null +++ b/x11-servers/xorg-server/files/pkg-install.in @@ -0,0 +1,25 @@ +#!/bin/sh +# +# $FreeBSD$ +# + +PREFIX="${PKG_PREFIX-/usr/local}" + +case $2 in +# Do we need this? + PRE-INSTALL) + /bin/rm -f ${PREFIX}/lib/xorg/modules/extensions/libglx.* + ;; + + POST-INSTALL) + if [ -f ${PREFIX}/lib/xorg/modules/extensions/nvidia/libglx.so.1 ]; then + /bin/ln -f ${PREFIX}/lib/xorg/modules/extensions/nvidia/libglx.so.1 \ + ${PREFIX}/lib/xorg/modules/extensions/libglx.so + /bin/ln -f ${PREFIX}/lib/xorg/modules/extensions/nvidia/libglx.so.1 \ + ${PREFIX}/lib/xorg/modules/extensions/libglx.so.1 + else + /bin/ln -f ${PREFIX}/lib/xorg/modules/extensions/xorg/libglx.so \ + ${PREFIX}/lib/xorg/modules/extensions/libglx.so + fi + ;; +esac diff --git a/x11-servers/xorg-server/pkg-plist b/x11-servers/xorg-server/pkg-plist index 6dc16b2..6f54b89 100644 --- a/x11-servers/xorg-server/pkg-plist +++ b/x11-servers/xorg-server/pkg-plist @@ -183,10 +183,9 @@ lib/xorg/modules/extensions/libdri2.la lib/xorg/modules/extensions/libdri2.so lib/xorg/modules/extensions/libextmod.la lib/xorg/modules/extensions/libextmod.so -lib/xorg/modules/extensions/libglx.la -lib/xorg/modules/extensions/libglx.so lib/xorg/modules/extensions/librecord.la lib/xorg/modules/extensions/librecord.so +lib/xorg/modules/extensions/xorg/libglx.so lib/xorg/modules/libexa.la lib/xorg/modules/libexa.so lib/xorg/modules/libfb.la -- cgit v1.2.3