Skip to content

Commit 0452dfb

Browse files
committed
Update Makefile: adjust linker flags for Linux and test target
1 parent 236066e commit 0452dfb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ else ifeq ($(PLATFORM),isim)
6464
CFLAGS += -arch x86_64 -arch arm64 $(SDK)
6565
else # linux
6666
TARGET := $(DIST_DIR)/js.so
67-
LDFLAGS := -shared
67+
LDFLAGS := -lm -shared
6868
endif
6969

7070
# Object files
@@ -131,7 +131,7 @@ endif
131131

132132
# Compile test target
133133
$(TEST_TARGET): $(TEST_FILES) $(TARGET)
134-
$(CC) $(INCLUDES) $^ -lm -o $@ libs/sqlite3.c -DSQLITE_CORE
134+
$(CC) $(INCLUDES) $^ -o $@ libs/sqlite3.c -DSQLITE_CORE
135135

136136
# Testing the extension
137137
test: $(TARGET) $(TEST_TARGET)

0 commit comments

Comments
 (0)