Selaa lähdekoodia

Normalize the use of abspath in the teensy3/Makefile.

Some path-variables in the teens3/Makefile passes though abspath
every time before they get used. Do this only once, when they get
set. This makes things more readable and less error-prone.
teensy4-core
Pieter du Preez 9 vuotta sitten
vanhempi
commit
060b1a7d1d
1 muutettua tiedostoa jossa 9 lisäystä ja 9 poistoa
  1. +9
    -9
      teensy3/Makefile

+ 9
- 9
teensy3/Makefile Näytä tiedosto

#************************************************************************ #************************************************************************


# path location for Teensy Loader, teensy_post_compile and teensy_reboot # path location for Teensy Loader, teensy_post_compile and teensy_reboot
TOOLSPATH = $(ARDUINOPATH)/hardware/tools # on Linux
TOOLSPATH = $(abspath $(ARDUINOPATH)/hardware/tools) # on Linux


# path location for Arduino libraries (currently not used) # path location for Arduino libraries (currently not used)
LIBRARYPATH = $(ARDUINOPATH)/libraries
LIBRARYPATH = $(abspath $(ARDUINOPATH)/libraries)


# path location for the arm-none-eabi compiler # path location for the arm-none-eabi compiler
COMPILERPATH = $(ARDUINOPATH)/hardware/tools/arm/bin
COMPILERPATH = $(abspath $(ARDUINOPATH)/hardware/tools/arm/bin)


#************************************************************************ #************************************************************************
# Settings below this point usually do not need to be edited # Settings below this point usually do not need to be edited




# names for the compiler programs # names for the compiler programs
CC = $(abspath $(COMPILERPATH))/arm-none-eabi-gcc
CXX = $(abspath $(COMPILERPATH))/arm-none-eabi-g++
OBJCOPY = $(abspath $(COMPILERPATH))/arm-none-eabi-objcopy
SIZE = $(abspath $(COMPILERPATH))/arm-none-eabi-size
CC = $(COMPILERPATH)/arm-none-eabi-gcc
CXX = $(COMPILERPATH)/arm-none-eabi-g++
OBJCOPY = $(COMPILERPATH)/arm-none-eabi-objcopy
SIZE = $(COMPILERPATH)/arm-none-eabi-size


# automatically create lists of the sources and objects # automatically create lists of the sources and objects
# TODO: this does not handle Arduino libraries yet... # TODO: this does not handle Arduino libraries yet...
%.hex: %.elf %.hex: %.elf
$(SIZE) $< $(SIZE) $<
$(OBJCOPY) -O ihex -R .eeprom $< $@ $(OBJCOPY) -O ihex -R .eeprom $< $@
$(abspath $(TOOLSPATH))/teensy_post_compile -file=$(basename $@) -path=$(shell pwd) -tools=$(abspath $(TOOLSPATH))
-$(abspath $(TOOLSPATH))/teensy_reboot
$(TOOLSPATH)/teensy_post_compile -file=$(basename $@) -path=$(shell pwd) -tools=$(TOOLSPATH)
-$(TOOLSPATH)/teensy_reboot




# compiler generated dependency info # compiler generated dependency info

Loading…
Peruuta
Tallenna