pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/mk Makefiles that include oss.buildlink3.mk can now ch...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/cd51178421a4
branches:  trunk
changeset: 509691:cd51178421a4
user:      jlam <jlam%pkgsrc.org@localhost>
date:      Mon Mar 13 16:10:15 2006 +0000

description:
Makefiles that include oss.buildlink3.mk can now check the value of
OSS_TYPE to determine whether or not a native OSS implementation is
present or not.  OSS_TYPE just exports the value of IS_BUILIN.oss, but
exports it early enough where it can be used within a package Makefile,
e.g.:

        .include "../../mk/oss.buildlink3.mk"
        .if ${OSS_TYPE} == "none"
        CONFIGURE_ARGS+=        --without-oss
        .endif

This should fix builds of some packages that include "oss.buildlink3.mk"
on platforms where there is no OSS in the base system, e.g. Mac OS X
and Solaris.

diffstat:

 mk/oss.buildlink3.mk |  27 +++++++++++++++++++++++++--
 1 files changed, 25 insertions(+), 2 deletions(-)

diffs (45 lines):

diff -r d6855c900883 -r cd51178421a4 mk/oss.buildlink3.mk
--- a/mk/oss.buildlink3.mk      Mon Mar 13 15:05:57 2006 +0000
+++ b/mk/oss.buildlink3.mk      Mon Mar 13 16:10:15 2006 +0000
@@ -1,12 +1,33 @@
-# $NetBSD: oss.buildlink3.mk,v 1.3 2006/03/10 22:33:24 jlam Exp $
+# $NetBSD: oss.buildlink3.mk,v 1.4 2006/03/13 16:10:15 jlam Exp $
 #
 # This Makefile fragment is included by packages that require an Open Sound
-# System (OSS) implementation.
+# System (OSS) implementation.  After inclusion of this file, the following
+# variables may be examined:
+#
+#    OSS_TYPE
+#      The type of OSS implementation that has been found.  "native"
+#      means the native OSS implementation is used.  "none" means that
+#      no suitable OSS implementation could be found.
 #
 OSS_BUILDLINK3_MK:=    ${OSS_BUILDLINK3_MK}+
 
 .include "../../mk/bsd.prefs.mk"
 
+.if !defined(_OSS_TYPE)
+_OSS_TYPE=             none
+CHECK_BUILTIN.oss:=    yes
+.  include "../../mk/oss.builtin.mk"
+CHECK_BUILTIN.oss:=    no
+.  if defined(IS_BUILTIN.oss) && !empty(IS_BUILTIN.oss:M[yY][eE][sS])
+_OSS_TYPE=             native
+.  endif
+.endif
+MAKEVARS+=             _OSS_TYPE
+
+OSS_TYPE=              ${_OSS_TYPE}
+
+.if ${OSS_TYPE} != "none"
+
 BUILDLINK_PACKAGES:=           ${BUILDLINK_PACKAGES:Noss}
 BUILDLINK_PACKAGES+=           oss
 BUILDLINK_BUILTIN_MK.oss=      ../../mk/oss.builtin.mk
@@ -29,3 +50,5 @@
 MAKE_ENV+=             DEVOSSAUDIO=${DEVOSSAUDIO:Q}
 MAKE_ENV+=             DEVOSSSOUND=${DEVOSSSOUND:Q}
 .endif # OSS_BUILDLINK3_MK
+
+.endif # OSS_TYPE != none



Home | Main Index | Thread Index | Old Index