Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make: Use ld -r for intermediate linking of each module #8711

Closed
wants to merge 18 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions Makefile.base
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@ MODULE ?= $(shell basename $(CURDIR))

.PHONY: all clean $(DIRS:%=ALL--%) $(DIRS:%=CLEAN--%)

# Build a static library if the current module is listed in LIBS
ifneq (,$(filter $(MODULE),$(LIBS)))
all: $(BINDIR)/$(MODULE).a ..nothing
else
# .. otherwise, build a monolithic object file
all: $(BINDIR)/$(MODULE).o ..nothing
endif

..nothing:
@:
Expand Down Expand Up @@ -65,6 +71,18 @@ DEP := $(OBJC:.o=.d) $(OBJCXX:.o=.d) $(ASSMOBJ:.o=.d)
$(BINDIR)/$(MODULE)/:
$(Q)mkdir -p $@

$(BINDIR)/$(MODULE).o $(OBJ): | $(BINDIR)/$(MODULE)/

# An empty object file is included in the link to avoid situations where modules
# do not provide any code (e.g. sys, some boards), causing the build to fail
# with a missing object file.
EMPTYOBJ = $(BINDIR)/$(MODULE)/.empty.o
Copy link
Contributor

@Kijewski Kijewski Mar 1, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure that using a generic empty.o will work. If I'm not mistaken (I did not test it), the linker will reject an object file if it's not the right architecture.

I guess something like that would be more robust:

ifeq $(,$(OBJ))
  OBJ := $(BINDIR)/$(MODULE)/empty.o

  $(BINDIR)/$(MODULE)/empty.o: $(RIOTBASE)/empty.c
        $(CC) $(CFLAGS) -w -c -o $@ $<
ifeq
static void __attribute__((unused)) _placeholder(void) {}

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works, try it. It is the correct architecture because of using the real CFLAGS when generating it.
Not sure the ifeq suggestion is robust because of lazy evaluation of recursive variables, does OBJ always have its final value when interpreting this makefile?

$(EMPTYOBJ): | $(BINDIR)/$(MODULE)/
$(Q)$(CC) $(CFLAGS) -Wno-pedantic -xc -o $@ -c - < /dev/null

$(BINDIR)/$(MODULE).o: $(OBJ) $(EMPTYOBJ) | ${DIRS:%=ALL--%}
$(Q)$(ILINK) $(ILINKFLAGS) -o $@ $^

$(BINDIR)/$(MODULE).a $(OBJ): | $(BINDIR)/$(MODULE)/

$(BINDIR)/$(MODULE).a: $(OBJ) | $(DIRS:%=ALL--%)
Expand Down
13 changes: 12 additions & 1 deletion Makefile.dep
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,14 @@ endif

ifneq (,$(filter stdio_uart,$(USEMODULE)))
USEMODULE += isrpipe
FEATURES_REQUIRED += periph_uart
ifneq (,$(filter newlib_syscalls_mips_uhi,$(USEMODULE)))
# The periph_uart driver is optional when using MIPS UHI syscalls (debug
# UART is used on PIC32 boards, but not on mips-malta)
FEATURES_OPTIONAL += periph_uart
else
# All other UART implementations require the periph_uart driver.
FEATURES_REQUIRED += periph_uart
endif
endif

ifneq (,$(filter isrpipe,$(USEMODULE)))
Expand Down Expand Up @@ -562,6 +569,10 @@ ifneq (,$(filter pthread,$(USEMODULE)))
USEMODULE += timex
endif

ifneq (,$(filter pthread_tls,$(USEMODULE)))
USEMODULE += pthread
endif

ifneq (,$(filter schedstatistics,$(USEMODULE)))
USEMODULE += xtimer
endif
Expand Down
16 changes: 8 additions & 8 deletions Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ endif
APPLICATION_MODULE ?= application_$(APPLICATION)

# the binaries to link
BASELIBS += $(BINDIR)/$(APPLICATION_MODULE).a
BASELIBS += $(BINDIR)/$(APPLICATION_MODULE).o
BASELIBS += $(APPDEPS)


