416f3812159bdb043997da81c5f38132b80a7737
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / sdl_sound / sdl_sound.mk
1 ################################################################################
2 #
3 # sdl_sound
4 #
5 ################################################################################
6
7 SDL_SOUND_VERSION = 1.0.3
8 SDL_SOUND_SOURCE = SDL_sound-$(SDL_SOUND_VERSION).tar.gz
9 SDL_SOUND_SITE = http://icculus.org/SDL_sound/downloads
10 SDL_SOUND_LICENSE = LGPLv2.1+
11 SDL_SOUND_LICENSE_FILES = COPYING
12 SDL_SOUND_INSTALL_STAGING = YES
13 SDL_SOUND_DEPENDENCIES = sdl
14
15 ifneq ($(BR2_ENABLE_LOCALE),y)
16 SDL_SOUND_DEPENDENCIES += libiconv
17 endif
18
19 # optional dependencies
20 ifeq ($(BR2_PACKAGE_FLAC),y)
21 SDL_SOUND_DEPENDENCIES += flac # is only used if ogg is also enabled
22 endif
23
24 ifeq ($(BR2_PACKAGE_LIBVORBIS),y)
25 SDL_SOUND_DEPENDENCIES += libvorbis
26 endif
27
28 ifeq ($(BR2_PACKAGE_SPEEX),y)
29 SDL_SOUND_DEPENDENCIES += speex
30 endif
31
32 SDL_SOUND_CONF_OPTS = \
33         --with-sdl-prefix=$(STAGING_DIR)/usr \
34         --with-sdl-exec-prefix=$(STAGING_DIR)/usr \
35         --disable-sdltest \
36         --enable-static
37
38 ifeq ($(BR2_X86_CPU_HAS_MMX),y)
39 SDL_SOUND_CONF_OPTS += --enable-mmx
40 else
41 SDL_SOUND_CONF_OPTS += --disable-mmx
42 endif
43
44 define SDL_SOUND_REMOVE_PLAYSOUND
45         rm $(addprefix $(TARGET_DIR)/usr/bin/,playsound playsound_simple)
46 endef
47
48 ifneq ($(BR2_PACKAGE_SDL_SOUND_PLAYSOUND),y)
49 SDL_SOUND_POST_INSTALL_TARGET_HOOKS += SDL_SOUND_REMOVE_PLAYSOUND
50 endif
51
52 $(eval $(autotools-package))