forked from alejandro-isaza/Upsurge
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Makefile to build libUpsurge.a and .swiftmodule
- Loading branch information
1 parent
38dfbcf
commit eb568e9
Showing
1 changed file
with
20 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
VPATH = Array Complex DSP Matrix Operations Tensor Types | ||
SDK=$$(xcrun --show-sdk-path --sdk macosx) | ||
SRC=ValueArray.swift ValueArraySlice.swift DSP.swift Matrix.swift MatrixArithmetic.swift Tensor.swift TensorSlice.swift Span.swift Arithmetic.swift Auxiliary.swift Exponential.swift Hyperbolic.swift Trigonometric.swift ContiguousMemory.swift Interval.swift Real.swift Value.swift | ||
OBJS:=$(subst .swift,.o,$(SRC)) | ||
|
||
.PHONY: all | ||
all: libUpsurge.a Upsurge.swiftmodule | ||
|
||
libUpsurge.a: $(OBJS) | ||
libtool -static -s -o $@ -no_warning_for_no_symbols $^ | ||
|
||
Upsurge.swiftmodule: $(SRC) | ||
xcrun swiftc -emit-module $^ -sdk $(SDK) -module-name Upsurge | ||
|
||
$(OBJS): $(SRC) | ||
xcrun swiftc -emit-library -emit-object $^ -sdk $(SDK) -module-name Upsurge | ||
|
||
.PHONY: clean | ||
clean: | ||
rm -f *.o *.a *.swiftdoc *.swiftmodule |