Browse Source

linking fails because clock_gettime is missing without -lrt flag on ubuntu

Nick Hildebrant 10 năm trước cách đây
mục cha
commit
1dbd48c011
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      Makefile

+ 1 - 1
Makefile

@@ -62,7 +62,7 @@ endif
 # only set main compile options if none were chosen
 # only set main compile options if none were chosen
 CFLAGS += -W -Wall -O2 -D$(TARGET_OS) -Iinclude $(COPT) -DUSE_STACK_SIZE=102400
 CFLAGS += -W -Wall -O2 -D$(TARGET_OS) -Iinclude $(COPT) -DUSE_STACK_SIZE=102400
 
 
-LIBS = -lpthread -lm
+LIBS = -lpthread -lm -lrt
 
 
 ifdef WITH_DEBUG
 ifdef WITH_DEBUG
   CFLAGS += -g -DDEBUG_ENABLED
   CFLAGS += -g -DDEBUG_ENABLED