Skip to content

Commit d2ea250

Browse files
authored
Make the SwiftPM build system configurable as a make variable (#180)
1 parent 6e4cd31 commit d2ea250

File tree

7 files changed

+14
-0
lines changed

7 files changed

+14
-0
lines changed

rpi-4b-blink/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,13 @@ TOOLSROOT := $(REPOROOT)/Tools
1515
TOOLSET := $(TOOLSROOT)/Toolsets/rpi-5-elf.json
1616
LLVM_OBJCOPY := llvm-objcopy
1717
SWIFT_BUILD := swift build
18+
BUILD_SYSTEM := native
1819

1920
# Flags
2021
ARCH := aarch64
2122
TARGET := $(ARCH)-none-none-elf
2223
SWIFT_BUILD_ARGS := \
24+
--build-system $(BUILD_SYSTEM) \
2325
--configuration release \
2426
--triple $(TARGET) \
2527
--toolset $(TOOLSET)

rpi-5-blink/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,13 @@ TOOLSROOT := $(REPOROOT)/Tools
1515
TOOLSET := $(TOOLSROOT)/Toolsets/rpi-5-elf.json
1616
LLVM_OBJCOPY := llvm-objcopy
1717
SWIFT_BUILD := swift build
18+
BUILD_SYSTEM := native
1819

1920
# Flags
2021
ARCH := aarch64
2122
TARGET := $(ARCH)-none-none-elf
2223
SWIFT_BUILD_ARGS := \
24+
--build-system $(BUILD_SYSTEM) \
2325
--configuration release \
2426
--triple $(TARGET) \
2527
--toolset $(TOOLSET)

rpi-pico-blink/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,14 @@ TOOLSROOT := $(REPOROOT)/Tools
1515
TOOLSET := $(TOOLSROOT)/Toolsets/pico.json
1616
MACHO2UF2 := $(TOOLSROOT)/macho2uf2.py
1717
SWIFT_BUILD := swift build
18+
BUILD_SYSTEM := native
1819

1920
# Flags
2021
PICO_FAMILY := rp2040
2122
ARCH := armv6m
2223
TARGET := $(ARCH)-apple-none-macho
2324
SWIFT_BUILD_ARGS := \
25+
--build-system $(BUILD_SYSTEM) \
2426
--configuration release \
2527
--triple $(TARGET) \
2628
--toolset $(TOOLSET)

rpi-pico2-neopixel/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,13 @@ TOOLSROOT := $(REPOROOT)/Tools
1515
TOOLSET := $(TOOLSROOT)/Toolsets/pico2.json
1616
MACHO2UF2 := $(TOOLSROOT)/macho2uf2.py
1717
SWIFT_BUILD := swift build
18+
BUILD_SYSTEM := native
1819

1920
# Setup tools and build flags
2021
ARCH := armv7em
2122
TARGET := $(ARCH)-apple-none-macho
2223
SWIFT_BUILD_ARGS := \
24+
--build-system $(BUILD_SYSTEM) \
2325
--configuration release \
2426
--triple $(TARGET) \
2527
--toolset $(TOOLSET)

stm32-lvgl/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,13 @@ ELF2HEX := $(TOOLSROOT)/elf2hex.py
1717
SWIFT_BUILD := swift build
1818
NM := nm
1919
LLVM_TOOLCHAIN := $(PWD)/llvm-toolchain
20+
BUILD_SYSTEM := native
2021

2122
# Flags
2223
ARCH := armv7em
2324
TARGET := $(ARCH)-none-none-eabi
2425
SWIFT_BUILD_ARGS := \
26+
--build-system $(BUILD_SYSTEM) \
2527
--configuration release \
2628
--triple $(TARGET) \
2729
--toolset $(TOOLSET) \

stm32-neopixel/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,13 @@ TOOLSROOT := $(REPOROOT)/Tools
1515
TOOLSET := $(TOOLSROOT)/Toolsets/stm32f74x.json
1616
MACHO2BIN := $(TOOLSROOT)/macho2bin.py
1717
SWIFT_BUILD := swift build
18+
BUILD_SYSTEM := native
1819

1920
# Flags
2021
ARCH := armv7em
2122
TARGET := $(ARCH)-apple-none-macho
2223
SWIFT_BUILD_ARGS := \
24+
--build-system $(BUILD_SYSTEM) \
2325
--configuration release \
2426
--triple $(TARGET) \
2527
--toolset $(TOOLSET)

stm32-uart-echo/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,13 @@ TOOLSROOT := $(REPOROOT)/Tools
1515
TOOLSET := $(TOOLSROOT)/Toolsets/stm32f74x.json
1616
MACHO2BIN := $(TOOLSROOT)/macho2bin.py
1717
SWIFT_BUILD := swift build
18+
BUILD_SYSTEM := native
1819

1920
# Flags
2021
ARCH := armv7em
2122
TARGET := $(ARCH)-apple-none-macho
2223
SWIFT_BUILD_ARGS := \
24+
--build-system $(BUILD_SYSTEM) \
2325
--configuration release \
2426
--triple $(TARGET) \
2527
--toolset $(TOOLSET)

0 commit comments

Comments
 (0)