2009-03-20 20:23:50 +01:00
|
|
|
# $NetBSD: oss.buildlink3.mk,v 1.10 2009/03/20 19:25:01 joerg Exp $
|
2006-03-09 21:23:13 +01:00
|
|
|
#
|
|
|
|
# This Makefile fragment is included by packages that require an Open Sound
|
2006-03-13 17:10:15 +01:00
|
|
|
# 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.
|
2006-03-09 21:23:13 +01:00
|
|
|
#
|
|
|
|
OSS_BUILDLINK3_MK:= ${OSS_BUILDLINK3_MK}+
|
|
|
|
|
2006-03-10 23:33:24 +01:00
|
|
|
.include "../../mk/bsd.prefs.mk"
|
|
|
|
|
2006-03-13 17:10:15 +01:00
|
|
|
.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"
|
|
|
|
|
2009-03-20 20:23:50 +01:00
|
|
|
BUILDLINK_TREE+= oss -oss
|
2006-03-09 21:23:13 +01:00
|
|
|
BUILDLINK_BUILTIN_MK.oss= ../../mk/oss.builtin.mk
|
|
|
|
|
|
|
|
.if !empty(OSS_BUILDLINK3_MK:M+)
|
|
|
|
LIBOSSAUDIO?= ${BUILDLINK_LDADD.oss}
|
|
|
|
. if (${OPSYS} == "Linux") && exists(/dev/dsp)
|
|
|
|
DEVOSSAUDIO?= /dev/dsp
|
|
|
|
DEVOSSSOUND?= /dev/dsp
|
2007-02-25 01:29:27 +01:00
|
|
|
. elif ${OPSYS} == "DragonFly"
|
2008-11-11 14:26:42 +01:00
|
|
|
DEVOSSAUDIO?= /dev/dsp
|
2007-02-25 01:29:27 +01:00
|
|
|
DEVOSSSOUND?= /dev/dsp
|
2009-03-19 21:12:00 +01:00
|
|
|
. elif ${OPSYS} == "FreeBSD"
|
|
|
|
. if !empty(OS_VERSION:M4.*) || !empty(OS_VERSION:M5.[12]*)
|
|
|
|
DEVOSSAUDIO?= /dev/dsp
|
|
|
|
DEVOSSSOUND?= /dev/dsp
|
|
|
|
. else
|
|
|
|
DEVOSSAUDIO?= /dev/dsp0.0
|
|
|
|
DEVOSSSOUND?= /dev/dsp0.0
|
|
|
|
. endif
|
2006-03-09 21:23:13 +01:00
|
|
|
. else
|
|
|
|
DEVOSSAUDIO?= /dev/audio
|
|
|
|
DEVOSSSOUND?= /dev/sound
|
|
|
|
. endif
|
|
|
|
|
|
|
|
CONFIGURE_ENV+= LIBOSSAUDIO=${LIBOSSAUDIO:Q}
|
|
|
|
CONFIGURE_ENV+= DEVOSSAUDIO=${DEVOSSAUDIO:Q}
|
|
|
|
CONFIGURE_ENV+= DEVOSSSOUND=${DEVOSSSOUND:Q}
|
|
|
|
|
|
|
|
MAKE_ENV+= LIBOSSAUDIO=${LIBOSSAUDIO:Q}
|
|
|
|
MAKE_ENV+= DEVOSSAUDIO=${DEVOSSAUDIO:Q}
|
|
|
|
MAKE_ENV+= DEVOSSSOUND=${DEVOSSSOUND:Q}
|
|
|
|
.endif # OSS_BUILDLINK3_MK
|
2006-03-13 17:10:15 +01:00
|
|
|
|
|
|
|
.endif # OSS_TYPE != none
|