Skip to content

Commit

Permalink
newlib.mk: indent comments in conditionnal
Browse files Browse the repository at this point in the history
Comments inside an if are usually also indented.

(cherry picked from commit 3226918)
  • Loading branch information
cladmi committed Aug 2, 2018
1 parent a953cdb commit 43a5a64
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions makefiles/libc/newlib.mk
Original file line number Diff line number Diff line change
Expand Up @@ -39,30 +39,30 @@ ifeq (,$(NEWLIB_INCLUDE_DIR))
endif

ifeq (,$(NEWLIB_INCLUDE_DIR))
# Since Clang is not installed as a separate instance for each crossdev target
# we need to tell it where to look for platform specific includes (Newlib
# headers instead of Linux/Glibc headers.)
# On GCC this is done when building the cross compiler toolchain so we do not
# actually need to specify the include paths for system includes.
# Ubuntu gcc-arm-embedded toolchain (https://launchpad.net/gcc-arm-embedded)
# places newlib headers in several places, but the primary source seem to be
# /etc/alternatives/gcc-arm-none-eabi-include
# Gentoo Linux crossdev place the newlib headers in /usr/arm-none-eabi/include
# Arch Linux also place the newlib headers in /usr/arm-none-eabi/include
# Ubuntu seem to put a copy of the newlib headers in the same place as
# Gentoo crossdev, but we prefer to look at /etc/alternatives first.
# On OSX, newlib includes are possibly located in
# /usr/local/opt/arm-none-eabi*/arm-none-eabi/include or /usr/local/opt/gcc-arm/arm-none-eabi/include
# Since Clang is not installed as a separate instance for each crossdev target
# we need to tell it where to look for platform specific includes (Newlib
# headers instead of Linux/Glibc headers.)
# On GCC this is done when building the cross compiler toolchain so we do not
# actually need to specify the include paths for system includes.
# Ubuntu gcc-arm-embedded toolchain (https://launchpad.net/gcc-arm-embedded)
# places newlib headers in several places, but the primary source seem to be
# /etc/alternatives/gcc-arm-none-eabi-include
# Gentoo Linux crossdev place the newlib headers in /usr/arm-none-eabi/include
# Arch Linux also place the newlib headers in /usr/arm-none-eabi/include
# Ubuntu seem to put a copy of the newlib headers in the same place as
# Gentoo crossdev, but we prefer to look at /etc/alternatives first.
# On OSX, newlib includes are possibly located in
# /usr/local/opt/arm-none-eabi*/arm-none-eabi/include or /usr/local/opt/gcc-arm/arm-none-eabi/include
NEWLIB_INCLUDE_PATTERNS ?= \
/etc/alternatives/gcc-$(TARGET_ARCH)-include \
/usr/$(TARGET_ARCH)/include \
/usr/local/opt/$(TARGET_ARCH)*/$(TARGET_ARCH)/include \
/usr/local/opt/gcc-*/$(TARGET_ARCH)/include \
#
# Use the wildcard Makefile function to search for existing directories matching
# the patterns above. We use the -isystem gcc/clang argument to add the include
# directories as system include directories, which means they will not be
# searched until after all the project specific include directories (-I/path)
# Use the wildcard Makefile function to search for existing directories matching
# the patterns above. We use the -isystem gcc/clang argument to add the include
# directories as system include directories, which means they will not be
# searched until after all the project specific include directories (-I/path)
NEWLIB_INCLUDE_DIR := $(firstword $(realpath $(dir $(wildcard $(addsuffix /newlib.h, $(NEWLIB_INCLUDE_PATTERNS))))))
endif

Expand Down

0 comments on commit 43a5a64

Please sign in to comment.