base_tools & base_rules move to devkitA64

This commit is contained in:
Dave Murphy 2018-01-26 23:45:16 +00:00 committed by plutoo
parent 7ed122eefc
commit 1d03916aaa
4 changed files with 0 additions and 82 deletions

View File

@ -2,7 +2,6 @@ all:
$(MAKE) -C nx/ $(MAKE) -C nx/
install: install:
$(MAKE) -C buildscripts/ install
$(MAKE) -C nx/ install $(MAKE) -C nx/ install
clean: clean:

View File

@ -1,3 +0,0 @@
install:
cp base_rules base_tools switch_rules $(DEVKITPRO)/devkitA64
cp lib/switch.ld lib/switch.specs $(DEVKITPRO)/devkitA64/aarch64-none-elf/lib/

View File

@ -1,40 +0,0 @@
include $(DEVKITPRO)/devkitA64/base_tools
#---------------------------------------------------------------------------------
%.a:
#---------------------------------------------------------------------------------
@echo $(notdir $@)
@rm -f $@
$(AR) -rc $@ $^
#---------------------------------------------------------------------------------
%.o: %.cpp
@echo $(notdir $<)
$(CXX) -MMD -MP -MF $(DEPSDIR)/$*.d $(CXXFLAGS) -c $< -o $@ $(ERROR_FILTER)
#---------------------------------------------------------------------------------
%.o: %.c
@echo $(notdir $<)
$(CC) -MMD -MP -MF $(DEPSDIR)/$*.d $(CFLAGS) -c $< -o $@ $(ERROR_FILTER)
#---------------------------------------------------------------------------------
%.o: %.s
@echo $(notdir $<)
$(CC) -MMD -MP -MF $(DEPSDIR)/$*.d -x assembler-with-cpp $(ASFLAGS) -c $< -o $@ $(ERROR_FILTER)
#---------------------------------------------------------------------------------
%.o: %.S
@echo $(notdir $<)
$(CC) -MMD -MP -MF $(DEPSDIR)/$*.d -x assembler-with-cpp $(ASFLAGS) -c $< -o $@ $(ERROR_FILTER)
#---------------------------------------------------------------------------------
# canned command sequence for binary data
#---------------------------------------------------------------------------------
define bin2o
bin2s $< | $(AS) -o $(@)
echo "extern const u8" `(echo $(<F) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"_end[];" > `(echo $(<F) | tr . _)`.h
echo "extern const u8" `(echo $(<F) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"[];" >> `(echo $(<F) | tr . _)`.h
echo "extern const u32" `(echo $(<F) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`_size";" >> `(echo $(<F) | tr . _)`.h
endef

View File

@ -1,38 +0,0 @@
#---------------------------------------------------------------------------------
# make sure we have bash on OSX
#---------------------------------------------------------------------------------
UNAME_S := $(shell uname -s)
UNAME_R := $(shell uname -r)
ifneq (,$(findstring Darwin,$(UNAME_S)))
export SHELL=/bin/bash
endif
#---------------------------------------------------------------------------------
# path to tools
#---------------------------------------------------------------------------------
export PATH := $(DEVKITPRO)/devkitA64/bin:$(PATH)
#---------------------------------------------------------------------------------
# add portlibs path
#---------------------------------------------------------------------------------
export PORTLIBS_PATH := $(DEVKITPRO)/portlibs
#---------------------------------------------------------------------------------
# the prefix on the compiler executables
#---------------------------------------------------------------------------------
PREFIX := aarch64-none-elf-
export CC := $(PREFIX)gcc
export CXX := $(PREFIX)g++
export AS := $(PREFIX)as
export AR := $(PREFIX)gcc-ar
export OBJCOPY := $(PREFIX)objcopy
export STRIP := $(PREFIX)strip
export NM := $(PREFIX)gcc-nm
export RANLIB := $(PREFIX)gcc-ranlib
ISVC=$(or $(VCBUILDHELPER_COMMAND),$(MSBUILDEXTENSIONSPATH32),$(MSBUILDEXTENSIONSPATH))
ifneq (,$(ISVC))
ERROR_FILTER := 2>&1 | sed -e 's/\(.[a-zA-Z]\+\):\([0-9]\+\):/\1(\2):/g'
endif