src/Makefile
branchENGINE-229
changeset 1997 2c10033e2ade
parent 1993 efaeadf3e6f0
child 2002 6b465132be58
child 2011 86bbefb0e806
     1.1 --- a/src/Makefile	Thu Aug 24 11:46:42 2017 +0200
     1.2 +++ b/src/Makefile	Thu Aug 24 15:05:08 2017 +0200
     1.3 @@ -8,6 +8,7 @@
     1.4  CFLAGS+= $(ETPAN_INC) -I../asn.1 -DSYSTEM_DB=\"$(SYSTEM_DB)\" $(EXTRA_MACROS)
     1.5  LDFLAGS+= $(ETPAN_LIB) -L../asn.1 -shared
     1.6  LDLIBS+= -lc -letpan -lasn1
     1.7 +NO_SOURCE=
     1.8  
     1.9  ifeq ($(BUILD_ON),Darwin)
    1.10      ifeq ($(BUILD_FOR),Darwin)
    1.11 @@ -28,13 +29,18 @@
    1.12      $(error I don't know how to make for $(BUILD_FOR) on $(BUILD_ON))
    1.13  endif
    1.14  
    1.15 +ifdef SQLITE3_FROM_OS
    1.16 +    NO_SOURCE+= sqlite3.c
    1.17 +    CFLAGS+= -DSQLITE3_FROM_OS
    1.18 +endif
    1.19 +
    1.20  ifeq ($(OPENPGP),GPG)
    1.21 -    NO_SOURCE=pgp_netpgp.c
    1.22 +    NO_SOURCE+= pgp_netpgp.c
    1.23      CFLAGS+= -DUSE_GPG $(GPGME_INC) -DLIBGPGME=\"$(LIBGPGME)\"
    1.24      LDFLAGS+= $(GPGME_LIB)
    1.25      # No extra LDLIBS are needed here, because GPGME is dynamically loaded
    1.26  else ifeq ($(OPENPGP),NETPGP)
    1.27 -    NO_SOURCE=pgp_gpg.c
    1.28 +    NO_SOURCE+= pgp_gpg.c
    1.29      CFLAGS+= -DUSE_NETPGP $(NETGPG_INC)
    1.30      LDFLAGS+= $(NETGPG_LIB)
    1.31      LDLIBS+= -lnetpgp -lcurl
    1.32 @@ -42,7 +48,7 @@
    1.33      $(error Unknown OpenPGP library: $(OPENPGP))
    1.34  endif
    1.35  
    1.36 -ALL_SOURCE=$(subst $(NO_SOURCE),,$(wildcard *.c))
    1.37 +ALL_SOURCE=$(filter-out $(NO_SOURCE),$(wildcard *.c))
    1.38  DEPENDS=$(subst .c,.d,$(ALL_SOURCE))
    1.39  ALL_OBJECTS=$(subst .c,.o,$(ALL_SOURCE))
    1.40