1#! make -f
2#----------------------------------------------------------------------------
3# Project:  TwlSDK - GX - demos - UnitTours/2D_BmpBg_MainRam
4# File:     Makefile
5#
6# Copyright 2003-2008 Nintendo.  All rights reserved.
7#
8# These coded instructions, statements, and computer programs contain
9# proprietary information of Nintendo of America Inc. and/or Nintendo
10# Company Ltd., and are protected by Federal copyright law.  They may
11# not be disclosed to third parties or copied or duplicated in any form,
12# in whole or in part, without the prior written consent of Nintendo.
13#
14# $Date:: 2008-09-18#$
15# $Rev: 8573 $
16# $Author: okubata_ryoma $
17#----------------------------------------------------------------------------
18TARGET_PLATFORM	= TWL NITRO
19
20SUBDIRS			=
21
22#----------------------------------------------------------------------------
23
24SRCS			=	main.c \
25					image.c
26
27PICTURES_DIR	=	../2D_BmpBg_MainRam/pictures
28PICTURES		=	picture_256_192_a.ppm \
29					picture_256_192_b.ppm \
30					picture_256_192_c.ppm \
31					picture_256_192_d.ppm
32
33PCITURES_C_DIR	=	pictures
34PICTURES_C		=	$(addprefix $(PCITURES_C_DIR)/,$(PICTURES:.ppm=.autogen.c))
35
36TARGET_BIN		=	main.srl
37LINCLUDES		=	$(PCITURES_C_DIR)
38
39LDIRT_CLEAN		=	$(PICTURES_C)
40
41#SRCDIR			=	# using default
42#LCFILE			=	# using default
43
44include	$(TWLSDK_ROOT)/build/buildtools/commondefs
45include	$(TWLSDK_ROOT)/build/buildtools/commondefs.gx.demolib
46
47#----------------------------------------------------------------------------
48
49PPMCONV			=	$(TOOLSDIR)/bin/ppmconv.exe
50
51#----------------------------------------------------------------------------
52
53do-build:		$(TARGETS)
54
55include	$(TWLSDK_ROOT)/build/buildtools/modulerules
56
57$(PCITURES_C_DIR)/%.autogen.c:	$(PICTURES_DIR)/%.ppm
58	install -d $(@D)
59	$(PPMCONV) $< > $@
60
61$(OBJDIR)/image.o: image.c $(PICTURES_C)
62
63#===== End of Makefile =====
64