| 1 | # $Id: $
|
|---|
| 2 | ## @file
|
|---|
| 3 | #
|
|---|
| 4 | # kBuild SDK - libsdl (default target only).
|
|---|
| 5 | #
|
|---|
| 6 | # Copyright (c) 2006 knut st. osmundsen <bird-srcspam@anduin.net>
|
|---|
| 7 | #
|
|---|
| 8 | #
|
|---|
| 9 | # This file is part of kBuild.
|
|---|
| 10 | #
|
|---|
| 11 | # kBuild is free software; you can redistribute it and/or modify
|
|---|
| 12 | # it under the terms of the GNU General Public License as published by
|
|---|
| 13 | # the Free Software Foundation; either version 2 of the License, or
|
|---|
| 14 | # (at your option) any later version.
|
|---|
| 15 | #
|
|---|
| 16 | # kBuild is distributed in the hope that it will be useful,
|
|---|
| 17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 19 | # GNU General Public License for more details.
|
|---|
| 20 | #
|
|---|
| 21 | # You should have received a copy of the GNU General Public License
|
|---|
| 22 | # along with kBuild; if not, write to the Free Software
|
|---|
| 23 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|---|
| 24 | #
|
|---|
| 25 | #
|
|---|
| 26 |
|
|---|
| 27 | ## @todo I need to come up with a decent way of dealing with non-default targets.
|
|---|
| 28 | # The different SDL distros and install patterns isn't making this very easy exactly.
|
|---|
| 29 |
|
|---|
| 30 | SDK_LIBSDL := libsdl
|
|---|
| 31 | ifndef PATH_SDK_LIBSDL
|
|---|
| 32 | PATH_SDK_LIBSDL := $(sort $(wildcard $(PATH_DEV)/$(BUILD_TARGET_ARCH).$(BUILD_TARGET)/libsdl/v*))
|
|---|
| 33 | ifneq ($(PATH_SDK_LIBSDL),)
|
|---|
| 34 | PATH_SDK_LIBSDL := $(call lastword,$(PATH_SDK_LIBSDL))
|
|---|
| 35 | else
|
|---|
| 36 | $(warning kBuild: PATH_SDK_LIBSDL couldn't be determined!)
|
|---|
| 37 | PATH_SDK_LIBSDL := /usr
|
|---|
| 38 | endif
|
|---|
| 39 | endif
|
|---|
| 40 |
|
|---|
| 41 | ifeq ($(BUILD_TARGET),os2)
|
|---|
| 42 | SDK_LIBSDL_INCS := \
|
|---|
| 43 | $(PATH_SDK_LIBSDL)/SDL/include \
|
|---|
| 44 | $(PATH_SDK_LIBSDL)/SDLGfx \
|
|---|
| 45 | $(PATH_SDK_LIBSDL)/SDLImage \
|
|---|
| 46 | $(PATH_SDK_LIBSDL)/SDLMixer \
|
|---|
| 47 | $(PATH_SDK_LIBSDL)/SDLNet \
|
|---|
| 48 | $(PATH_SDK_LIBSDL)/SDLTTF
|
|---|
| 49 | SDK_LIBSDL_LIBS := \
|
|---|
| 50 | $(PATH_SDK_LIBSDL)/SDL/SDL12.lib \
|
|---|
| 51 | $(PATH_SDK_LIBSDL)/SDLGfx/SDLGFX.lib \
|
|---|
| 52 | $(PATH_SDK_LIBSDL)/SDLImage/SDLIMAGE.lib \
|
|---|
| 53 | $(PATH_SDK_LIBSDL)/SDLMixer/SDLMIXER.lib \
|
|---|
| 54 | $(PATH_SDK_LIBSDL)/SDLNet/SDLNET.lib \
|
|---|
| 55 | $(PATH_SDK_LIBSDL)/SDLTTF/SDLTTF.lib
|
|---|
| 56 | SDK_LIBSDL_LIBPATHS := \
|
|---|
| 57 | $(PATH_SDK_LIBSDL)/SDL \
|
|---|
| 58 | $(PATH_SDK_LIBSDL)/SDLGfx \
|
|---|
| 59 | $(PATH_SDK_LIBSDL)/SDLImage \
|
|---|
| 60 | $(PATH_SDK_LIBSDL)/SDLMixer \
|
|---|
| 61 | $(PATH_SDK_LIBSDL)/SDLNet \
|
|---|
| 62 | $(PATH_SDK_LIBSDL)/SDLTTF
|
|---|
| 63 | SDK_LIBSDL_LIBMAIN =
|
|---|
| 64 | else
|
|---|
| 65 | ifneq ($(filter nt win win32 win64,$(BUILD_TARGET)),)
|
|---|
| 66 | # only vc++, not mingw/cygwin.
|
|---|
| 67 | SDK_LIBSDL_INCS := \
|
|---|
| 68 | $(PATH_SDK_LIBSDL)/include/SDL \
|
|---|
| 69 | $(PATH_SDK_LIBSDL)/include
|
|---|
| 70 | SDK_LIBSDL_LIBS := \
|
|---|
| 71 | $(PATH_SDK_LIBSDL)/lib/SDL.lib
|
|---|
| 72 | SDK_LIBSDL_LIBPATHS := \
|
|---|
| 73 | $(PATH_SDK_LIBSDL)/lib
|
|---|
| 74 | SDK_LIBSDL_LIBMAIN = \
|
|---|
| 75 | $(PATH_SDK_LIBSDL)/lib/SDLmain.lib
|
|---|
| 76 | else
|
|---|
| 77 | SDK_LIBSDL_INCS := \
|
|---|
| 78 | $(PATH_SDK_LIBSDL)/include/SDL \
|
|---|
| 79 | $(PATH_SDK_LIBSDL)/include
|
|---|
| 80 | SDK_LIBSDL_LIBS := sdl sdlgfx sdlimage sdlmixer sdlnet sdlttf
|
|---|
| 81 | SDK_LIBSDL_LIBPATHS := \
|
|---|
| 82 | $(PATH_SDK_LIBSDL)/lib
|
|---|
| 83 | SDK_LIBSDL_LIBMAIN = sdlmain
|
|---|
| 84 | endif
|
|---|
| 85 | endif
|
|---|
| 86 |
|
|---|