TwlToolsRED/build/tools/sctools/copy_dst/Makefile

177 lines
6.7 KiB
Makefile
Raw Blame History

#! make -f
#----------------------------------------------------------------------------
# Project: TwlSDK - demos - MI - ndma-1
# File: Makefile
#
# Copyright 2007 Nintendo. All rights reserved.
#
# These coded instructions, statements, and computer programs contain
# proprietary information of Nintendo of America Inc. and/or Nintendo
# Company Ltd., and are protected by Federal copyright law. They may
# not be disclosed to third parties or copied or duplicated in any form,
# in whole or in part, without the prior written consent of Nintendo.
#
# $Date:: 2008-01-17#$
# $Rev: 3650 $
# $Author: okubata_ryoma $
#----------------------------------------------------------------------------
SUBDIRS = ./banner ../files/tads ../files/taddevs
TARGET_PLATFORM := TWL
TWL_ARCHGEN := LIMITED
SRCDIR = ../common/src ./src
SRCS = main.c mfiler.c key.c font.c text.c mprintf.c logprintf.c \
gfx.c hwi.c mynvram.c my_fs_util.c \
hatamotolib.cpp miya_mcu.c error_report.c \
sitedefs.c wcm_control.c netconnect.c mywlan.c \
mynuc.c nuc_error_msg.c stream.c myfilename.c menu_version.c \
ntp.c myimport.c pre_install.c \
my_rsa_sign.c my_aes.c my_sha.c my_sign.c my_keys.c
TARGET_BIN = copy_dst.srl
ROM_SPEC = copy_dst.rsf
TARGET_AUTOBOOT = ./bin/$(TWL_BUILDTYPE)/copy_dst_autoboot.srl
ES_DIR = $(ROOT)/add-ins/es
ES_LATEST = $(shell ls -d $(ES_DIR)/es-sdk-*|sort|tail -n 1)
ES_ROOT = $(ES_LATEST)
BSAFE_DIR = $(TWLSDK_ROOT)/build/libraries/crypto/common/mes
LINCLUDES = $(TWLSDK_ROOT)/build/libraries/lcfg/ARM9.TWL/include ../common/src \
$(TWLSDK_ROOT)/build/libraries/nam/ARM9.TWL/include \
$(TWLSDK_ROOT)/build/libraries/ese/common/include \
$(BSAFE_DIR)/src $(BSAFE_DIR)/include/r_com \
$(BSAFE_DIR)/include $(BSAFE_DIR)/bn \
$(BSAFE_DIR)/bio $(BSAFE_DIR)/pubkey/pk \
$(BSAFE_DIR)/pubkey/rsa $(BSAFE_DIR)/pubkey/pk_op \
$(BSAFE_DIR)/pubkey/pk_data $(BSAFE_DIR)/ber \
$(BSAFE_DIR)/berobj $(BSAFE_DIR)/buffer \
$(BSAFE_DIR)/data/eitems $(BSAFE_DIR)/data/flag \
$(BSAFE_DIR)/data/lhash $(BSAFE_DIR)/data/op \
$(BSAFE_DIR)/data/reslist $(BSAFE_DIR)/data/stack \
$(BSAFE_DIR)/data/strtbl $(BSAFE_DIR)/err \
$(BSAFE_DIR)/evp $(BSAFE_DIR)/library \
$(BSAFE_DIR)/objects $(BSAFE_DIR)/os/cpuid \
$(BSAFE_DIR)/os/lock $(BSAFE_DIR)/os/memory \
$(BSAFE_DIR)/os/perf $(BSAFE_DIR)/os/rand \
$(BSAFE_DIR)/os/surr $(BSAFE_DIR)/digest/sha \
$(BSAFE_DIR)/random $(BSAFE_DIR)/cipher/aes \
$(BSAFE_DIR)/module/crypto $(BSAFE_DIR)/module/crypto/nat_meth \
$(BSAFE_DIR)/key \
$(ES_ROOT)/twl/include $(ES_ROOT)/common/lib/ec/include
LLIBRARY_DIRS += $(ES_ROOT)/twl/lib/$(TWL_BUILDTYPE) ../wifilib/$(TWL_BUILDTYPE)
# LLIBRARY_DIRS += $(ES_ROOT)/twl/lib/$(TWL_BUILDTYPE)
LLIBRARIES += libecx$(TWL_LIBSUFFIX).a \
liblcfg$(TWL_LIBSUFFIX).a \
libnhttp.nssl$(TWL_LIBSUFFIX).a \
libshr$(TWL_LIBSUFFIX).a \
libnuc$(TWL_LIBSUFFIX).a \
libnup$(TWL_LIBSUFFIX).a \
libnam$(TWL_LIBSUFFIX).a \
libes$(TWL_LIBSUFFIX).a \
libsea$(TWL_LIBSUFFIX).a \
libboc$(TWL_LIBSUFFIX).a \
libsfs$(TWL_LIBSUFFIX).a \
libna$(TWL_LIBSUFFIX).a \
MACRO_FLAGS += \
-DOPT_32_BIT \
-DRCOM_LEAN \
-DR_LIBRARY_BUILD \
-DFLAT_INC \
-DNO_SOCK \
-DNO_SPLIT \
-DNO_FP_API \
-DNO_R_DIAG \
-DNO_STDIO_H \
-DNO_STDLIB_H \
-DNO_PK_TO_OP_FUNCS \
-DNO_PKCS8 \
-DNO_CRYPTO \
-DNO_CERT \
-DNO_HDW \
-DNO_TIME_H \
-DNO_SHA224 \
-DNO_SHA256 \
-DNO_SHA384 \
-DNO_SHA512 \
-DNO_FP_API \
-DNO_BIO \
# -DBN_LIBRARY_SMALL \
# -DNO_RSA -DNO_SHA1 \
# -DNO_R_LOCK \
MACRO_FLAGS += -DSMALL_CODE_SIZE
MACRO_FLAGS += -DOPT_BN_ASM
MACRO_FLAGS += -DOPT_SHA1_ASM -DOPT_SHA1_ARM
MAKEROM_ROMROOT = ../files
TAD_TABLE_TXT = ../files/tads/tad_table.txt
TADDEV_TABLE_TXT = ../files/taddevs/taddev_table.txt
-include MakefileTad.inc
-include MakefileTadDev.inc
MAKEROM_ROMFILES = fanfare.32.wav ok.wav ng.wav cursor.wav \
tads/tad_table.txt taddevs/taddev_table.txt $(MAKEROM_TAD_ROMFILES) $(MAKEROM_TADDEV_ROMFILES)
MY_TWL_COMPONENTSDIR = ../my_armadillo.TWL/bin
COMPONENT_NAME = armadillo
# MAKEROM_ARM7_BASE = $(MY_TWL_COMPONENTSDIR)/$(COMPONENT_NAME)/$(TWL_BUILDTYPE_ARM7)/$(COMPONENT_NAME)
MAKEROM_ARM7_BASE = $(MY_TWL_COMPONENTSDIR)/$(TWL_BUILDTYPE_ARM7)/$(COMPONENT_NAME)
MAKEROM_ARM7 = $(MAKEROM_ARM7_BASE).$(TWL_ELF_EXT)
LDIRT_CLEAN =
include $(TWLWIFI_ROOT)/build/buildtools/commondefs
include $(TWLSDK_ROOT)/build/buildtools/commondefs
#----------------------------------
# <20>Z<EFBFBD>L<EFBFBD><4C><EFBFBD>A<EFBFBD>A<EFBFBD>v<EFBFBD><76><EFBFBD>w<EFBFBD><77>
MAKEROM := $(TWL_TOOLSDIR)/bin/makerom.TWL.secure.exe
#----------------------------------------------------------------------------
#----------------------------------------------------------------------------
$(TARGET_AUTOBOOT): ./bin/$(TWL_BUILDTYPE)/$(TARGET_BIN)
../bin/FakeRomHeader.secure.exe -c -f $< $@
do-build: $(TARGETS) $(TARGET_AUTOBOOT)
$(BINDIR)/$(TARGET_BIN_BASENAME).$(TWL_ELF_EXT): MakefileTad.inc MakefileTadDev.inc $(TAD_TABLE_TXT) $(TADDEV_TABLE_TXT)
#----------------------------------------------------------------------------
include $(TWLWIFI_ROOT)/build/buildtools/modulerules
include $(TWLSDK_ROOT)/build/buildtools/modulerules