!if 0
Copyright (c) Microsoft Corporation.  All rights reserved.
!endif
!if 0
Use of this source code is subject to the terms of the Microsoft end-user
license agreement (EULA) under which you licensed this SOFTWARE PRODUCT.
If you did not accept the terms of the EULA, you are not authorized to use
this source code. For a copy of the EULA, please see the LICENSE.RTF on your
install media.
!endif

TARGETNAME=bldr
TARGETTYPE=PROGRAM
EXEENTRY=StartUp
SYNCHRONIZE_DRAIN=1

ASM_SAFESEH=1

LINKER_SUBSYSTEM=-subsystem:native
LDEFINES=$(LDEFINES) $(LINKER_SUBSYSTEM) /FIXED:NO

TARGETLIBS=\
	$(_TARGETPLATROOT)\lib\$(_CPUDEPPATH)\iniparse.lib \
	$(_WINCEROOT)\public\common\oak\lib\$(_CPUDEPPATH)\cecompress.lib \
	$(_COMMONOAKROOT)\lib\$(_CPUINDPATH)\gsnull.lib \
        $(_COMMONOAKROOT)\lib\$(_CPUINDPATH)\fulllibc.lib

#
# Debug output options:
#
# Use -DSHIP_BUILD for no debug messages (smallest BLDR binary)
# Use -DDEBUG for debug output using error/warning codes
# Use -DDEBUG -DFULLMESSAGES for full debug string
# Use -DDEBUG -DFULLMESSAGES -DFULLINT13MESSAGES for full disk-errror messages (biggest BLDR binary)
#
DEBUG_OPTIONS=-DDEBUG

#
# Compression method options (one and only one option can be specified):
# 
# Use -DNO_COMPRESSION for disabling compression support (smallest BLDR binary)
# Use -DCECOMPRESSION for compression support (bigger BLDR)
#
COMPRESSION_OPTIONS=-DCECOMPRESSION 

CDEFINES=$(CDEFINES) -DCEDDK_USEDDKMACRO $(DEBUG_OPTIONS) $(COMPRESSION_OPTIONS)

INCLUDES=$(_WINCEROOT)\platform\common\src\soc\x86_ms_v1\inc; \
         $(_COMMONOAKROOT)\lib; \
         ..\iniparser; \
         ..\utilities\bincompress

SOURCES= startup.asm \
         bios.asm    \
         debug.c     \
         main.c      \
	 fat.c       \
         format.c    \
         drive.c     \
         ini.c \
         video.c \
         splash.c \
         decoder.c

!IF "$(LINKONLY)"=="1"         
WINCETARGETFILES=MakeImage
!ENDIF