aboutsummaryrefslogtreecommitdiff
path: root/opengl/Makefile.config
blob: 1e0fd61c385d1533b3dca0ef8bbc4ebebcab00d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36

prefix = /usr/local

PDP_VERSION=0.12.6
PDP_DIR = ../../include
PDP_OGL_DIR = ../include


CFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer  -ffast-math \
    -Wall -W -Wstrict-prototypes \
    -Wno-unused -Wno-parentheses -Wno-switch -g -I../../../../pd/src


CPPFLAGS = -I$(PDP_DIR) -I$(PDP_OGL_DIR) -I/usr/X11R6/include -DPDP_VERSION=\"$(PDP_VERSION)\"
# CPPFLAGS = -I$(PD_DIR) -I$(PDP_DIR) -I$(PDP_OGL_DIR) -I/usr/X11R6/include

UNAME := $(shell uname -s)
ifeq ($(UNAME),Linux)
  TARGET=linux
  LDFLAGS = -lGL -lglut
  CFLAGS+= -fPIC
endif
ifeq ($(UNAME),Darwin)
  TARGET = darwin
  CPPFLAGS += -I/sw/include
  PD_EXECUTABLE=../../../pd/bin/pd
  LDFLAGS = -lgsl -lGL -lGLU -lglut -lX11 -L/sw/lib -L/usr/X11R6/lib
endif



PDP_OPENGL_LIBRARY_NAME=pdp_opengl.pd_$(TARGET)


.c.o:
	$(CC) $(CFLAGS) $(CPPFLAGS) -o $*.o -c $*.c