Skip to content

Commit

Permalink
fixup! native: 64 bit compatibility and Linux/x86_64 support for the …
Browse files Browse the repository at this point in the history
…native board
  • Loading branch information
fzi-haxel committed Aug 18, 2023
1 parent e939795 commit 554c916
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
14 changes: 11 additions & 3 deletions boards/native/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ ifeq (,$(filter -std=%, $(CFLAGS)))
endif

ifeq ($(OS_ARCH),x86_64)
ifneq ($(NATIVE_64BIT), y)
ifeq ($(NATIVE_64BIT), y)
CFLAGS += -m64
else
CFLAGS += -m32
endif
endif
Expand All @@ -50,7 +52,9 @@ ifneq (,$(filter -DDEVELHELP,$(CFLAGS)))
endif
ifeq ($(OS),FreeBSD)
ifeq ($(OS_ARCH),amd64)
ifneq ($(NATIVE_64BIT), y)
ifeq ($(NATIVE_64BIT), y)
CFLAGS += -m64
else
CFLAGS += -m32 -DCOMPAT_32BIT -B/usr/lib32
endif
endif
Expand All @@ -64,13 +68,17 @@ CXXUWFLAGS +=
CXXEXFLAGS +=

ifeq ($(OS_ARCH),x86_64)
ifneq ($(NATIVE_64BIT), y)
ifeq ($(NATIVE_64BIT), y)
LINKFLAGS += -m64
else
LINKFLAGS += -m32
endif
endif
ifeq ($(OS),FreeBSD)
ifeq ($(OS_ARCH),amd64)
ifneq ($(NATIVE_64BIT), y)
LINKFLAGS += -m64
else

Check failure on line 81 in boards/native/Makefile.include

View workflow job for this annotation

GitHub Actions / static-tests

trailing whitespace.
LINKFLAGS += -m32 -DCOMPAT_32BIT -L/usr/lib32 -B/usr/lib32
endif
endif
Expand Down
6 changes: 3 additions & 3 deletions cpu/native/Makefile.features
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ ifeq (FreeBSD,$(OS))
DISABLE_LIBSTDCPP ?= 1
endif

ifneq ($(NATIVE_64BIT), y)
FEATURES_PROVIDED += arch_32bit
else
ifeq ($(NATIVE_64BIT), y)
FEATURES_PROVIDED += arch_64bit
else
FEATURES_PROVIDED += arch_32bit
endif
FEATURES_PROVIDED += arch_native
FEATURES_PROVIDED += cpp
Expand Down

0 comments on commit 554c916

Please sign in to comment.