pkgsrc/devel/SDL/Makefile.common
hubertf 1a9aac4eaf Document why we don't need Mesa on Irix.
If more pkgs like this are found that work fine with Irix'
native GL, the Mesa buildlink3.mk file should take care of this.
2004-08-24 21:07:04 +00:00

76 lines
2.1 KiB
Makefile

# $NetBSD: Makefile.common,v 1.16 2004/08/24 21:07:04 hubertf Exp $
#
DISTNAME= SDL-1.2.7
CATEGORIES= devel games
MASTER_SITES= http://www.libsdl.org/release/
MAINTAINER= wiz@NetBSD.org
HOMEPAGE= http://www.libsdl.org/
COMMENT= Simple DirectMedia Layer, a cross-platform multimedia library
DISTINFO_FILE= ${.CURDIR}/../../devel/SDL/distinfo
PATCHDIR= ${.CURDIR}/../../devel/SDL/patches
USE_BUILDLINK3= YES
USE_X11= YES
GNU_CONFIGURE= YES
USE_GNU_TOOLS+= make
USE_LANGUAGES= c c++
PTHREAD_OPTS+= require
USE_LIBTOOL= YES
.include "../../mk/bsd.prefs.mk"
.if ${MACHINE_ARCH} == "i386"
. include "../../devel/binutils/buildlink3.mk"
BUILD_DEPENDS+= nasm>=0.98:../../devel/nasm
NASMFLAGS_ELF= -f elf
NASMFLAGS_a.out= -f aoutb
.endif
CONFIGURE_ARGS+= --enable-dlopen
CONFIGURE_ARGS+= --disable-arts
CONFIGURE_ARGS+= --disable-esd
CONFIGURE_ARGS+= --disable-nas
CONFIGURE_ARGS+= --enable-video-aalib
CONFIGURE_ENV+= NASMFLAGS="${NASMFLAGS_${OBJECT_FMT}}"
MAKE_ENV+= NASMFLAGS="${NASMFLAGS_${OBJECT_FMT}}"
# Pass in LDFLAGS via SYSTEM_LIBS as it's used as the linker options for
# finding various libraries. This ensure that any unusual -Wl,-R options
# are noted correctly in the generated sdl-config.
#
CONFIGURE_ENV+= SYSTEM_LIBS="${LDFLAGS}"
# buildlink passthru the directories required for the Cocoa framework
# on Darwin if they exist.
.if ${OPSYS} == "Darwin"
COCOA_DIRS+= /System /Library /Developer
. for _dir_ in ${COCOA_DIRS}
. if exists(${_dir_})
BUILDLINK_PASSTHRU_DIRS+= ${_dir_}
. endif
. endfor
.endif
.include "../../mk/ossaudio.buildlink3.mk"
. if defined(HAVE_OSS) && ${HAVE_OSS} == "YES"
AM_CFLAGS= -D_PATH_DEV_DSP=\\\"${DEVOSSAUDIO}\\\"
MAKE_ENV+= AM_CFLAGS="${AM_CFLAGS}"
.endif
# Irix comes with GL, which works fine for SDL
.if ${OPSYS} != "IRIX"
.include "../../graphics/Mesa/buildlink3.mk"
.endif
.include "../../graphics/aalib-x11/buildlink3.mk"
.include "../../mk/pthread.buildlink3.mk"
.if defined(PTHREAD_TYPE) && ${PTHREAD_TYPE} == "pth"
# Let SDL know that we do not have native pthreads and are using GNU pth.
CONFIGURE_ARGS+= --disable-pthreads
CONFIGURE_ARGS+= --enable-pth
.endif