pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/graphics Add Makefile.version and glx-config.mk so tha...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/50a0c0f9d61d
branches:  trunk
changeset: 547534:50a0c0f9d61d
user:      bjs <bjs%pkgsrc.org@localhost>
date:      Thu Sep 18 21:10:28 2008 +0000

description:
Add Makefile.version and glx-config.mk so that x11/modular-xorg-server
can share this information in lieu of us duplicating it by hand.

diffstat:

 graphics/Mesa/Makefile.common  |  18 +++---------
 graphics/Mesa/Makefile.version |  22 +++++++++++++++
 graphics/MesaLib/Makefile      |  55 +-------------------------------------
 graphics/MesaLib/glx-config.mk |  59 ++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 88 insertions(+), 66 deletions(-)

diffs (200 lines):

diff -r bba18486ba1e -r 50a0c0f9d61d graphics/Mesa/Makefile.common
--- a/graphics/Mesa/Makefile.common     Thu Sep 18 21:07:58 2008 +0000
+++ b/graphics/Mesa/Makefile.common     Thu Sep 18 21:10:28 2008 +0000
@@ -1,15 +1,16 @@
-# $NetBSD: Makefile.common,v 1.69 2008/08/23 02:51:19 dsainty Exp $
+# $NetBSD: Makefile.common,v 1.70 2008/09/18 21:10:28 bjs Exp $
 #
 # This Makefile fragment is included either directly or indirectly (through
 # Makefile.lib) by all packages that are built from the Mesa sources.
 #
 # used by graphics/Mesa/Makefile.lib
 
-DISTNAME?=     MesaLib-${MESA_VERSION}
+.include "../../graphics/Mesa/Makefile.version"
+
+DISTNAME?=     ${MESA_DISTNAME}
 EXTRACT_SUFX=  .tar.bz2
 CATEGORIES=    graphics
-#MASTER_SITES= ${MASTER_SITE_LOCAL:=Mesa-${MESA_VERSION}/}
-MASTER_SITES=  ${MASTER_SITE_SOURCEFORGE:=mesa3d/}
+MASTER_SITES=  ${MESA_SITES}
 
 # When changing this version, please run "make distinfo" in the following
 # package directories:
@@ -17,15 +18,6 @@
 #      graphics/MesaLib
 #      graphics/glx-utils
 #
-MESA_VERSION=          7.0.4
-MESA_PKGVERSION=       ${MESA_VERSION}${MESA_PATCHLEVEL}
-#MESA_PATCHFILES=      001 002 003
-MESA_PATCHLEVEL=       .1
-
-#PATCHFILES=           ${MESA_PATCHFILES:@.p.@Mesa-${MESA_VERSION}-${.p.}@}
-#PATCH_SITES=          ftp://ftp.NetBSD.org/pub/NetBSD/misc/bjs/patchfiles/
-#PATCH_DIST_STRIP=     -p1
-
 MAINTAINER=            bjs%NetBSD.org@localhost
 HOMEPAGE=              http://www.mesa3d.org/
 
diff -r bba18486ba1e -r 50a0c0f9d61d graphics/Mesa/Makefile.version
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/Mesa/Makefile.version    Thu Sep 18 21:10:28 2008 +0000
@@ -0,0 +1,22 @@
+# $NetBSD: Makefile.version,v 1.1 2008/09/18 21:10:28 bjs Exp $
+#
+# When changing this version, please run "make distinfo" in the following
+# package directories:
+#
+#      graphics/MesaLib
+#      graphics/glx-utils
+#
+# used by graphics/Mesa/Makefile.common
+# used by x11/modular-xorg-server/options.mk
+
+MESA_DISTNAME=                 MesaLib-${MESA_VERSION}
+MESA_SITES=            ${MASTER_SITE_SOURCEFORGE:=mesa3d/}
+
+MESA_VERSION=          7.0.4
+MESA_PKGVERSION=       ${MESA_VERSION}${MESA_PATCHLEVEL}
+#MESA_PATCHFILES=      001 002 003
+MESA_PATCHLEVEL=       .1
+
+#PATCHFILES=           ${MESA_PATCHFILES:@.p.@Mesa-${MESA_VERSION}-${.p.}@}
+#PATCH_SITES=          ftp://ftp.NetBSD.org/pub/NetBSD/misc/bjs/patchfiles/
+#PATCH_DIST_STRIP=     -p1
diff -r bba18486ba1e -r 50a0c0f9d61d graphics/MesaLib/Makefile
--- a/graphics/MesaLib/Makefile Thu Sep 18 21:07:58 2008 +0000
+++ b/graphics/MesaLib/Makefile Thu Sep 18 21:10:28 2008 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.72 2008/09/06 13:00:31 wiz Exp $
+# $NetBSD: Makefile,v 1.73 2008/09/18 21:10:28 bjs Exp $
 
 PKGNAME=       MesaLib-${MESA_PKGVERSION}
 COMMENT=       Graphics library similar to SGI's OpenGL
@@ -13,60 +13,9 @@
 PKG_DESTDIR_SUPPORT=   user-destdir
 
 BUILD_DEFS+=           MESA_HZ