Expand Down Expand Up @@ -437,9 +437,9 @@ _BASELIBS_VALUE_BEFORE_USAGE := $(BASELIBS)
# Linker rule
$(ELFFILE): FORCE
ifeq ($(BUILDOSXNATIVE),1)
_LINK = $(if $(CPPMIX),$(LINKXX),$(LINK)) $(UNDEF) $$(find $(BASELIBS) -size +8c) $(LINKFLAGS) $(LINKFLAGPREFIX)-no_pie
_LINK = $(if $(CPPMIX),$(LINKXX),$(LINK)) $$(find $(BASELIBS) -size +8c) $(LINKFLAGS) $(LINKFLAGPREFIX)-no_pie
else
_LINK = $(if $(CPPMIX),$(LINKXX),$(LINK)) $(UNDEF) $(LINKFLAGPREFIX)--start-group $(BASELIBS) -lm $(LINKFLAGPREFIX)--end-group $(LINKFLAGS) $(LINKFLAGPREFIX)-Map=$(BINDIR)/$(APPLICATION).map
_LINK = $(if $(CPPMIX),$(LINKXX),$(LINK)) $(LINKFLAGPREFIX)--start-group $(BASELIBS) -lm $(LINKFLAGPREFIX)--end-group $(LINKFLAGS) $(LINKFLAGPREFIX)-Map=$(BINDIR)/$(APPLICATION).map
endif # BUILDOSXNATIVE

# include bootloaders support. When trying to overwrite one variable
Expand All @@ -459,13 +459,13 @@ endif # RIOTNOLINK
$(ELFFILE): $(BASELIBS)
$(Q)$(_LINK) -o $@

$(BINDIR)/$(APPLICATION_MODULE).a: pkg-build $(BUILDDEPS)
$(BINDIR)/$(APPLICATION_MODULE).o: pkg-build $(BUILDDEPS)
$(Q)DIRS="$(DIRS)" "$(MAKE)" -C $(APPDIR) -f $(RIOTMAKE)/application.inc.mk
$(BINDIR)/$(APPLICATION_MODULE).a: FORCE
$(BINDIR)/$(APPLICATION_MODULE).o: FORCE

# Other modules are built by application.inc.mk and packages building
_SUBMAKE_LIBS = $(filter-out $(BINDIR)/$(APPLICATION_MODULE).a $(APPDEPS), $(BASELIBS))
$(_SUBMAKE_LIBS): $(BINDIR)/$(APPLICATION_MODULE).a pkg-build
_SUBMAKE_LIBS = $(filter-out $(BINDIR)/$(APPLICATION_MODULE).o $(APPDEPS), $(BASELIBS))
$(_SUBMAKE_LIBS): $(BINDIR)/$(APPLICATION_MODULE).o pkg-build

# 'print-size' triggers a rebuild. Use 'info-buildsize' if you do not need to rebuild.
print-size: $(ELFFILE)
Expand Down Expand Up @@ -516,7 +516,7 @@ clean:
# Remove intermediates, but keep the .elf, .hex and .map etc.
clean-intermediates:
-@for i in $(USEPKG) ; do "$(MAKE)" -C $(RIOTPKG)/$$i distclean ; done
-@rm -rf $(BINDIR)/*.a $(BINDIR)/*/
-@rm -rf $(BINDIR)/*.o $(BINDIR)/*.a $(BINDIR)/*/

clean-pkg:
-@for i in $(USEPKG) ; do "$(MAKE)" -C $(RIOTPKG)/$$i distclean ; done
Expand Down
2 changes: 0 additions & 2 deletions boards/common/msba2/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,3 @@ USEMODULE += newlib_nano
FFLAGS = $(PORT) $(HEXFILE)

INCLUDES += -I$(RIOTBOARD)/common/msba2/include

export UNDEF += $(BINDIR)/cpu/startup.o
3 changes: 1 addition & 2 deletions boards/native/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ export CXXEXFLAGS +=

ifeq ($(shell uname -m),x86_64)
export LINKFLAGS += -m32
export ILINKFLAGS += -r -m elf_i386 --unique
endif
ifeq ($(shell uname -s),FreeBSD)
ifeq ($(shell uname -m),amd64)
Expand Down Expand Up @@ -187,5 +188,3 @@ eval-gprof:

eval-cachegrind:
$(CGANNOTATE) $(shell ls -rt cachegrind.out* | tail -1)

export UNDEF += $(BINDIR)/cpu/startup.o
3 changes: 3 additions & 0 deletions cpu/atmega1281/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# tell the build system that the CPU depends on the atmega common files
USEMODULE += atmega_common

# CPU family, see https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html
export CPU_FAM = avr51

RAM_LEN = 8K
ROM_LEN = 128K

Expand Down
3 changes: 3 additions & 0 deletions cpu/atmega1284p/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# tell the build system that the CPU depends on the atmega common files
USEMODULE += atmega_common

# CPU family, see https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html
export CPU_FAM = avr51

RAM_LEN = 16K
ROM_LEN = 128K

Expand Down
3 changes: 3 additions & 0 deletions cpu/atmega2560/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# tell the build system that the CPU depends on the atmega common files
USEMODULE += atmega_common

