aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorYour Name <you@example.com>2022-02-17 17:17:30 -0500
committerYour Name <you@example.com>2022-02-17 17:17:30 -0500
commitaa9dabdeaead3c8b1b11f9d4f321265c439bfbfc (patch)
tree19f31e283890fba9042628c8c48657bfc0a7f4bf /Makefile
parentb760bab7c1c4c09e84c9db9f0868d959fa735a6b (diff)
downloadlibbible-aa9dabdeaead3c8b1b11f9d4f321265c439bfbfc.tar.gz
libbible-aa9dabdeaead3c8b1b11f9d4f321265c439bfbfc.tar.bz2
libbible-aa9dabdeaead3c8b1b11f9d4f321265c439bfbfc.zip
Now respects environment LDFLAGS
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 3 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 4fe1ffc..6b367f8 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
CC=g++
LIBS=sword minizip
CFLAGS=-c -Wall -fPIC -std=c++20
-LDFLAGS=-lstdc++fs
+LDLIBS=-lstdc++fs
SOURCES=libbible.cc mods.cc settings.cc
OBJECTS=$(SOURCES:.cc=.o)
LIBRARY=libbible.so
@@ -29,13 +29,13 @@ testLibbible.o: testLibbible.cc
$(CC) $(CFLAGS) testLibbible.cc -o $@
bible: $(OBJECTS) bible.o
- $(CC) $(OBJECTS) bible.o -o $@ $(LDFLAGS) `pkg-config $(LIBS) --libs`
+ $(CC) $(OBJECTS) bible.o -o $@ $(LDFLAGS) `pkg-config $(LIBS) --libs` $(LDLIBS)
bible.o: bible.cc
$(CC) $(CFLAGS) bible.cc -o $@
$(LIBRARY): $(OBJECTS)
- $(CC) $(OBJECTS) -shared -o $@ $(LDFLAGS) `pkg-config $(LIBS) --libs`
+ $(CC) $(OBJECTS) -shared -o $@ $(LDFLAGS) `pkg-config $(LIBS) --libs` $(LDLIBS)
.cc.o:
$(CC) $(CFLAGS) $< -o $@ `pkg-config $(LIBS) --cflags`