-###
-### XXX Older versions of xf86driproto installed dri_interface.h, which
-###    is now installed by Mesa.
-###
-BUILDLINK_API_DEPENDS.driproto+=       xf86driproto>=2.0.4
-
-.include "../../mk/bsd.prefs.mk"
-
-CFLAGS.NetBSD+=        -D_NETBSD_SOURCE
-CFLAGS.NetBSD+=        ${ATOMIC_OPS_CHECK}HAVE_NETBSD_ATOMIC_OPS
-
-.if ${OPSYS} == "NetBSD" && !target(netbsd-atomic-ops-check)
-netbsd-atomic-ops-check:
-ATOMIC_OPS_CHECK!=\
-  if ( ${NM} /usr/lib/libc.so | ${GREP} -q atomic_cas_uint ); then     \
-    ${ECHO} "-D";      \
-  else \
-    ${ECHO} "-U";      \
-  fi
-.endif
-
-.if (${MACHINE_ARCH} == "x86_64" || \
-    ${MACHINE_ARCH} == "sparc64" || \
-    ${MACHINE_ARCH} == "alpha")
-CFLAGS+=       -D__GLX_ALIGN64
-.endif
-
-.if !empty(MACHINE_ARCH:Mi386) || !empty(MACHINE_ARCH:Mx86_64)
-###
-### This is taken from <sys/arch/i386/include/npx.h>.  If we don't override
-### it, the FPU control word will be restored to 0x037f.
-###
-### Also, see patch-aq about the libm functions required (float functions
-### such as floorf).  Proper configuration of this should be a goal of
-### the Mesa developers; alas, it obviously is not.
-###
-### XXX We need a reliable check for these functions.
-###
-#/* NetBSD uses IEEE double precision. */
-CFLAGS.NetBSD+=                -DDEFAULT_X86_FPU=0x127f
-###
-###
-#/* FreeBSD leaves some exceptions unmasked as well. */
-###
-CFLAGS.FreeBSD+=       -DDEFAULT_x86_FPU=0x1272
-.endif
-
-CFLAGS.FreeBSD+=       -DUSE_NATIVE_LIBM_FUNCS
-CFLAGS.Linux+=         -DUSE_NATIVE_LIBM_FUNCS
-CFLAGS.NetBSD+=                -DUSE_NATIVE_LIBM_FUNCS
-CFLAGS.DragonFly+=     -DUSE_NATIVE_LIBM_FUNCS
-
 PLIST_VARS=            dri nodri
 
+.include "glx-config.mk"
 .include "../../graphics/Mesa/Makefile.lib"
 .include "options.mk"
 
diff -r bba18486ba1e -r 50a0c0f9d61d graphics/MesaLib/glx-config.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/MesaLib/glx-config.mk    Thu Sep 18 21:10:28 2008 +0000
@@ -0,0 +1,59 @@
+# $NetBSD: glx-config.mk,v 1.1 2008/09/18 21:10:28 bjs Exp $
+#
+# used by x11/modular-xorg-server/options.mk
+
+.if !defined(GLX_CONFIG_MK)
+GLX_CONFIG_MK= # empty
+
+### XXX Older versions of xf86driproto installed dri_interface.h, which
+###    is now installed by Mesa.
+###
+BUILDLINK_API_DEPENDS.driproto+=       xf86driproto>=2.0.4
+
+.  include "../../mk/bsd.fast.prefs.mk"
+
+CFLAGS.NetBSD+=        -D_NETBSD_SOURCE
+CFLAGS.NetBSD+=        ${ATOMIC_OPS_CHECK}HAVE_NETBSD_ATOMIC_OPS
+
+.  if ${OPSYS} == "NetBSD" && !target(netbsd-atomic-ops-check)
+.  PHONY:      netbsd-atomic-opts-check
+netbsd-atomic-ops-check:
+ATOMIC_OPS_CHECK!=\
+  if ( ${NM} /usr/lib/libc.so | ${GREP} -q atomic_cas_uint ); then     \
+    ${ECHO} "-D";      \
+  else \
+    ${ECHO} "-U";      \
+  fi
+.endif
+
+.if (${MACHINE_ARCH} == "x86_64" || \
+    ${MACHINE_ARCH} == "sparc64" || \
+    ${MACHINE_ARCH} == "alpha")
+CFLAGS+=       -D__GLX_ALIGN64
+.endif
+
+.if !empty(MACHINE_ARCH:Mi386) || !empty(MACHINE_ARCH:Mx86_64)
+###
+### This is taken from <sys/arch/i386/include/npx.h>.  If we don't override
+### it, the FPU control word will be restored to 0x037f.
+###
+### Also, see patch-aq about the libm functions required (float functions
+### such as floorf).  Proper configuration of this should be a goal of
+### the Mesa developers; alas, it obviously is not.
+###
+### XXX We need a reliable check for these functions.
+###
+#/* NetBSD uses IEEE double precision. */
+CFLAGS.NetBSD+=                -DDEFAULT_X86_FPU=0x127f
+###
+#/* FreeBSD leaves some exceptions unmasked as well. */
+###
+CFLAGS.FreeBSD+=       -DDEFAULT_x86_FPU=0x1272
+.  endif
+
+CFLAGS.FreeBSD+=       -DUSE_NATIVE_LIBM_FUNCS
+CFLAGS.Linux+=         -DUSE_NATIVE_LIBM_FUNCS
+CFLAGS.NetBSD+=                -DUSE_NATIVE_LIBM_FUNCS
+CFLAGS.DragonFly+=     -DUSE_NATIVE_LIBM_FUNCS
+
+.endif # GLX_CONFIG_MK



Home | Main Index | Thread Index | Old Index