root / src / spin / Makefile.am @ d409e5a5
History | View | Annotate | Download (9.6 kB)
| 1 |
AM_CPPFLAGS = \ |
|---|---|
| 2 |
$(BOOST_CPPFLAGS) \ |
| 3 |
$(CPPINTROSPECTION_CFLAGS) \ |
| 4 |
$(PYTHON_CPPFLAGS) \ |
| 5 |
$(LIBLO_CFLAGS) \ |
| 6 |
$(OPENTHREADS_CFLAGS) \ |
| 7 |
$(OSG_CFLAGS) \ |
| 8 |
$(SHAREDVIDEO_CFLAGS) \ |
| 9 |
$(SPATOSC_CFLAGS) \ |
| 10 |
-I$(top_srcdir)/include \ |
| 11 |
-I$(top_srcdir)/src/tinyxml |
| 12 |
|
| 13 |
#AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/src/tinyxml -I/opt/local/Library/Frameworks/Python.framework/Versions/2.6/include/python2.6 -isysroot / -fno-strict-aliasing -fno-common -dynamic -DNDEBUG -fwrapv -O3 -Wall |
| 14 |
|
| 15 |
# use lib_LTLIBRARIES to build a shared lib: |
| 16 |
lib_LTLIBRARIES = libspin_@SPIN_API_VERSION@.la |
| 17 |
python_LTLIBRARIES = libpyspin.la |
| 18 |
|
| 19 |
libpyspin_@SPIN_API_VERSION@_la_LIBADD = \ |
| 20 |
$(top_builddir)/src/osgWrappers/introspection/libSPINwrappers.la \ |
| 21 |
$(top_builddir)/src/tinyxml/libtinyxml.la |
| 22 |
|
| 23 |
libpyspin_@SPIN_API_VERSION@_la_LDFLAGS = \ |
| 24 |
-export-dynamic \ |
| 25 |
-version-info $(SPIN_LT_VERSION) \ |
| 26 |
$(BOOST_SYSTEM_LIBS) \ |
| 27 |
$(BOOST_FILESYSTEM_LIBS) \ |
| 28 |
$(BOOST_PROGRAM_OPTIONS_LIBS) \ |
| 29 |
$(BOOST_PYTHON_LIBS) \ |
| 30 |
$(BOOST_LDFLAGS) \ |
| 31 |
$(CPPINTROSPECTION_LIBS) \ |
| 32 |
$(PYTHON_LDFLAGS) \ |
| 33 |
$(BOOST_THREADS_LIBS) \ |
| 34 |
$(LIBLO_LIBS) \ |
| 35 |
$(OPENTHREADS_LIBS) \ |
| 36 |
$(OSG_LIBS) \ |
| 37 |
$(SHAREDVIDEO_LIBS) \ |
| 38 |
$(SPATOSC_LIBS) |
| 39 |
|
| 40 |
# please keep those in alphabetical order: |
| 41 |
libpyspin_@SPIN_API_VERSION@_la_SOURCES = \ |
| 42 |
AttractorNode.cpp \ |
| 43 |
ConstraintsNode.cpp \ |
| 44 |
DSPNode.cpp \ |
| 45 |
EventHandler.cpp \ |
| 46 |
Fog.cpp \ |
| 47 |
GeometryNode.cpp \ |
| 48 |
GridNode.cpp \ |
| 49 |
ReferencedNode.cpp \ |
| 50 |
SceneManager.cpp \ |
| 51 |
UserNode.cpp \ |
| 52 |
osgUtil.cpp \ |
| 53 |
spinApp.cpp \ |
| 54 |
AnimationNode.cpp \ |
| 55 |
Contour.cpp \ |
| 56 |
GroupNode.cpp \ |
| 57 |
ImageTexture.cpp \ |
| 58 |
LightSource.cpp \ |
| 59 |
Listener.cpp \ |
| 60 |
MeasurementNode.cpp \ |
| 61 |
MediaManager.cpp \ |
| 62 |
Menu3D.cpp \ |
| 63 |
ModelNode.cpp \ |
| 64 |
PointerNode.cpp \ |
| 65 |
RayNode.cpp \ |
| 66 |
ReferencedStateSet.cpp \ |
| 67 |
ReporterNode.cpp \ |
| 68 |
ShapeNode.cpp \ |
| 69 |
SharedVideoTexture.cpp \ |
| 70 |
SoundConnection.cpp \ |
| 71 |
SoundNode.cpp \ |
| 72 |
SoundSpace.cpp \ |
| 73 |
SwitchNode.cpp \ |
| 74 |
TextNode.cpp \ |
| 75 |
VideoTexture.cpp \ |
| 76 |
ViewerManipulator.cpp \ |
| 77 |
libloUtil.cpp \ |
| 78 |
nodeVisitors.cpp \ |
| 79 |
spinBaseContext.cpp \ |
| 80 |
spinClientContext.cpp \ |
| 81 |
spinServerContext.cpp \ |
| 82 |
spinUtil.cpp \ |
| 83 |
introspect_helpers.cpp |
| 84 |
|
| 85 |
libpyspin_@SPIN_API_VERSION@_la_includedir = $(includedir)/spin-$(SPIN_API_VERSION)/spin |
| 86 |
libpyspin_@SPIN_API_VERSION@_la_include_HEADERS = \ |
| 87 |
$(top_srcdir)/include/AnimationNode.h \ |
| 88 |
$(top_srcdir)/include/AttractorNode.h \ |
| 89 |
$(top_srcdir)/include/config.h \ |
| 90 |
$(top_srcdir)/include/ConstraintsNode.h \ |
| 91 |
$(top_srcdir)/include/Contour.h \ |
| 92 |
$(top_srcdir)/include/DSPNode.h \ |
| 93 |
$(top_srcdir)/include/EventHandler.h \ |
| 94 |
$(top_srcdir)/include/EventTypes.h \ |
| 95 |
$(top_srcdir)/include/Fog.h \ |
| 96 |
$(top_srcdir)/include/GeometryNode.h \ |
| 97 |
$(top_srcdir)/include/GridNode.h \ |
| 98 |
$(top_srcdir)/include/GroupNode.h \ |
| 99 |
$(top_srcdir)/include/ImageTexture.h \ |
| 100 |
$(top_srcdir)/include/introspect_helpers.h \ |
| 101 |
$(top_srcdir)/include/libloUtil.h \ |
| 102 |
$(top_srcdir)/include/LightSource.h \ |
| 103 |
$(top_srcdir)/include/Listener.h \ |
| 104 |
$(top_srcdir)/include/mainpage.h \ |
| 105 |
$(top_srcdir)/include/MeasurementNode.h \ |
| 106 |
$(top_srcdir)/include/MediaManager.h \ |
| 107 |
$(top_srcdir)/include/Menu3D.h \ |
| 108 |
$(top_srcdir)/include/ModelNode.h \ |
| 109 |
$(top_srcdir)/include/nodeVisitors.h \ |
| 110 |
$(top_srcdir)/include/oscParser.h \ |
| 111 |
$(top_srcdir)/include/osgUtil.h \ |
| 112 |
$(top_srcdir)/include/PointerNode.h \ |
| 113 |
$(top_srcdir)/include/RayNode.h \ |
| 114 |
$(top_srcdir)/include/ReferencedNode.h \ |
| 115 |
$(top_srcdir)/include/ReferencedStateSet.h \ |
| 116 |
$(top_srcdir)/include/ReporterNode.h \ |
| 117 |
$(top_srcdir)/include/SceneManager.h \ |
| 118 |
$(top_srcdir)/include/ShapeNode.h \ |
| 119 |
$(top_srcdir)/include/SharedVideoTexture.h \ |
| 120 |
$(top_srcdir)/include/SoundConnection.h \ |
| 121 |
$(top_srcdir)/include/SoundNode.h \ |
| 122 |
$(top_srcdir)/include/SoundSpace.h \ |
| 123 |
$(top_srcdir)/include/spinApp.h \ |
| 124 |
$(top_srcdir)/include/spinBaseContext.h \ |
| 125 |
$(top_srcdir)/include/spinClientContext.h \ |
| 126 |
$(top_srcdir)/include/spinDefaults.h \ |
| 127 |
$(top_srcdir)/include/spinLog.h \ |
| 128 |
$(top_srcdir)/include/spinLogWX.h \ |
| 129 |
$(top_srcdir)/include/spinServerContext.h \ |
| 130 |
$(top_srcdir)/include/spinUtil.h \ |
| 131 |
$(top_srcdir)/include/spinWX.h \ |
| 132 |
$(top_srcdir)/include/SwitchNode.h \ |
| 133 |
$(top_srcdir)/include/TextNode.h \ |
| 134 |
$(top_srcdir)/include/UserNode.h \ |
| 135 |
$(top_srcdir)/include/VideoTexture.h \ |
| 136 |
$(top_srcdir)/include/ViewerManipulator.h \ |
| 137 |
$(top_srcdir)/src/tinyxml/tinystr.h \ |
| 138 |
$(top_srcdir)/src/tinyxml/tinyxml.h |
| 139 |
|
| 140 |
# $(top_srcdir)/include/videoSize.h |
| 141 |
|
| 142 |
pyspin_la_SOURCES = python_wrappers.cpp |
| 143 |
#pyspin_la_LDFLAGS = -shrext ".so" # python expects .so on OSX |
| 144 |
pyspin_la_LIBADD = libspin_@SPIN_API_VERSION@.la \ |
| 145 |
$(top_builddir)/src/osgWrappers/introspection/libSPINwrappers.la |
| 146 |
|
| 147 |
spindir = `python -c 'from distutils import sysconfig; sysconfig.get_python_lib(plat_specific=True, standard_lib=False, prefix="@PYTHON_PREFIX@")'` |
| 148 |
# `python -c 'from distutils import sysconfig; print sysconfig.get_python_lib(1,0,"${exec_prefix}")'`
|
| 149 |
|
| 150 |
# On OSX, we need the python module to have a .so extension, but the |
| 151 |
# -shrext option doesn't work with glibtool, so we make a symbolic link |
| 152 |
# in an install hook instead. |
| 153 |
# On Linux, this will fail because the .dylip doesn't exist. Is there |
| 154 |
# any way we can do this only for OSX? |
| 155 |
|
| 156 |
install-exec-hook: |
| 157 |
cd $(spindir) && $(LN_S) -f spin.dylib spin.so |
| 158 |
|
| 159 |
#$(LN_S) prog-$(VERSION)$(EXEEXT) prog$(EXEEXT) |
| 160 |
|
| 161 |
bin_PROGRAMS = spinserver spinviewer spindocgenerator |
| 162 |
|
| 163 |
spinserver_SOURCES = spinServer.cpp |
| 164 |
spinserver_LDADD = libspin_@SPIN_API_VERSION@.la $(OPENTHREADS_LIBS) $(OSG_LIBS) $(CPPINTROSPECTION_LIBS) $(PYTHON_LDFLAGS) $(LIBLO_LIBS) $(BOOST_PROGRAM_OPTIONS_LIBS) $(BOOST_FILESYSTEM_LIBS) |
| 165 |
|
| 166 |
spinviewer_SOURCES = spinViewer.cpp |
| 167 |
spinviewer_LDADD = libspin_@SPIN_API_VERSION@.la $(OPENTHREADS_LIBS) $(OSG_LIBS) $(CPPINTROSPECTION_LIBS) $(PYTHON_LDFLAGS) $(LIBLO_LIBS) $(BOOST_PROGRAM_OPTIONS_LIBS) $(BOOST_FILESYSTEM_LIBS) |
| 168 |
|
| 169 |
spindocgenerator_SOURCES = docGenerator.cpp |
| 170 |
spindocgenerator_LDADD = libspin_@SPIN_API_VERSION@.la $(OPENTHREADS_LIBS) $(OSG_LIBS) $(CPPINTROSPECTION_LIBS) $(PYTHON_LDFLAGS) $(LIBLO_LIBS) $(BOOST_PROGRAM_OPTIONS_LIBS) $(BOOST_FILESYSTEM_LIBS) |
| 171 |
|
| 172 |
############################################################################### |
| 173 |
# CUSTOM targets: |
| 174 |
|
| 175 |
#OSG_VER = $(shell osgversion --so-number) |
| 176 |
#OPENTHREADS_VER= $(shell osgversion --openthreads-soversion-number) |
| 177 |
|
| 178 |
#OSX_OSG_LIBS = osg osgGA osgSim osgDB osgManipulator osgText osgUtil osgFX osgParticle osgViewer cppintrospection |
| 179 |
|
| 180 |
# WARNING: the .app generation script pulls some libs (eg, libspin_@SPIN_API_VERSION@) from /usr/local |
| 181 |
# so you must do a 'make install' before this will work (TODO: fix this) |
| 182 |
|
| 183 |
spinviewer.app: spinviewer$(EXEEXT) |
| 184 |
@echo "\n--------------- Building $@: ---------------" |
| 185 |
-mkdir $@ |
| 186 |
-mkdir $@/Contents |
| 187 |
-mkdir $@/Contents/Frameworks |
| 188 |
-mkdir $@/Contents/libs |
| 189 |
-mkdir $@/Contents/MacOS |
| 190 |
-mkdir $@/Contents/Resources |
| 191 |
-mkdir $@/Contents/Resources/fonts |
| 192 |
-mkdir $@/Contents/Resources/images |
| 193 |
-mkdir $@/Contents/Resources/scripts |
| 194 |
-mkdir $@/Contents/Resources/English.lproj |
| 195 |
sed -e "s/IDENTIFIER/`echo ./ | sed -e 's,\.\./,,g' | sed -e 's,/,.,g'`/" \ |
| 196 |
-e "s/EXECUTABLE/$</" \ |
| 197 |
-e "s/VERSION/$(VERSION)/" \ |
| 198 |
spinviewer.plist.in >$@/Contents/Info.plist |
| 199 |
echo -n 'APPL????' > $@/Contents/PkgInfo |
| 200 |
cp /usr/local/bin/spinviewer $@/Contents/MacOS |
| 201 |
../../util/dylibbundler/dylibbundler -of -b -x $@/Contents/MacOS/spinviewer -d $@/Contents/libs |
| 202 |
|
| 203 |
# cp ../Resources/fonts/*.ttf $@/Contents/Resources/fonts |
| 204 |
# cp ../Resources/images/*.icns ../Resources/images/*.xpm ../Resources/images/*.gif ../Resources/images/*.png $@/Contents/Resources/images |
| 205 |
# cp ../Resources/scripts/*.py $@/Contents/Resources/scripts |
| 206 |
|
| 207 |
#cp .libs/spinviewer $@/Contents/MacOS |
| 208 |
|
| 209 |
# install_name_tool -change libOpenThreads.$(OPENTHREADS_VER).dylib /usr/local/lib/libOpenThreads.$(OPENTHREADS_VER).dylib $@/Contents/MacOS/spinviewer |
| 210 |
#-cp -R /usr/local/lib/osgPlugins-* $@/Contents/libs |
| 211 |
#-cp /usr/local/lib/libosg*.dylib $@/Contents/libs |
| 212 |
#-cp /usr/local/lib/libOpenThreads.*.dylib $@/Contents/libs |
| 213 |
|
| 214 |
#install_name_tool -change libosg.55.dylib @executable_path/../libs/libosg.55.dylib $@/Contents/MacOS/spinviewer |
| 215 |
#install_name_tool -change libosgGA.55.dylib @executable_path/../libs/libosgGA.55.dylib $@/Contents/MacOS/spinviewer |
| 216 |
#install_name_tool -change libosgSim.55.dylib @executable_path/../libs/libosgSim.55.dylib $@/Contents/MacOS/spinviewer |
| 217 |
#install_name_tool -change libosgDB.55.dylib @executable_path/../libs/libosgDB.55.dylib $@/Contents/MacOS/spinviewer |
| 218 |
#install_name_tool -change libosgManipulator.55.dylib @executable_path/../libs/libosgManipulator.55.dylib $@/Contents/MacOS/spinviewer |
| 219 |
#install_name_tool -change libosgText.55.dylib @executable_path/../libs/libosgText.55.dylib $@/Contents/MacOS/spinviewer |
| 220 |
#install_name_tool -change libosgUtil.55.dylib @executable_path/../libs/libosgUtil.55.dylib $@/Contents/MacOS/spinviewer |
| 221 |
#install_name_tool -change libosgFX.55.dylib @executable_path/../libs/libosgFX.55.dylib $@/Contents/MacOS/spinviewer |
| 222 |
#install_name_tool -change libosgParticle.55.dylib @executable_path/../libs/libosgParticle.55.dylib $@/Contents/MacOS/spinviewer |
| 223 |
#install_name_tool -change libosgViewer.55.dylib @executable_path/../libs/libosgViewer.55.dylib $@/Contents/MacOS/spinviewer |
| 224 |
#install_name_tool -change libcppintrospection.55.dylib @executable_path/../libs/libcppintrospection.55.dylib $@/Contents/MacOS/spinviewer |
| 225 |
|
| 226 |
#install_name_tool -change libSPIN.dylib @executable_path/../libs/libSPIN.dylib $@/Contents/MacOS/spinviewer |
| 227 |
#-cp -R /Library/Frameworks/osg* $@/Contents/Frameworks |
| 228 |
#-cp -R /Library/Frameworks/OpenThreads.framework $@/Contents/Frameworks |
| 229 |
#-cp -R /Library/Application\ Support/OpenSceneGraph/PlugIns $@/Contents |
| 230 |
|
| 231 |
doc: |
| 232 |
./spindocgenerator |
| 233 |
-cp *.html ../../doxygen/html |
| 234 |
|