# CPU family, see https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html
export CPU_FAM = avr6

RAM_LEN = 8K
ROM_LEN = 256K

Expand Down
3 changes: 3 additions & 0 deletions cpu/atmega256rfr2/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# tell the build system that the CPU depends on the atmega common files
USEMODULE += atmega_common

# CPU family, see https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html
export CPU_FAM = avr6

#include periph module
USEMODULE += periph

Expand Down
3 changes: 3 additions & 0 deletions cpu/atmega328p/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# tell the build system that the CPU depends on the atmega common files
USEMODULE += atmega_common

# CPU family, see https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html
export CPU_FAM = avr5

RAM_LEN = 2K
ROM_LEN = 32K

Expand Down
3 changes: 0 additions & 3 deletions cpu/efm32/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@ endif
# include CPU family module
USEMODULE += cpu_$(EFM32_FAMILY)

# vectors.o is provided by 'cpu_$(EFM32_FAMILY)' and not by 'cpu'
VECTORS_O := $(BINDIR)/cpu_$(EFM32_FAMILY)/vectors.o

# include common periph module
USEMODULE += periph_common

Expand Down
3 changes: 0 additions & 3 deletions cpu/kinetis/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,6 @@ LINKFLAGS += $(LINKFLAGPREFIX)--defsym=_ram_start_addr=$(RAM_START_ADDR)
LINKFLAGS += $(LINKFLAGPREFIX)--defsym=_rom_length=$(ROM_LEN)
LINKFLAGS += $(LINKFLAGPREFIX)--defsym=_ram_length=$(RAM_LEN)

# add the CPU specific flash configuration field for the linker
export UNDEF += $(BINDIR)/cpu/fcfield.o

# include common periph drivers
USEMODULE += periph_common

Expand Down
3 changes: 3 additions & 0 deletions cpu/mips32r2_common/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ export USEMODULE += newlib
# mips32 needs periph_timer for its gettimeofday() implementation
export USEMODULE += periph_timer

# Need to tell the linker about the CPU endianness
export ILINKFLAGS += -r -EL --unique

ifeq ($(USE_UHI_SYSCALLS),1)
#Use UHI to handle syscalls
export LINKFLAGS += -luhi
Expand Down
4 changes: 4 additions & 0 deletions cpu/mips32r2_common/newlib_syscalls_mips_uhi/syscalls.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ extern char _sheap; /* start of the heap */
extern char _eheap; /* end of the heap */
char *heap_top = &_sheap + 4;

/* MIPS newlib crt implements _init,_fini and _exit and manages the heap */
#ifndef __mips__
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cladmi do you mean that this should be forked off?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If possible yes, also with the related changes in Makefile.dep.

I think it would would help comparing the size change between master and this one as it is my main way of debugging currently.

/**
* @brief Free resources on NewLib de-initialization, not used for RIOT
*/
Expand Down Expand Up @@ -98,6 +100,8 @@ void *_sbrk_r(struct _reent *r, ptrdiff_t incr)
return res;
}

#endif /*__mips__*/

