Commit aacccb2b authored by thomas's avatar thomas
Browse files

- fix (compiler option -fvisibility-inlines-hidden) for clash of inline functions

- framework for flext namespace (not used yet)


git-svn-id: https://svn.grrrr.org/ext/trunk/flext@3657 4d9ac71a-51e6-0310-8455-cad1006bcd31
parent beca7e39
......@@ -21,7 +21,7 @@ TARGETNAME=$(OUTNAME).$(EXT)
##############################################
CFLAGS += -pthread -fPIC
CFLAGS += -pthread -fPIC -fvisibility-inlines-hidden
LDFLAGS += -pthread -shared
##############################################
......
......@@ -36,7 +36,7 @@ endif
$(PRECOMDST) : $(PRECOMSRC) $(patsubst %,$(SRCDIR)/%,$(HDRS))
-mkdir -p $(dir $@)
$(CXX) -c $(DEFS) $(INCPATH) $(PRECOMSRC) -o $@
$(CXX) -c $(CFLAGS) $(DEFS) $(INCPATH) $(PRECOMSRC) -o $@
ifndef ARCH
......
......@@ -30,6 +30,7 @@ FLEXTBIN := $(FLEXTPREFIX)/bin
##############################################
CFLAGS += -fvisibility-inlines-hidden
LDFLAGS += -dynamic -framework vecLib
##############################################
......
......@@ -2,6 +2,11 @@
# flext - C++ layer for Max/MSP and pd (pure data) externals
#
# Copyright (c) 2001-2008 Thomas Grill (gr@grrrr.org)
#
# $LastChangedRevision: 3651 $
# $LastChangedDate: 2008-12-04 00:57:18 +0100 (Thu, 04 Dec 2008) $
# $LastChangedBy: thomas $
#
# For information on usage and redistribution, and for a DISCLAIMER OF ALL
# WARRANTIES, see the file, "license.txt," in this distribution.
#
......@@ -34,6 +39,7 @@ SRCS= \
flproxy.cpp flqueue.cpp flbind.cpp flmap.cpp
HDRS= \
flext.h flprefix.h flstdc.h flinternal.h flfeatures.h \
flpushns.h flpopns.h \
flbase.h flclass.h flsupport.h fldsp.h \
flmap.h flcontainers.h \
fldefs.h fldefs_hdr.h fldefs_setup.h \
......
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2006 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -18,6 +18,8 @@ $LastChangedBy$
#include "flext.h"
#include <string.h> // for memcpy
#include "flpushns.h"
#if FLEXT_SYS != FLEXT_SYS_JMAX
int flext::CmpAtom(const t_atom &a,const t_atom &b)
{
......@@ -166,3 +168,5 @@ void flext::AtomListStaticBase::Free()
if(lst != predata) AtomList::Free();
else lst = NULL,cnt = 0;
}
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -17,6 +17,8 @@ $LastChangedBy$
#include "flext.h"
#include "flpushns.h"
int flext::AtomList::Get(t_atom *argv,int mxsz) const
{
int argc = Count();
......@@ -38,3 +40,4 @@ void flext::AtomList::GetPart(int offs,int len,AtomList &ret) const
ret(len,Atoms()+offs);
}
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2008 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -21,6 +21,8 @@ $LastChangedBy$
#include <string.h>
#include <stdio.h>
#include "flpushns.h"
#ifdef _MSC_VER
#define snprintf _snprintf
#endif
......@@ -132,3 +134,4 @@ int flext::ScanList(int argc,t_atom *argv,const char *buf)
return read;
}
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -21,6 +21,7 @@ $LastChangedBy$
#include <set>
#include "flpushns.h"
#ifdef __MWERKS__
#define STD std
......@@ -446,3 +447,5 @@ bool flext_base::ShowAttrib(const t_symbol *attr,bool show) const
AttrItem *item = FindAttrib(attr,true);
return item && ShowAttrib(item,show);
}
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -17,6 +17,8 @@ $LastChangedBy$
#include "flext.h"
#include "flpushns.h"
#if FLEXT_SYS == FLEXT_SYS_PD
#ifdef _MSC_VER
......@@ -873,3 +875,6 @@ void flext_base::cb_GfxSave(flext_hdr *c, t_binbuf *b)
#endif // FLEXT_ATTRHIDE
#endif // FLEXT_SYS_PD
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -35,6 +35,7 @@ $LastChangedBy$
#endif
#endif
#include "flpushns.h"
/////////////////////////////////////////////////////////
//
......@@ -207,3 +208,6 @@ void flext_obj::GetCanvasDir(char *buf,size_t bufsz) const
#error Not implemented
#endif
}
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2008 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -23,6 +23,7 @@ $LastChangedBy$
#include "flstdc.h"
#include "flsupport.h"
#include "flpushns.h"
class FLEXT_SHARE FLEXT_CLASSDEF(flext_obj);
typedef class FLEXT_CLASSDEF(flext_obj) flext_obj;
......@@ -373,7 +374,7 @@ static void __setup__(t_classid classid) { \
// specify that to define the library itself
#if FLEXT_SYS == FLEXT_SYS_PD
#define REAL_LIB_SETUP(NAME,SETUPFUN) extern "C" FLEXT_EXT void NAME##_setup() { flext_obj::lib_init(#NAME,SETUPFUN); }
#define REAL_LIB_SETUP(NAME,SETUPFUN) extern "C" FLEXT_EXT void ::NAME##_setup() { flext_obj::lib_init(#NAME,SETUPFUN); }
#elif FLEXT_SYS == FLEXT_SYS_MAX
#define REAL_LIB_SETUP(NAME,SETUPFUN) extern "C" FLEXT_EXT int main() { flext_obj::lib_init(#NAME,SETUPFUN); return 0; }
#else
......@@ -562,5 +563,6 @@ FLEXT_OBJ_SETUP(NEW_CLASS,DSP,LIB)
#define FLEXTARG(TP) FLEXTARG_ ## TP
#include "flpopns.h"
#endif
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -18,6 +18,7 @@ $LastChangedBy$
#include "flext.h"
#include "flinternal.h"
#include "flpushns.h"
t_class *flext_base::pxbnd_class = NULL;
......@@ -262,3 +263,5 @@ void flext_base::pxbnd_object::px_method(pxbnd_object *c,const t_symbol *s,int a
{
c->item->fun(c->base,(t_symbol *)s,argc,(t_atom *)argv,c->data);
}
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2007 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -19,6 +19,8 @@ $LastChangedBy$
#include "flfeatures.h"
#include <set>
#include "flpushns.h"
#if FLEXT_SYS != FLEXT_SYS_JMAX
#if FLEXT_SYS == FLEXT_SYS_PD
......@@ -374,4 +376,5 @@ bool flext::buffer::IsDirty() const
#endif // Jmax
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2008 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -36,6 +36,8 @@ $LastChangedBy$
#endif
#include "flpushns.h"
// === flext_base ==================================================
/*! \brief Flext message only base object
......@@ -1123,4 +1125,6 @@ private:
#endif
};
#include "flpopns.h"
#endif
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2008 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -23,6 +23,8 @@ $LastChangedBy$
#include "lockfree/stack.hpp"
#include "lockfree/fifo.hpp"
#include "flpushns.h"
class LifoCell: public lockfree::stack_node {};
class Lifo
......@@ -168,5 +170,7 @@ private:
size_t sz,resz;
};
#include "flpopns.h"
#endif
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2005 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2006 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -19,6 +19,8 @@ $LastChangedBy$
#include "flinternal.h"
#include <string.h>
#include "flpushns.h"
// === flext_dsp ==============================================
void flext_dsp::Setup(t_classid id)
......@@ -120,3 +122,6 @@ void flext_dsp::CbSignal()
//void flext_dsp::cb_enable(flext_hdr *c,t_float on) { thisObject(c)->dspon = on != 0; }
bool flext_dsp::cb_enable(flext_base *b,float &on) { static_cast<flext_dsp *>(b)->dspon = on != 0; return true; }
#endif
#include "flpopns.h"
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2006 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -22,6 +22,7 @@ $LastChangedBy$
// include the header file declaring the base classes
#include "flext.h"
#include "flpushns.h"
// === flext_dsp ==================================================
......@@ -184,4 +185,6 @@ private:
static t_int *dspmeth(t_int *w);
};
#include "flpopns.h"
#endif
......@@ -2,7 +2,7 @@
flext - C++ layer for Max/MSP and pd (pure data) externals
Copyright (c) 2001-2008 Thomas Grill (gr@grrrr.org)
Copyright (c) 2001-2009 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
......@@ -20,6 +20,8 @@ $LastChangedBy$
#include "fldsp.h"
#include <string.h>
#include "flpushns.h"
// === flext_base ============================================
const t_symbol *flext_base::curtag = NULL;
......@@ -263,3 +265,5 @@ void flext_base::cb_dsp(flext_hdr *c,t_signal **sp)
}
bool flext_base::CbIdle() { return 0; }
#include "flpopns.h"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment