Commit c06eb3b73a07f18e24634bd96d3ef791bc43a3dc

David Turner 2000-05-12T15:10:21

fixed stupid math lib bug in the Makefile

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff --git a/demos/Makefile b/demos/Makefile
index d6ca827..c1d47b1 100644
--- a/demos/Makefile
+++ b/demos/Makefile
@@ -82,6 +82,14 @@ else
   # be re-defined for platform-specific stuff..
   #
   LINK = $(CC) $T$@ $< $(FTLIB) $(EFENCE) $(LDFLAGS)
+  
+  # the program "src/ftstring.c" used the math library which isn't linked
+  # with the program by default on Unix, we thus add it whenever appropriate
+  #
+  ifeq ($(PLATFORM),unix)
+  LINK += -lm
+  endif
+
   COMMON_LINK = $(LINK) $(COMMON_OBJ)
   GRAPH_LINK  = $(COMMON_LINK) $(GRAPH_LIB)
   GRAPH_LINK2 = $(GRAPH_LINK) $(EXTRA_GRAPH_OBJS)