diff options
author | Thomas Grill <xovo@users.sourceforge.net> | 2005-01-03 05:00:31 +0000 |
---|---|---|
committer | Thomas Grill <xovo@users.sourceforge.net> | 2005-01-03 05:00:31 +0000 |
commit | 1611d50c03d8f79560ffc3bc63c268894f411abc (patch) | |
tree | 33a751fe81ef62e3bb4104f82132d3bc43efcaa7 /externals/grill/flext/buildsys/mac | |
parent | 7873938d18daf4a94ca77eeb970457f89e679374 (diff) |
updated make system
build system for OSX
simplified make system
reconsidered flext::buffer:Update
added object construction and destruction flags
updated build system
svn path=/trunk/; revision=2447
Diffstat (limited to 'externals/grill/flext/buildsys/mac')
-rw-r--r-- | externals/grill/flext/buildsys/mac/gnumake-gcc-ext.inc | 51 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/gnumake-gcc-flext.inc | 64 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/gnumake-gcc.inc | 12 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/make-gcc.inc | 102 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/max/config-gcc.def | 20 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/max/gnumake-gcc-ext.inc | 8 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/max/gnumake-gcc-flext.inc | 12 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/max/gnumake-gcc.inc (renamed from externals/grill/flext/buildsys/mac/max/make-gcc.inc) | 2 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/pd/config-gcc.def | 24 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/pd/gnumake-gcc-ext.inc | 1 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/pd/gnumake-gcc-flext.inc | 5 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/pd/gnumake-gcc.inc | 13 | ||||
-rw-r--r-- | externals/grill/flext/buildsys/mac/pd/make-gcc.inc | 10 |
13 files changed, 201 insertions, 123 deletions
diff --git a/externals/grill/flext/buildsys/mac/gnumake-gcc-ext.inc b/externals/grill/flext/buildsys/mac/gnumake-gcc-ext.inc new file mode 100644 index 00000000..ad4e2856 --- /dev/null +++ b/externals/grill/flext/buildsys/mac/gnumake-gcc-ext.inc @@ -0,0 +1,51 @@ +# build class specific settings
+
+INCPATH += -I$(FLEXTINC)
+LIBPATH += -L$(FLEXTLIB) -L$(FLEXTSHLIB)
+LIBS += -l$(FLEXTNAME)
+
+##############################################
+
+CSRCS=$(patsubst %.c,$(SRCDIR)/%.c,$(filter %.c,$(SRCS)))
+CPPSRCS=$(patsubst %.cpp,$(SRCDIR)/%.cpp,$(filter %.cpp,$(SRCS)))
+COBJS=$(patsubst %.c,$(OBJPATH)/%.o,$(filter %.c,$(SRCS)))
+CPPOBJS=$(patsubst %.cpp,$(OBJPATH)/%.opp,$(filter %.cpp,$(SRCS)))
+
+##############################################
+
+# default target
+_build_: $(TARGET)
+
+$(CSRCS) $(CPPSRCS): $(patsubst %,$(SRCDIR)/%,$(HDRS))
+ touch $@
+
+$(OBJPATH):
+ -mkdir -p $@
+
+$(TARGETPATH):
+ -mkdir -p $@
+
+$(OBJPATH)/%.opp : $(SRCDIR)/%.cpp
+ $(CXX) -c $(CFLAGS) $(DEFS) $(INCPATH) $< -o $@
+
+$(OBJPATH)/%.o : $(SRCDIR)/%.c
+ $(CC) -c $(CFLAGS) $(DEFS) $(INCPATH) $< -o $@
+
+$(TARGET) :: $(OBJPATH) $(TARGETPATH)
+
+$(TARGET) :: $(COBJS) $(CPPOBJS)
+ $(CXX) $(LDFLAGS) $(LIBPATH) -o $@ $(COBJS) $(CPPOBJS) $(LIBS)
+ chmod 755 $@
+
+##############################################
+
+_clean_:
+ rm $(COBJS) $(CPPOBJS) $(TARGET)
+
+##############################################
+
+$(INSTPATH):
+ -mkdir -p $@
+
+_install_:: $(INSTPATH)
+ install $(TARGET) $(INSTPATH)
diff --git a/externals/grill/flext/buildsys/mac/gnumake-gcc-flext.inc b/externals/grill/flext/buildsys/mac/gnumake-gcc-flext.inc new file mode 100644 index 00000000..1baafe86 --- /dev/null +++ b/externals/grill/flext/buildsys/mac/gnumake-gcc-flext.inc @@ -0,0 +1,64 @@ +# build class specific settings
+ +#LDFLAGS += -dylib_install_name $(FLEXTSHLIB) +
+##############################################
+
+CSRCS=$(patsubst %.c,$(SRCDIR)/%.c,$(filter %.c,$(SRCS)))
+CPPSRCS=$(patsubst %.cpp,$(SRCDIR)/%.cpp,$(filter %.cpp,$(SRCS)))
+COBJS=$(patsubst %.c,$(OBJPATH)/%.o,$(filter %.c,$(SRCS)))
+CPPOBJS=$(patsubst %.cpp,$(OBJPATH)/%.opp,$(filter %.cpp,$(SRCS)))
+
+# default target
+_build_: $(TARGET)
+
+$(CSRCS) $(CPPSRCS): $(patsubst %,$(SRCDIR)/%,$(HDRS))
+ touch $@
+
+$(OBJPATH):
+ -mkdir -p $@
+
+$(TARGETPATH):
+ -mkdir -p $@
+
+$(OBJPATH)/%.opp : $(SRCDIR)/%.cpp
+ $(CXX) -c $(CFLAGS) $(DEFS) $(INCPATH) $< -o $@
+
+$(OBJPATH)/%.o : $(SRCDIR)/%.c
+ $(CC) -c $(CFLAGS) $(DEFS) $(INCPATH) $< -o $@
+
+$(TARGET) :: $(OBJPATH) $(TARGETPATH)
+
+$(TARGET) :: $(COBJS) $(CPPOBJS)
+ifdef SHARED
+ $(CXX) $(LDFLAGS) $(LIBPATH) -o $@ $(COBJS) $(CPPOBJS) $(LIBS)
+ chmod 755 $@
+else + libtool -static -o $@ $(COBJS) $(CPPOBJS)
+endif
+ +##############################################
+
+_clean_:
+ rm $(COBJS) $(CPPOBJS) $(TARGET)
+
+##############################################
+
+ifdef SHARED
+FLEXTLIBINST=$(FLEXTSHLIB)
+else
+FLEXTLIBINST=$(FLEXTLIB)
+endif
+
+$(FLEXTINC):
+ -mkdir -p $@
+
+$(FLEXTLIBINST):
+ -mkdir -p $@
+
+_install_: $(FLEXTINC) $(FLEXTLIBINST)
+ install $(TARGET) $(FLEXTLIBINST) +ifndef SHARED + ranlib $(FLEXTLIBINST)/$(OUTNAME).$(EXT) # have to rerun ranlib at install dir ?! +endif
+ install $(patsubst %,$(SRCDIR)/%,$(HDRS)) $(FLEXTINC)
diff --git a/externals/grill/flext/buildsys/mac/gnumake-gcc.inc b/externals/grill/flext/buildsys/mac/gnumake-gcc.inc new file mode 100644 index 00000000..4567ec41 --- /dev/null +++ b/externals/grill/flext/buildsys/mac/gnumake-gcc.inc @@ -0,0 +1,12 @@ +############################################## + +LDFLAGS += -dynamic -Wl,-x -framework ApplicationServices -framework vecLib + +############################################## + +ifndef DEBUG +CFLAGS += -g -D_DEBUG +else +CFLAGS += $(OFLAGS) -DNDEBUG +LDFLAGS += -Wl,-S +endif diff --git a/externals/grill/flext/buildsys/mac/make-gcc.inc b/externals/grill/flext/buildsys/mac/make-gcc.inc deleted file mode 100644 index a7f6c511..00000000 --- a/externals/grill/flext/buildsys/mac/make-gcc.inc +++ /dev/null @@ -1,102 +0,0 @@ -ifndef FLEXTBUILD -INCPATH += -I$(FLEXTPATH) -LIBPATH += -L$(FLEXTPATH) -LIBS+=$(FLEXTPATH)/$(FLEXTNAME).a -endif - -LDFLAGS += -Wl,-x -framework ApplicationServices -framework vecLib -dynamiclib -dynamic - -############################################## - -ifndef DEBUG -CFLAGS += -g -D_DEBUG -else -CFLAGS += $(OFLAGS) -DNDEBUG -LDFLAGS += -Wl,-S -endif - -############################################## - -ifdef FLEXTBUILD -OUTNAME=$(FLEXTNAME) - -ifdef SHARED -EXT=dylib -else -EXT=a -BUILDLIB=1 -endif - -else -OUTNAME=$(NAME) -endif - -############################################## - -OBJPATH=$(OUTPATH)/$(OUTSUB) - -ifdef FLEXTBUILD -TARGETPATH=$(OBJPATH) -TARGET=$(TARGETPATH)/$(OUTNAME).$(EXT) -else -TARGETPATH=$(OBJPATH)/$(OUTNAME).$(EXT)/Contents/MacOS -TARGET=$(TARGETPATH)/$(OUTNAME) -endif - -############################################## - -CSRCS=$(patsubst %.c,$(SRCDIR)/%.c,$(filter %.c,$(SRCS))) -CPPSRCS=$(patsubst %.cpp,$(SRCDIR)/%.cpp,$(filter %.cpp,$(SRCS))) -COBJS=$(patsubst %.c,$(OBJPATH)/%.o,$(filter %.c,$(SRCS))) -CPPOBJS=$(patsubst %.cpp,$(OBJPATH)/%.opp,$(filter %.cpp,$(SRCS))) - -# default target -_all_: $(TARGET) - -$(CSRCS) $(CPPSRCS): $(patsubst %,$(SRCDIR)/%,$(HDRS)) - touch $@ - -$(OBJPATH): - -mkdir -p $@ - -$(TARGETPATH): - -mkdir -p $@ - -$(OBJPATH)/%.opp : $(SRCDIR)/%.cpp - $(CXX) -c $(CFLAGS) $(DEFS) $(INCPATH) $< -o $@ - -$(OBJPATH)/%.o : $(SRCDIR)/%.c - $(CC) -c $(CFLAGS) $(DEFS) $(INCPATH) $< -o $@ - -$(TARGET) :: $(OBJPATH) $(TARGETPATH) - -$(TARGET) :: $(COBJS) $(CPPOBJS) -ifdef BUILDLIB - libtool -static -o $@ $(COBJS) $(CPPOBJS) -else -# $(CXX) $(LDFLAGS) $(LIBPATH) -dylib_install_name $(INSTPATH)/$(notdir $@) -o $@ $(COBJS) $(CPPOBJS) $(LIBS) - $(CXX) $(LDFLAGS) $(LIBPATH) -o $@ $(COBJS) $(CPPOBJS) $(LIBS) - chmod 755 $@ -endif - -############################################## - -_clean_: - rm $(COBJS) $(CPPOBJS) $(TARGET) - -############################################## - -$(INSTPATH): - -mkdir -p $@ - -$(FLEXTPATH): - -mkdir -p $@ - -_install_:: $(INSTPATH) $(FLEXTPATH) - -_install_:: $(TARGET) -ifdef FLEXTBUILD - cp $(TARGET) $(patsubst %,$(SRCDIR)/%,$(HDRS)) $(FLEXTPATH) -else - install $(TARGET) $(INSTPATH) -endif diff --git a/externals/grill/flext/buildsys/mac/max/config-gcc.def b/externals/grill/flext/buildsys/mac/max/config-gcc.def index b10869b2..41c0b490 100644 --- a/externals/grill/flext/buildsys/mac/max/config-gcc.def +++ b/externals/grill/flext/buildsys/mac/max/config-gcc.def @@ -2,15 +2,27 @@ # you should have the latest version! MAXSDKPATH=/Volumes/Daten/Prog/MaxMSP-SDK/4.5\ headers/c74support -# where should the external be installed? -INSTPATH=/Library/Application\ Support/Cycling\ \'74/externals +############################################################### + +# where do/should the flext headers reside/be built? +FLEXTINC=/usr/local/include/flext + +# where do/should the flext static libraries reside/be built? +FLEXTLIB=/usr/local/lib + +# where do/should the flext shared libraries reside/be built? +FLEXTSHLIB=$(FLEXTLIB) -# where do the flext headers and libraries reside? -FLEXTPATH=/Library/Application\ Support/Cycling\ \'74/flext +############################################################### # where should the external be built? OUTPATH=max-darwin +# where should the external be installed? +INSTPATH=/Library/Application\ Support/Cycling\ \'74/externals + +############################################################### + # user defined compiler flags # (check if they match your system!) OFLAGS=-O2 -mcpu=G4 -malign-natural -maltivec -faltivec diff --git a/externals/grill/flext/buildsys/mac/max/gnumake-gcc-ext.inc b/externals/grill/flext/buildsys/mac/max/gnumake-gcc-ext.inc new file mode 100644 index 00000000..24d90d60 --- /dev/null +++ b/externals/grill/flext/buildsys/mac/max/gnumake-gcc-ext.inc @@ -0,0 +1,8 @@ +EXT=mxo + +############################################## + +OBJPATH=$(OUTPATH)/$(OUTSUB) + +TARGETPATH=$(OBJPATH)/$(OUTNAME).$(EXT)/Contents/MacOS +TARGET=$(TARGETPATH)/$(OUTNAME) diff --git a/externals/grill/flext/buildsys/mac/max/gnumake-gcc-flext.inc b/externals/grill/flext/buildsys/mac/max/gnumake-gcc-flext.inc new file mode 100644 index 00000000..4cb53259 --- /dev/null +++ b/externals/grill/flext/buildsys/mac/max/gnumake-gcc-flext.inc @@ -0,0 +1,12 @@ +ifdef SHARED +EXT=dylib +else +EXT=a +endif + +############################################## + +OBJPATH=$(OUTPATH)/$(OUTSUB) +TARGETPATH=$(OBJPATH) +TARGET=$(TARGETPATH)/$(OUTNAME).$(EXT) + diff --git a/externals/grill/flext/buildsys/mac/max/make-gcc.inc b/externals/grill/flext/buildsys/mac/max/gnumake-gcc.inc index fb5a40ca..cd5740f4 100644 --- a/externals/grill/flext/buildsys/mac/max/make-gcc.inc +++ b/externals/grill/flext/buildsys/mac/max/gnumake-gcc.inc @@ -3,5 +3,5 @@ DEFS += -DFLEXT_SYS=1 INCPATH += -I$(MAXSDKPATH)/max-includes -I$(MAXSDKPATH)/msp-includes LDFLAGS += -framework MaxAPI -framework MaxAudioAPI +LDFLAGS += -dynamiclib -EXT=mxo diff --git a/externals/grill/flext/buildsys/mac/pd/config-gcc.def b/externals/grill/flext/buildsys/mac/pd/config-gcc.def index 9793e4a3..85a9d8bd 100644 --- a/externals/grill/flext/buildsys/mac/pd/config-gcc.def +++ b/externals/grill/flext/buildsys/mac/pd/config-gcc.def @@ -1,18 +1,30 @@ # where is the PD installation including source code? -PDPATH=/Applications/Pd-0.38-0test10.app/Contents/Resources +PDPATH=/Applications/audio/Pd-0.38-0test13.app/Contents/Resources # where is the PD executable? -PDBIN=/usr/local/bin/pd +PDBIN=$(PDPATH)/bin/pd -# where should the external be installed? -INSTPATH=$(PDPATH)/extra +############################################################### + +# where do/should the flext headers reside/be built? +FLEXTINC=/usr/local/include/flext + +# where do/should the flext static libraries reside/be built? +FLEXTLIB=/usr/local/lib + +# where do/should the flext shared libraries reside/be built? +FLEXTSHLIB=$(FLEXTLIB) -# where do the flext headers and libraries reside? -FLEXTPATH=$(PDPATH)/flext +############################################################### # where should the external be built? OUTPATH=pd-darwin +# where should the external be installed? +INSTPATH=$(PDPATH)/extra + +############################################################### + # user defined compiler flags # (check if they match your system!) OFLAGS=-O2 -mcpu=G4 -malign-natural -maltivec -faltivec diff --git a/externals/grill/flext/buildsys/mac/pd/gnumake-gcc-ext.inc b/externals/grill/flext/buildsys/mac/pd/gnumake-gcc-ext.inc new file mode 100644 index 00000000..f52bc6db --- /dev/null +++ b/externals/grill/flext/buildsys/mac/pd/gnumake-gcc-ext.inc @@ -0,0 +1 @@ +EXT=pd_darwin
diff --git a/externals/grill/flext/buildsys/mac/pd/gnumake-gcc-flext.inc b/externals/grill/flext/buildsys/mac/pd/gnumake-gcc-flext.inc new file mode 100644 index 00000000..2ebf308d --- /dev/null +++ b/externals/grill/flext/buildsys/mac/pd/gnumake-gcc-flext.inc @@ -0,0 +1,5 @@ +ifdef SHARED
+EXT=dylib
+else
+EXT=a
+endif
diff --git a/externals/grill/flext/buildsys/mac/pd/gnumake-gcc.inc b/externals/grill/flext/buildsys/mac/pd/gnumake-gcc.inc new file mode 100644 index 00000000..ac805f09 --- /dev/null +++ b/externals/grill/flext/buildsys/mac/pd/gnumake-gcc.inc @@ -0,0 +1,13 @@ +DEFS += -DFLEXT_SYS=2 + +INCPATH += -I$(PDPATH)/src +LIBPATH += -L$(PDPATH)/bin + +LDFLAGS += -bundle -bundle_loader $(PDBIN) + +############################################## + +OBJPATH=$(OUTPATH)/$(OUTSUB) +TARGETPATH=$(OBJPATH) +TARGET=$(TARGETPATH)/$(OUTNAME).$(EXT) + diff --git a/externals/grill/flext/buildsys/mac/pd/make-gcc.inc b/externals/grill/flext/buildsys/mac/pd/make-gcc.inc deleted file mode 100644 index 05c2cd08..00000000 --- a/externals/grill/flext/buildsys/mac/pd/make-gcc.inc +++ /dev/null @@ -1,10 +0,0 @@ -DEFS += -DFLEXT_SYS=2 - -INCPATH += -I$(PDPATH)/src -LIBPATH += -L$(PDPATH)/bin - -LDFLAGS += -bundle -bundle_loader $(PDBIN) - -LIBS += - -EXT=pd_darwin |