From f3e255ddca6468b6adea0f10f30540c37cdde9ad Mon Sep 17 00:00:00 2001 From: "N.N." Date: Tue, 18 Sep 2007 17:19:03 +0000 Subject: first commit for tclpd external svn path=/trunk/externals/tclpd/; revision=8736 --- Makefile | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..5c97c54 --- /dev/null +++ b/Makefile @@ -0,0 +1,38 @@ +#!/usr/bin/make + +CPU=athlon-xp +CFLAGS += -I/usr/include -I. -xc++ -funroll-loops -fno-operator-names -fno-omit-frame-pointer -falign-functions=16 -mtune=$(CPU) -march=$(CPU) -Wall -Wno-unused -Wunused-variable -Wno-strict-aliasing -g -fPIC -I. +LDSOFLAGS += -lm -L/usr/lib -ltcl8.5 -L/usr/X11R6/lib +CXX = g++ +OS = linux +LDSHARED = $(CXX) $(PDBUNDLEFLAGS) + +all:: tcl + +clean:: + rm -f tcl.pd_linux tcl_wrap.cxx *.o *~ + +.SUFFIXES: + +ifeq ($(OS),darwin) + PDSUF = .pd_darwin + PDBUNDLEFLAGS = -bundle -flat_namespace -undefined suppress +else + ifeq ($(OS),nt) + PDSUF = .dll + PDBUNDLEFLAGS = -shared + else + PDSUF = .pd_linux + PDBUNDLEFLAGS = -shared -rdynamic + endif +endif + +tcl:: tcl.pd_linux + +tcl.pd_linux: tcl_wrap.cxx tcl_extras.cxx tcl_loader.cxx tcl_extras.h Makefile + $(LDSHARED) $(CFLAGS) -DPDSUF=\"$(PDSUF)\" -o tcl$(PDSUF) \ + tcl_wrap.cxx tcl_extras.cxx tcl_loader.cxx $(LDSOFLAGS) + +tcl_wrap.cxx: tcl.i tcl_extras.h + swig -v -c++ -tcl -o tcl_wrap.cxx -I/usr/include -I/usr/local/include tcl.i + -- cgit v1.2.1