/**
* @brief Get the process-ID of the current thread
*
Expand Down
1 change: 0 additions & 1 deletion cpu/msp430_common/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ INCLUDES += -I$(RIOTCPU)/msp430_common/include/
MODEL = $(shell echo $(CPU_MODEL) | tr 'a-z' 'A-Z')
export CFLAGS += -DCPU_MODEL_$(MODEL)

export UNDEF += $(BINDIR)/msp430_common/startup.o
export USEMODULE += msp430_common msp430_common_periph periph_common

DEFAULT_MODULE += oneway_malloc
Expand Down
7 changes: 3 additions & 4 deletions makefiles/arch/atmega.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ CFLAGS_OPT ?= -Os

CFLAGS += $(CFLAGS_CPU) $(CFLAGS_LINK) $(CFLAGS_DBG) $(CFLAGS_OPT)
ASFLAGS += $(CFLAGS_CPU) $(CFLAGS_DBG)
# See https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html for information on
# which CPU_FAM corresponds to your CPU
ILINKFLAGS += -r -m $(CPU_FAM) --unique
LINKFLAGS += $(CFLAGS_CPU) $(CFLAGS_DBG) $(CFLAGS_OPT) -static -lgcc -e reset_handler -Wl,--gc-sections
OFLAGS += -j .text -j .data

Expand All @@ -27,10 +30,6 @@ endif
# the atmel port uses stdio_uart
USEMODULE += stdio_uart

# explicitly tell the linker to link the syscalls and startup code.
# without this the interrupt vectors will not be linked correctly!
UNDEF += $(BINDIR)/atmega_common/startup.o

# Use ROM_LEN and RAM_LEN during link
$(if $(ROM_LEN),,$(error ROM_LEN is not defined))
$(if $(RAM_LEN),,$(error RAM_LEN is not defined))
Expand Down
7 changes: 0 additions & 7 deletions makefiles/arch/cortexm.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,6 @@ export CFLAGS += -DARM_MATH_CM23
endif
endif

# Explicitly tell the linker to link the startup code.
# Without this the interrupt vectors will not be linked correctly!
VECTORS_O ?= $(BINDIR)/cpu/vectors.o
ifeq ($(COMMON_STARTUP),)
export UNDEF += $(VECTORS_O)
endif

# CPU depends on the cortex-m common module, so include it:
include $(RIOTCPU)/cortexm_common/Makefile.include

Expand Down
2 changes: 2 additions & 0 deletions makefiles/arch/riscv.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,5 @@ export CFLAGS += $(CFLAGS_CPU) $(CFLAGS_DBG) $(CFLAGS_OPT) $(CFLAGS_LINK)
export ASFLAGS += $(CFLAGS_CPU) $(CFLAGS_DBG)
# export linker flags
export LINKFLAGS += $(CFLAGS_CPU) $(CFLAGS_LINK) $(CFLAGS_DBG) $(CFLAGS_OPT) -Wl,--gc-sections -static -lgcc
# ld defaults to elf64-littleriscv, tell it to use elf32 in incremental links
ILINKFLAGS += -m elf32lriscv -r --unique
2 changes: 1 addition & 1 deletion makefiles/bindist.inc.mk
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Avoid including APPLICATION_MODULE twice to prevent multiple definition errors
USEMODULE += $(filter-out $(APPLICATION_MODULE),$(BIN_USEMODULE))

DIST_FILES += $(BIN_USEMODULE:%=bin/$(BOARD)/%.a)
DIST_FILES += $(BIN_USEMODULE:%=bin/$(BOARD)/%.o)

# if the file Makefile.distcheck exists, we're executing from within a folder
# generated by "make bindist".
Expand Down
1 change: 0 additions & 1 deletion makefiles/docker.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ export DOCKER_ENV_VARS = \
SCANBUILD_OUTPUTDIR \
SIZE \
TOOLCHAIN \
UNDEF \
#

# Find which variables were set using the command line or the environment and
Expand Down
16 changes: 13 additions & 3 deletions makefiles/modules.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,19 @@ ED = $(addprefix MODULE_,$(sort $(USEMODULE) $(USEPKG)))
EXTDEFINES = $(addprefix -D,$(shell echo '$(ED)' | tr 'a-z-' 'A-Z_'))

# filter "pseudomodules" from "real modules", but not "no_pseudomodules"
NO_PSEUDOMODULES := $(filter $(NO_PSEUDOMODULES), $(sort $(USEMODULE) $(USEPKG)))
REALMODULES = $(filter-out $(PSEUDOMODULES), $(sort $(USEMODULE) $(USEPKG))) $(NO_PSEUDOMODULES)
export BASELIBS += $(REALMODULES:%=$(BINDIR)/%.a)
# any module listed in LIBS will be used as a .a file instead of .o
REALMODULES = $(filter-out $(LIBS), \
$(filter-out $(PSEUDOMODULES), $(USEMODULE)) \
$(filter $(NO_PSEUDOMODULES), $(USEMODULE)))
REALPKGS = $(filter-out $(LIBS), \
$(filter-out $(PSEUDOMODULES), $(USEPKG)) \
$(filter $(NO_PSEUDOMODULES), $(USEPKG)))
REALARCHIVES = $(filter $(LIBS),$(USEMODULE) $(USEPKG))
# filter out any duplicate object file names
BASELIBS += \
$(shell printf %s '$(REALMODULES:%=$(BINDIR)/%.o) $(REALPKGS:%=$(BINDIR)/%.o)' | \
tr ' ' '\n' | awk '!a[$$0]++')
BASELIBS += $(REALARCHIVES:%=$(BINDIR)/%.a)

CFLAGS += $(EXTDEFINES)

Expand Down
1 change: 1 addition & 0 deletions makefiles/pseudomodules.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ PSEUDOMODULES += pktqueue
PSEUDOMODULES += printf_float
PSEUDOMODULES += prng
PSEUDOMODULES += prng_%
PSEUDOMODULES += pthread_tls
PSEUDOMODULES += riotboot_%
PSEUDOMODULES += saul_adc
PSEUDOMODULES += saul_default
Expand Down
1 change: 0 additions & 1 deletion makefiles/scan-build.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ SCANBUILD_ENV_VARS := \
RIOT_CI_BUILD \
SIZE \
TOOLCHAIN \
UNDEF \
USER \
#

Expand Down
3 changes: 3 additions & 0 deletions makefiles/toolchain/gnu.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ export RANLIB = $(PREFIX)ranlib
endif
export AS = $(PREFIX)as
export NM = $(PREFIX)nm
export LD = $(PREFIX)ld
export ILINK = $(LD)
export ILINKFLAGS ?= -r --unique
export LINK = $(PREFIX)gcc
export LINKXX = $(PREFIX)g++
export SIZE = $(PREFIX)size
Expand Down
3 changes: 3 additions & 0 deletions makefiles/toolchain/llvm.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ export NM = $(LLVMPREFIX)nm
# compatible with GCC. For instance spec files as used in
# `makefiles/libc/newlib.mk` are not supported. Therefore
# we just use GCC for now.
export LD = $(PREFIX)ld
export ILINK = $(LD)
export ILINKFLAGS ?= -r --unique
export LINK = $(PREFIX)gcc
export LINKXX = $(PREFIX)g++
# objcopy does not have a clear substitute in LLVM, use GNU binutils
Expand Down
4 changes: 3 additions & 1 deletion makefiles/vars.inc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export CXXINCLUDES # The extra include paths for c++, set by the vario

export USEMODULE # Sys Module dependencies of the application. Set in the application's Makefile.
export USEPKG # Pkg dependencies (third party modules) of the application. Set in the application's Makefile.
export LIBS # Build a static archive instead of a single object file for the given modules. Set by the package's Makefile.include when necessary
export DISABLE_MODULE # Used in the application's Makefile to suppress DEFAULT_MODULEs.
export APPDEPS # Files / Makefile targets that need to be created before the application can be build. Set in the application's Makefile.
# BUILDDEPS # Files / Makefile targets that need to be created before starting to build.
Expand Down Expand Up @@ -55,6 +56,8 @@ export AR # The command to create the object file archives.
export ARFLAGS # Command-line options to pass to AR, default `rcs`.
export AS # The assembler.
export ASFLAGS # Flags for the assembler.
export ILINK # Command used to perform incremental linking to create intermediate object files. Usually "ld"
export ILINKFLAGS # Incremental link command line options.
export LINK # The command used to link the files. Must take the same parameters as GCC, i.e. "ld" won't work.
# LINKFLAGS # Flags to supply in the linking step.
export LTOFLAGS # extra CFLAGS for compiling with link time optimization
Expand All @@ -64,7 +67,6 @@ export OBJDUMP # The command used to create the assembly listing.
export OBJDUMPFLAGS # The parameter for OBJDUMP.
export SIZE # The command to read to size of the ELF sections.
export SIZEFLAGS # The optional size flags.
export UNDEF # Object files that the linker must include in the ELFFILE even if no call to the functions or symbols (ex: interrupt vectors).
export WERROR # Treat all compiler warnings as errors if set to 1 (see -Werror flag in GCC manual)

export GITCACHE # path to git-cache executable
Expand Down
1 change: 1 addition & 0 deletions pkg/ccn-lite/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ INCLUDES += -I$(PKGDIRBASE)/ccn-lite/src/ccnl-fwd/include
INCLUDES += -I$(RIOTBASE)/sys/posix/include

CFLAGS += -DCCNL_RIOT
LIBS += ccn-lite
5 changes: 5 additions & 0 deletions pkg/jerryscript/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,2 +1,7 @@
INCLUDES += -I$(PKGDIRBASE)/jerryscript/jerry-core/include
INCLUDES += -I$(PKGDIRBASE)/jerryscript/jerry-ext/include

# the jerryscript build produces static archives
LIBS += jerryscript
LIBS += jerryscript-ext
LIBS += jerryport-minimal
3 changes: 3 additions & 0 deletions pkg/nordic_softdevice_ble/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ CFLAGS += -Wno-pedantic -Wno-unused-parameter -Wno-sign-compare
# so set this, otherwise linking fails
CFLAGS_FPU := -mfloat-abi=hard -mfpu=fpv4-sp-d16

# ble_6lowpan.a is provided as a binary-only library within the softdevice package
LIBS += ble_6lowpan

DIRS += \
$(RIOTBASE)/pkg/nordic_softdevice_ble/src \
$(NORDIC_SRCS)/components/softdevice/common/softdevice_handler \
Expand Down
Loading