# In case of windows, use os_cygwin=yes setting in the configuration file (smsd.conf).

# Uncomment for Solaris
# CFLAGS = -D SOLARIS
# CC=gcc

# Comment this out, to enable statistics
CFLAGS += -D NOSTATS

# Uncomment this to force smsd to run in terminal mode
#CFLAGS += -D TERMINAL

# Uncomment to add debug info
# CFLAGS += -ggdb -O0

# The following options are only used by developers
# CFLAGS += -Wall 
# CFLAGS += -D DEBUGMSG

all: smsd 

smsd: smsd.c extras.o locking.o cfgfile.o logging.o alarm.o smsd_cfg.o charset.o stats.o blacklist.o whitelist.o modeminit.o pdu.o
ifneq (,$(findstring NOSTATS,$(CFLAGS)))
	  $(CC) $(CFLAGS) -o $@ $^
else 
	  $(CC) `mm-config --cflags` $(CFLAGS) -o $@ $^ `mm-config --ldflags --libs`
	@echo "(Please ignore warning about tempnam -- it is used in a safe way)"
endif

clean:
	rm -f *.o smsd *.exe
