From 67e45b1bf1888b5c132052e38fe1453ab5fcbd2e Mon Sep 17 00:00:00 2001 From: Shawn Chain Date: Fri, 5 Oct 2018 12:40:34 +0800 Subject: [PATCH] Try to work --- Common/DStarDefines.h | 1 + GlobalDefines.h | 11 +++++++++++ Makefile | 7 ++++++- common.mk | 26 -------------------------- 4 files changed, 18 insertions(+), 27 deletions(-) create mode 100644 GlobalDefines.h diff --git a/Common/DStarDefines.h b/Common/DStarDefines.h index 8ea9ae6..9a0b1f0 100644 --- a/Common/DStarDefines.h +++ b/Common/DStarDefines.h @@ -15,6 +15,7 @@ #define DStarDefines_H #include +#include "GlobalDefines.h" const unsigned int DSTAR_GMSK_SYMBOL_RATE = 4800U; const float DSTAR_GMSK_BT = 0.5F; diff --git a/GlobalDefines.h b/GlobalDefines.h new file mode 100644 index 0000000..c83a798 --- /dev/null +++ b/GlobalDefines.h @@ -0,0 +1,11 @@ +#ifndef __GLOBAL_DEFS__ +#define __GLOBAL_DEFS__ + +#ifndef DATA_DIR +#define DATA_DIR "/etc/mmdvm/ircddbgateway" +#define LOG_DIR "/var/log/mmdvm" +#define CONF_DIR "/etc" +#define BIN_DIR "/usr/bin" +#endif + +#endif diff --git a/Makefile b/Makefile index fb7e425..e14b3d3 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,9 @@ -include common.mk + +# CXX := $(shell wx-config --cxx) +# CFLAGS := -O2 -Wall $(shell wx-config --cxxflags) -DLOG_DIR='$(LOGDIR)' -DCONF_DIR='$(CONFDIR)' -DDATA_DIR='$(DATADIR)' +# GUILIBS := $(shell wx-config --libs adv,core,base) +# LIBS := $(shell wx-config --libs base) +# LDFLAGS := all: ircDDBGateway/ircddbgatewayd diff --git a/common.mk b/common.mk index e2a7724..e69de29 100644 --- a/common.mk +++ b/common.mk @@ -1,26 +0,0 @@ - -# Add -DDCS_LINK to the end of the CFLAGS line below to add DCS linking to StarNet -# Add -DDEXTRA_LINK to the end of the CFLAGS line below to add DExtra linking to StarNet - -DATADIR := "/etc/mmdvm/ircddbgateway" -LOGDIR := "/var/log/mmdvm" -CONFDIR := "/etc" -BINDIR := "/usr/bin" - -CFLAGS += -DLOG_DIR='$(LOGDIR)' -DCONF_DIR='$(CONFDIR)' -DDATA_DIR='$(DATADIR)' -LIBS += -LDFLAGS := - -# else -# DATADIR := "/usr/share/ircddbgateway" -# LOGDIR := "/var/log" -# CONFDIR := "/etc" -# BINDIR := "/usr/bin" - -# CXX := $(shell wx-config --cxx) -# CFLAGS := -O2 -Wall $(shell wx-config --cxxflags) -DLOG_DIR='$(LOGDIR)' -DCONF_DIR='$(CONFDIR)' -DDATA_DIR='$(DATADIR)' -# GUILIBS := $(shell wx-config --libs adv,core,base) -# LIBS := $(shell wx-config --libs base) -# LDFLAGS := - -# endif