Bugfix #4081: support for OpenBSD platform for scons. Big thanks to Nathan Houghton...
[blender-staging.git] / extern / bullet / Makefile
1 #
2 # $Id$
3 #
4 # ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
5 #
6 # This program is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU General Public License
8 # as published by the Free Software Foundation; either version 2
9 # of the License, or (at your option) any later version. The Blender
10 # Foundation also sells licenses for use in proprietary software under
11 # the Blender License.  See http://www.blender.org/BL/ for information
12 # about this.
13 #
14 # This program is distributed in the hope that it will be useful,
15 # but WITHOUT ANY WARRANTY; without even the implied warranty of
16 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 # GNU General Public License for more details.
18 #
19 # You should have received a copy of the GNU General Public License
20 # along with this program; if not, write to the Free Software Foundation,
21 # Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22 #
23 # The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
24 # All rights reserved.
25 #
26 # The Original Code is: all of this file.
27 #
28 # Contributor(s): none yet.
29 #
30 # ***** END GPL/BL DUAL LICENSE BLOCK *****
31 #
32 #
33
34 include nan_definitions.mk
35
36
37 SOURCEDIR = extern/bullet
38 LIBNAMES = bullet bulletdyn
39 DIR = $(OCGDIR)/$(SOURCEDIR)
40 DIRS = Bullet BulletDynamics
41
42 include nan_subdirs.mk
43
44 install: all debug
45         @[ -d $(NAN_BULLET) ] || mkdir $(NAN_BULLET)
46         @[ -d $(NAN_BULLET)/include ] || mkdir $(NAN_BULLET)/include
47         @[ -d $(NAN_BULLET)/include/CollisionShapes ] || mkdir $(NAN_BULLET)/include/CollisionShapes
48         @[ -d $(NAN_BULLET)/include/BroadphaseCollision ] || mkdir $(NAN_BULLET)/include/BroadphaseCollision
49         @[ -d $(NAN_BULLET)/include/NarrowPhaseCollision ] || mkdir $(NAN_BULLET)/include/NarrowPhaseCollision
50         @[ -d $(NAN_BULLET)/include/Dynamics ] || mkdir $(NAN_BULLET)/include/Dynamics
51         @[ -d $(NAN_BULLET)/include/ConstraintSolver ] || mkdir $(NAN_BULLET)/include/ConstraintSolver
52         @[ -d $(NAN_BULLET)/include/CollisionDispatch ] || mkdir $(NAN_BULLET)/include/CollisionDispatch
53         @[ -d $(NAN_BULLET)/include/Vehicle ] || mkdir $(NAN_BULLET)/include/Vehicle
54         @[ -d $(NAN_BULLET)/lib ] || mkdir $(NAN_BULLET)/lib
55         @[ -d $(NAN_BULLET)/lib/debug ] || mkdir $(NAN_BULLET)/lib/debug
56         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh $(DIR)/Bullet/libbullet.a $(NAN_BULLET)/lib/
57         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh $(DIR)/Bullet/debug/libbullet.a $(NAN_BULLET)/lib/debug/
58         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh $(DIR)/BulletDynamics/libbulletdyn.a $(NAN_BULLET)/lib/
59         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh $(DIR)/BulletDynamics/debug/libbulletdyn.a $(NAN_BULLET)/lib/debug/
60 ifeq ($(OS),darwin)
61         ranlib $(NAN_BULLET)/lib/libbullet.a
62         ranlib $(NAN_BULLET)/lib/debug/libbullet.a
63         ranlib $(NAN_BULLET)/lib/libbulletdyn.a
64         ranlib $(NAN_BULLET)/lib/debug/libbulletdyn.a
65 endif
66         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh Bullet/CollisionShapes/*.h $(NAN_BULLET)/include/CollisionShapes
67         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh Bullet/BroadphaseCollision/*.h $(NAN_BULLET)/include/BroadphaseCollision
68         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh Bullet/NarrowPhaseCollision/*.h $(NAN_BULLET)/include/NarrowPhaseCollision
69         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh Bullet/CollisionDispatch/*.h $(NAN_BULLET)/include/CollisionDispatch
70         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh BulletDynamics/Dynamics/*.h $(NAN_BULLET)/include/Dynamics
71         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh BulletDynamics/ConstraintSolver/*.h $(NAN_BULLET)/include/ConstraintSolver
72         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh BulletDynamics/Vehicle/*.h $(NAN_BULLET)/include/Vehicle
73         @$(NANBLENDERHOME)/intern/tools/cpifdiff.sh LinearMath/*.h $(NAN_BULLET)/include