Merge pull request #244 from sdettmer/dev/sde/faketime_link_flags

Added support for FAKETIME_LINK_FLAGS for #243.
This commit is contained in:
Wolfgang Hommel
2020-04-08 19:47:46 +02:00
committed by GitHub
3 changed files with 7 additions and 2 deletions

4
NEWS
View File

@@ -1,3 +1,7 @@
- Additional link-time LDFLAGS can be passed via the
environment variable FAKETIME_LINK_FLAGS when
running 'make'.
Since 0.9.8:
- Compile-time CFLAG FAKE_SETTIME can be enabled to
intercept calls to clock_settime(), settimeofday(), and

View File

@@ -42,7 +42,8 @@ variable, so for example
FAKETIME_COMPILE_CFLAGS="-DFORCE_PTHREAD_NONVER" make test
would create the libfaketime binaries and run the tests with the
FORCE_PTHREAD_NONVER flag set in a single step.
FORCE_PTHREAD_NONVER flag set in a single step. Likewise there is
FAKETIME_LINK_FLAGS.
Please do not use FORCE_MONOTONIC_FIX by default, as it would result
in incorrect operations on platforms that do not need it.

View File

@@ -79,7 +79,7 @@ endif
LIB_LDFLAGS += -shared
LDFLAGS += -lpthread
LDFLAGS += $(FAKETIME_LINK_FLAGS) -lpthread
ifneq ($(PLATFORM),SunOS)
LDFLAGS += -Wl,--version-script=libfaketime.map
endif