summaryrefslogtreecommitdiff
path: root/libs/dgl
diff options
context:
space:
mode:
authorfalkTX <falktx@gmail.com>2014-04-10 18:34:26 +0000
committerfalkTX <falktx@gmail.com>2014-04-10 18:34:26 +0000
commit1864f2255a331e311de31cdbb8800a197dfa9e1d (patch)
tree7fd5e1a12d0f3d851a88d22988d37e89dc4b2bb6 /libs/dgl
parentd037de78e5454474037e2d12a298cff19b177a90 (diff)
Rework makefile structure
Diffstat (limited to 'libs/dgl')
-rw-r--r--libs/dgl/Makefile12
-rw-r--r--libs/dgl/Makefile.mk79
2 files changed, 1 insertions, 90 deletions
diff --git a/libs/dgl/Makefile b/libs/dgl/Makefile
index 6d6e949..fb65940 100644
--- a/libs/dgl/Makefile
+++ b/libs/dgl/Makefile
@@ -4,7 +4,7 @@
# Created by falkTX
#
-include Makefile.mk
+include ../../Makefile.mk
# --------------------------------------------------------------
@@ -42,16 +42,6 @@ all: $(TARGET)
$(RM) $@
$(AR) crs $@ $^
-../libdgl.dll: $(OBJS)
- # -Wl,--output-def,$@.def,--out-implib,$@.a
- $(CXX) $^ -shared $(LINK_FLAGS) -o $@
-
-../libdgl.dylib: $(OBJS)
- $(CXX) $^ -dynamiclib $(LINK_FLAGS) -o $@
-
-../libdgl.so: $(OBJS)
- $(CXX) $^ -shared $(LINK_FLAGS) -o $@
-
# --------------------------------------------------------------
%.cpp.o: %.cpp
diff --git a/libs/dgl/Makefile.mk b/libs/dgl/Makefile.mk
deleted file mode 100644
index a5ef785..0000000
--- a/libs/dgl/Makefile.mk
+++ /dev/null
@@ -1,79 +0,0 @@
-#!/usr/bin/make -f
-# Makefile for dgl #
-# ---------------- #
-# Created by falkTX
-#
-
-AR ?= ar
-RM ?= rm -f
-
-CC ?= gcc
-CXX ?= g++
-
-# --------------------------------------------------------------
-# Fallback to Linux if no other OS defined
-
-ifneq ($(MACOS),true)
-ifneq ($(WIN32),true)
-LINUX=true
-endif
-endif
-
-# --------------------------------------------------------------
-# Common build and link flags
-
-BASE_FLAGS = -Wall -Wextra -fPIC -DPIC -pipe -DREAL_BUILD
-BASE_OPTS = -O3 -ffast-math -mtune=generic -msse -msse2 -mfpmath=sse
-
-ifeq ($(RASPPI),true)
-# Raspberry-Pi optimization flags
-BASE_OPTS = -O3 -ffast-math -march=armv6 -mfpu=vfp -mfloat-abi=hard
-endif
-
-ifeq ($(DEBUG),true)
-BASE_FLAGS += -DDEBUG -O0 -g
-else
-BASE_FLAGS += -DNDEBUG $(BASE_OPTS) -fvisibility=hidden
-CXXFLAGS += -fvisibility-inlines-hidden
-LINK_OPTS += -Wl,--strip-all
-endif
-
-BUILD_C_FLAGS = $(BASE_FLAGS) -std=gnu99 $(CFLAGS)
-BUILD_CXX_FLAGS = $(BASE_FLAGS) -std=gnu++0x $(CXXFLAGS)
-LINK_FLAGS = $(LINK_OPTS) -Wl,--no-undefined $(LDFLAGS)
-
-ifeq ($(MACOS),true)
-# Get rid of most options for old gcc4.2
-BUILD_CXX_FLAGS = $(BASE_FLAGS) $(CXXFLAGS)
-LINK_FLAGS = $(LDFLAGS)
-endif
-
-# --------------------------------------------------------------
-# Check for required libs
-
-ifeq ($(LINUX),true)
-ifneq ($(shell pkg-config --exists gl && echo true),true)
-$(error OpenGL missing, cannot continue)
-endif
-ifneq ($(shell pkg-config --exists x11 && echo true),true)
-$(error X11 missing, cannot continue)
-endif
-endif
-
-# --------------------------------------------------------------
-# Set libs stuff
-
-ifeq ($(LINUX),true)
-DGL_FLAGS = $(shell pkg-config --cflags gl x11)
-DGL_LIBS = $(shell pkg-config --libs gl x11)
-endif
-
-ifeq ($(MACOS),true)
-DGL_LIBS = -framework OpenGL -framework Cocoa
-endif
-
-ifeq ($(WIN32),true)
-DGL_LIBS = -lopengl32 -lgdi32
-endif
-
-# --------------------------------------------------------------