summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Noble <nnoble@blizzard.com>2013-07-15 15:43:22 -0700
committerNicolas Noble <nnoble@blizzard.com>2013-07-15 15:43:22 -0700
commit8860ba11e6cb76586a32cb80cb443837a78e3a38 (patch)
tree6945c36a624a84ceeaed91380314b8b44064d2a2
parent20e2097e286bc41a36671cb78c2ad7039f505a66 (diff)
Using Balau's common.mk file to clean up Makefile.
m---------Balau0
-rw-r--r--Makefile32
2 files changed, 1 insertions, 31 deletions
diff --git a/Balau b/Balau
-Subproject 79ed0f94c0c682e2902d8787885a007189a010b
+Subproject 9dfd1d7a95988e0682d772010c3e13c6170e7d2
diff --git a/Makefile b/Makefile
index b4282cf..9253ccc 100644
--- a/Makefile
+++ b/Makefile
@@ -1,20 +1,4 @@
-ifeq ($(SYSTEM),)
- SYSTEM = $(shell uname | cut -f 1 -d_)
-endif
-
-TRUESYSTEM = $(shell uname)
-MACHINE = $(shell uname -m)
-DISTRIB = $(shell cat /etc/issue | cut -f 1 -d\ | head -1)
-
-CC = gcc
-CXX = g++
-LD = g++
-AS = gcc -c
-AR = ar rcs
-
-BINEXT = bin
-
-CPPFLAGS += -fno-strict-aliasing
+include Balau/common.mk
ifeq ($(DEBUG),)
CPPFLAGS += -g -O3 -DNDEBUG
@@ -28,32 +12,18 @@ INCLUDES = includes Balau/includes Balau/libcoro Balau/libeio Balau/libev Balau/
LIBS = z readline
ifeq ($(SYSTEM),Darwin)
- CC = clang
- CXX = clang++
- CPPFLAGS += -fPIC
- LDFLAGS += -fPIC
LIBS += pthread iconv
CONFIG_H = Balau/darwin-config.h
- ARCH_FLAGS = -arch i386
- LD = clang++ -arch i386
- STRIP = strip -x
endif
ifeq ($(SYSTEM),Linux)
- CPPFLAGS += -fPIC
- LDFLAGS += -fPIC -rdynamic
LIBS += pthread dl
CONFIG_H = Balau/linux-config.h
- ARCH_FLAGS = -march=i686 -m32
- ASFLAGS = -march=i686 --32
- STRIP = strip --strip-unneeded
endif
CPPFLAGS_NO_ARCH += $(addprefix -I, $(INCLUDES)) -fexceptions -imacros $(CONFIG_H)
CPPFLAGS += $(CPPFLAGS_NO_ARCH) $(ARCH_FLAGS)
-CXXFLAGS += -Wno-deprecated -std=gnu++0x
-
LDFLAGS += $(ARCH_FLAGS)
LDLIBS = $(addprefix -l, $(LIBS))