devel.mk 16.5 KB
Newer Older
Florent Lamiraux's avatar
Florent Lamiraux committed
1
2
3
4
5
6
#
# Copyright (c) 2014 CNRS-LAAS
# Author: Florent Lamiraux
#

FCL_REPO=https://github.com/flexible-collision-library
Florent Lamiraux's avatar
Florent Lamiraux committed
7
8
LAAS_REPO=https://github.com/laas
HPP_REPO=https://github.com/humanoid-path-planner
9
SOT_REPO=https://github.com/stack-of-tasks
10
GEPETTO_REPO=https://github.com/Gepetto
11
TRAC_REPO=ssh://trac.laas.fr/git/jrl/robots/ros-hrp2
12
LOCO3D_REPO=https://github.com/loco-3d
Florent Lamiraux's avatar
Florent Lamiraux committed
13

14
15
16
17
SRC_DIR=${DEVEL_HPP_DIR}/src
ifndef INSTALL_HPP_DIR
INSTALL_HPP_DIR=${DEVEL_HPP_DIR}/install
endif
18

Florent Lamiraux's avatar
Florent Lamiraux committed
19
# Whether to compute humanoid specific part
20
HUMANOID?=TRUE
Florent Lamiraux's avatar
Florent Lamiraux committed
21

22
23
BUILD_TYPE?=Release
BUILD_TESTING?=ON
24
25
26
27
ifeq (${BUILD_TYPE},Debug)
  BUILD_FOLDER=build
else
  BUILD_FOLDER=build-rel
28
  BUILD_TESTING=OFF
29
endif
Florent Lamiraux's avatar
Florent Lamiraux committed
30

Joseph Mirabel's avatar
Joseph Mirabel committed
31
OSG_PACKAGE=osg-dae
32
#OSG_PACKAGE=OpenSceneGraph-3.4.0
33

Florent Lamiraux's avatar
Florent Lamiraux committed
34
35
36
37
WGET=wget --quiet
UNZIP=unzip -qq
TAR=tar
GIT_QUIET=--quiet
38
39
# Qt version should be either 4 or 5
QT_VERSION=4
40
INSTALL_DOCUMENTATION=ON
Florent Lamiraux's avatar
Florent Lamiraux committed
41

42
43
44
##################################
# {{{ Dependencies

45
pinocchio_branch=v2.4.7
46
pinocchio_repository=${SOT_REPO}
Guilhem Saurel's avatar
Guilhem Saurel committed
47
pinocchio_extra_flags= -DBUILD_PYTHON_INTERFACE=OFF -DBUILD_UNIT_TESTS=OFF -DBUILD_WITH_COLLISION_SUPPORT=ON
Florent Lamiraux's avatar
Florent Lamiraux committed
48

49
hpp-template-corba_branch=devel
50
hpp-template-corba_repository=${HPP_REPO}
51

52
53
54
# }}}
##################################
# {{{ Packages supporting HPP_VERSION
55

56
# Either a version tag (e.g. v4.3.0), master or devel
57
HPP_VERSION=devel
58
HPP_EXTRA_FLAGS= -DBUILD_TESTING=${BUILD_TESTING}$
59

60
hpp-util_branch=${HPP_VERSION}
Florent Lamiraux's avatar
Florent Lamiraux committed
61
62
hpp-util_repository=${HPP_REPO}

63
hpp-fcl_branch=${HPP_VERSION}
64
hpp-fcl_repository=${HPP_REPO}
65
hpp-fcl_extra_flags= -DCMAKE_BUILD_TYPE=Release -DBUILD_PYTHON_INTERFACE=OFF
66

67
hpp-statistics_branch=${HPP_VERSION}
68
hpp-statistics_repository=${HPP_REPO}
69

70
hpp-pinocchio_branch=${HPP_VERSION}
71
hpp-pinocchio_repository=${HPP_REPO}
72
hpp-pinocchio_extra_flags=${HPP_EXTRA_FLAGS}
73

74
hpp-constraints_branch=${HPP_VERSION}
75
hpp-constraints_repository=${HPP_REPO}
76
hpp-constraints_extra_flags=${HPP_EXTRA_FLAGS} -DUSE_QPOASES=OFF
77

78
hpp-core_branch=${HPP_VERSION}
79
hpp-core_repository=${HPP_REPO}
80
hpp-core_extra_flags=${HPP_EXTRA_FLAGS}
Florent Lamiraux's avatar
Florent Lamiraux committed
81

82
hpp-corbaserver_branch=${HPP_VERSION}
83
hpp-corbaserver_repository=${HPP_REPO}
Florent Lamiraux's avatar
Florent Lamiraux committed
84

85
hpp-walkgen_branch=${HPP_VERSION}
Joseph Mirabel's avatar
Joseph Mirabel committed
86
87
hpp-walkgen_repository=${HPP_REPO}

88
hpp-wholebody-step_branch=${HPP_VERSION}
Florent Lamiraux's avatar
Florent Lamiraux committed
89
hpp-wholebody-step_repository=${HPP_REPO}
90
hpp-wholebody-step_extra_flags= -DRUN_TESTS=OFF
Florent Lamiraux's avatar
Florent Lamiraux committed
91

92
hpp-doc_branch=${HPP_VERSION}
93
hpp-doc_repository=${HPP_REPO}
Florent Lamiraux's avatar
Florent Lamiraux committed
94

95
hpp-manipulation_branch=${HPP_VERSION}
96
hpp-manipulation_repository=${HPP_REPO}
97

98
hpp-manipulation-urdf_branch=${HPP_VERSION}
99
hpp-manipulation-urdf_repository=${HPP_REPO}
Florent Lamiraux's avatar
Florent Lamiraux committed
100

101
hpp-manipulation-corba_branch=${HPP_VERSION}
102
hpp-manipulation-corba_repository=${HPP_REPO}
103

104
105
106
107
108
ifeq (${HUMANOID}, TRUE)
  hpp-manipulation_extra_flags=-DHPP_MANIPULATION_HAS_WHOLEBODY_STEP=TRUE
else
  hpp-manipulation_extra_flags=-DHPP_MANIPULATION_HAS_WHOLEBODY_STEP=FALSE
endif
109

110
hpp_tutorial_branch=${HPP_VERSION}
111
hpp_tutorial_repository=${HPP_REPO}
112

113
hpp-gepetto-viewer_branch=${HPP_VERSION}
114
hpp-gepetto-viewer_repository=${HPP_REPO}
Florent Lamiraux's avatar
Florent Lamiraux committed
115

116
hpp-plot_branch=${HPP_VERSION}
117
hpp-plot_repository=${HPP_REPO}
118

119
hpp-gui_branch=${HPP_VERSION}
120
hpp-gui_repository=${HPP_REPO}
121

122
123
124
# }}}
##################################
# {{{ Robot specific package + test packages
125

126
example-robot-data_branch=devel
127
example-robot-data_repository=${GEPETTO_REPO}
128
example-robot-data_extra_flags= -DBUILD_PYTHON_INTERFACE=OFF
129

Florent Lamiraux's avatar
Florent Lamiraux committed
130
hrp2-14-description_branch=master
131
hrp2-14-description_repository=${TRAC_REPO}
132

133
hpp-hrp2_branch=devel
134
hpp-hrp2_repository=${HPP_REPO}
Florent Lamiraux's avatar
Florent Lamiraux committed
135

136
137
robot_capsule_urdf_branch=groovy
robot_capsule_urdf_repository=${LAAS_REPO}
138

139
140
robot_model_py_branch=groovy
robot_model_py_repository=${LAAS_REPO}
141

142
iai_maps_branch=devel
143
144
iai_maps_repository=${HPP_REPO}

145
hpp_benchmark_branch=devel
146
hpp_benchmark_repository=${HPP_REPO}
147

148
hpp-environments_branch=${HPP_VERSION}
149
150
hpp-environments_repository=${HPP_REPO}

151
universal_robot_branch=kinetic
Florent Lamiraux's avatar
Florent Lamiraux committed
152
153
universal_robot_repository=${HPP_REPO}

154
hpp-universal-robot_branch=${HPP_VERSION}
Guilhem Saurel's avatar
Guilhem Saurel committed
155
hpp-universal-robot_repository=${HPP_REPO}
Florent Lamiraux's avatar
Florent Lamiraux committed
156

157
hpp-baxter_branch=${HPP_VERSION}
158
159
hpp-baxter_repository=${HPP_REPO}

160
hpp_romeo_branch=${HPP_VERSION}
Florent Lamiraux's avatar
Florent Lamiraux committed
161
hpp_romeo_repository=${HPP_REPO}
162

163
164
165
166
167

# }}}
##################################
# {{{ Packages for rbprm

168
hpp-affordance_branch=${HPP_VERSION}
169
170
171
hpp-affordance_repository=${HPP_REPO}
hpp-affordance_extra_flags=${HPP_EXTRA_FLAGS}

172
hpp-affordance-corba_branch=${HPP_VERSION}
173
174
175
hpp-affordance-corba_repository=${HPP_REPO}
hpp-affordance-corba_extra_flags=${HPP_EXTRA_FLAGS}

176
talos-rbprm_branch=${HPP_VERSION}
177
178
talos-rbprm_repository=${HPP_REPO}

179
hpp-rbprm_branch=${HPP_VERSION}
180
181
182
hpp-rbprm_repository=${HPP_REPO}
hpp-rbprm_extra_flags=${HPP_EXTRA_FLAGS}

183
hpp-rbprm-robot-data_branch=${HPP_VERSION}
184
185
hpp-rbprm-robot-data_repository=${HPP_REPO}

186
hpp-rbprm-corba_branch=${HPP_VERSION}
187
188
189
hpp-rbprm-corba_repository=${HPP_REPO}
hpp-rbprm-corba_extra_flags=${HPP_EXTRA_FLAGS}

190
hpp-centroidal-dynamics_branch=${HPP_VERSION}
191
192
hpp-centroidal-dynamics_repository=${HPP_REPO}

193
hpp-bezier-com-traj_branch=${HPP_VERSION}
194
195
196
hpp-bezier-com-traj_repository=${HPP_REPO}
hpp-bezier-com-traj_extra_flags= -DBUILD_PYTHON_INTERFACE=ON

197
curves_branch=${HPP_VERSION}
198
199
curves_repository=${LOCO3D_REPO}
curves_extra_flags= -DBUILD_PYTHON_INTERFACE=ON
200

201
eigenpy_branch=v2.3.2
202
203
eigenpy_repository=${SOT_REPO}

204
205
206
207
208
209
210
211
212
213
# }}}
##################################
# {{{ Packages for gepetto-gui

collada-dom_branch=master
collada-dom_repository=${HPP_REPO}
collada-dom_extra_flags=-DBUILD_SHARED_LIBS=TRUE -DOPT_COLLADA15=FALSE

osg-dae_branch=master
osg-dae_repository=${GEPETTO_REPO}
Joseph Mirabel's avatar
Joseph Mirabel committed
214
osg-dae_extra_flags= -DCOLLADA_DYNAMIC_LIBRARY=${INSTALL_HPP_DIR}/lib/libcollada14dom.so -DCOLLADA_INCLUDE_DIR=${INSTALL_HPP_DIR}/include/collada-dom
215
OpenSceneGraph-3.4.0_extra_flags= -DDESIRED_QT_VERSION=${QT_VERSION} -DCOLLADA_DYNAMIC_LIBRARY=${INSTALL_HPP_DIR}/lib/libcollada14dom.so -DCOLLADA_INCLUDE_DIR=${INSTALL_HPP_DIR}/include/collada-dom -DLIB_POSTFIX=""
216

217
gepetto-viewer_branch=${HPP_VERSION}
218
gepetto-viewer_repository=${GEPETTO_REPO}
219
ifeq (${QT_VERSION}, 5)
220
	gepetto-viewer_extra_flags= -DPROJECT_USE_QT4=OFF
221
else
222
	gepetto-viewer_extra_flags= -DPROJECT_USE_QT4=ON
223
endif
Florent Lamiraux's avatar
Florent Lamiraux committed
224

225
gepetto-viewer-corba_branch=${HPP_VERSION}
Guilhem Saurel's avatar
Guilhem Saurel committed
226
227
gepetto-viewer-corba_repository=${GEPETTO_REPO}

228
pythonqt_branch=qt${QT_VERSION}
229
pythonqt_repository=${GEPETTO_REPO}
230
231
pythonqt_extra_flags= -DPythonQt_Wrap_QtAll=ON -DPythonQt_Extensions=ON

232
qgv_branch=devel
233
qgv_repository=${HPP_REPO}
Joseph Mirabel's avatar
Joseph Mirabel committed
234
235
236
237
238
ifeq (${QT_VERSION}, 5)
	qgv_extra_flags=-DBINDINGS_QT5=ON -DBINDINGS_QT4=OFF
else
	qgv_extra_flags=-DBINDINGS_QT5=OFF -DBINDINGS_QT4=ON
endif
239

240
hpp-tools_branch=${HPP_VERSION}
241
hpp-tools_repository=${HPP_REPO}
242
hpp-tools_extra_flags=
243

244
245
246
247
# }}}
##################################
# {{{ High-level targets

248
all: hpp_tutorial.install hpp-gepetto-viewer.install hpp-plot.install hpp-gui.install
249
	${MAKE} hpp-doc.install
Florent Lamiraux's avatar
Florent Lamiraux committed
250

251
# For test on gepgitlab, install robot packages first
252
253
test-ci: example-robot-data.install  hpp-environments.install \
	hpp-baxter.install
254
	${MAKE} hpp_tutorial.install hpp-gepetto-viewer.install hpp-rbprm-corba.install \
Guilhem Saurel's avatar
Guilhem Saurel committed
255
	hpp-universal-robot.install && \
256
257
258
	${MAKE} hpp-doc.install

# For benchmark, install robot packages first
259
benchmark: example-robot-data.install \
260
	hpp-environments.install hrp2-14-description.install
261
	${MAKE} hpp_tutorial.install hpp-gepetto-viewer.install; \
262
	${MAKE} hpp-baxter.install hpp_romeo.install \
Guilhem Saurel's avatar
Guilhem Saurel committed
263
	hpp-universal-robot.install hpp-plot.install hpp-gui.install; \
264
	${MAKE} hpp_benchmark.checkout; \
265
	${MAKE} hpp-doc.install
266

267
268
269
270
rbprm: hpp-rbprm-corba.install hpp-gepetto-viewer.install
	${MAKE} hpp-doc.install


271
272
273
274
# }}}
##################################
# {{{ Dependencies declaration

275
hpp-doc.configure.dep: hpp-doc.checkout
276
hpp-fcl.configure.dep: hpp-fcl.checkout
Joseph Mirabel's avatar
Joseph Mirabel committed
277
hpp-walkgen.configure.dep: hpp-util.install hpp-core.install \
278
	hpp-walkgen.checkout
279
280
hpp-util.configure.dep: hpp-util.checkout
hpp-model-urdf.configure.dep: hpp-model.install hpp-model-urdf.checkout
281
pinocchio.configure.dep: hpp-fcl.install pinocchio.checkout
282
283
hpp-pinocchio.configure.dep: pinocchio.install hpp-util.install \
	hpp-pinocchio.checkout
Florent Lamiraux's avatar
Florent Lamiraux committed
284
hpp-statistics.configure.dep: hpp-util.install hpp-statistics.checkout
285
286
hpp-core.configure.dep: example-robot-data.install hpp-constraints.install \
	hpp-statistics.install hpp-core.checkout
Guilhem Saurel's avatar
Guilhem Saurel committed
287
hpp-constraints.configure.dep: hpp-pinocchio.install hpp-statistics.install \
288
	hpp-constraints.checkout
Joseph Mirabel's avatar
Joseph Mirabel committed
289
hpp-wholebody-step.configure.dep: hpp-constraints.install hpp-walkgen.install \
290
	hpp-wholebody-step.checkout
291
292
293
294
ifeq (${HUMANOID}, TRUE)
hpp-manipulation.configure.dep: hpp-core.install hpp-constraints.install \
	hpp-wholebody-step.install hpp-manipulation.checkout
hpp-manipulation-corba.configure.dep: hpp-manipulation-urdf.install \
295
	hpp-corbaserver.install hpp-manipulation-corba.checkout
Florent Lamiraux's avatar
Florent Lamiraux committed
296
hpp-plot.configure.dep: hpp-corbaserver.install hpp-manipulation-corba.install \
297
	qgv.install hpp-plot.checkout
298
else
299
hpp-manipulation.configure.dep: hpp-core.install hpp-constraints.install \
Florent Lamiraux's avatar
Florent Lamiraux committed
300
	hpp-manipulation.checkout
301
hpp-manipulation-corba.configure.dep: hpp-manipulation-urdf.install \
302
303
	hpp-manipulation.install hpp-corbaserver.install \
	hpp-template-corba.install hpp-manipulation-corba.checkout
Florent Lamiraux's avatar
Florent Lamiraux committed
304
305
hpp-plot.configure.dep: hpp-corbaserver.install hpp-manipulation-corba.install \
	qgv.install hpp-plot.checkout
306
endif
307
hpp-manipulation-urdf.configure.dep:hpp-manipulation.install \
308
	hpp-manipulation-urdf.checkout
309
hpp-corbaserver.configure.dep: hpp-core.install hpp-template-corba.install \
310
311
	hpp-constraints.install hpp-corbaserver.checkout
hpp-template-corba.configure.dep: hpp-util.install hpp-template-corba.checkout
Florent Lamiraux's avatar
Florent Lamiraux committed
312
313
qgv.configure.dep: qgv.checkout
pythonqt.configure.dep: pythonqt.checkout
314
315
316
robot_model_py.configure.dep: robot_model_py.checkout
robot_capsule_urdf.configure.dep: robot_model_py.install \
	robot_capsule_urdf.checkout
317
318
319
320
hpp-hrp2.configure.dep: hrp2-14-description.install hpp-corbaserver.install \
	hpp-hrp2.checkout
hrp2-14-description.configure.dep: robot_capsule_urdf.install \
	robot_model_py.install hrp2-14-description.checkout
321
test-hpp.configure.dep: hpp-wholebody-step.install \
322
	hpp-gepetto-viewer.install hpp-hrp2.install test-hpp.checkout
323
iai_maps.configure.dep: iai_maps.checkout
324
hpp_tutorial.configure.dep: hpp-gepetto-viewer.install iai_maps.install \
325
	hpp-manipulation-corba.install hpp_tutorial.checkout
326
hpp_benchmark.configure.dep: hpp_benchmark.checkout
327
collada-dom.configure.dep: collada-dom.checkout
Joseph Mirabel's avatar
Joseph Mirabel committed
328
329
osg-dae.configure.dep: collada-dom.install \
	osg-dae.checkout
330
331
OpenSceneGraph-3.4.0.configure.dep: collada-dom.install \
	OpenSceneGraph-3.4.0.checkout
332
gepetto-viewer.configure.dep: pythonqt.install gepetto-viewer.checkout
333
gepetto-viewer-corba.configure.dep: gepetto-viewer.install \
334
	pythonqt.install gepetto-viewer-corba.checkout
335
hpp-gepetto-viewer.configure.dep: gepetto-viewer-corba.install \
Florent Lamiraux's avatar
Florent Lamiraux committed
336
	hpp-corbaserver.install \
337
	hpp-gepetto-viewer.checkout
338
hpp-gui.configure.dep: hpp-gui.checkout
339
universal_robot.configure.dep: universal_robot.checkout
340
hpp-universal-robot.configure.dep: example-robot-data.install \
Guilhem Saurel's avatar
Guilhem Saurel committed
341
	hpp-universal-robot.checkout
342
example-robot-data.configure.dep: example-robot-data.checkout
Florent Lamiraux's avatar
Florent Lamiraux committed
343
hpp-environments.configure.dep: hpp-environments.checkout
344
345
hpp-baxter.configure.dep: hpp-baxter.checkout
hpp_romeo.configure.dep: hpp_romeo.checkout
346
347
348
hpp-affordance.configure.dep: hpp-core.install hpp-fcl.install hpp-affordance.checkout
hpp-affordance-corba.configure.dep: hpp-affordance.install hpp-template-corba.install \
 hpp-corbaserver.install hpp-affordance-corba.checkout
349
350
351
352
talos-rbprm.configure.dep: talos-rbprm.checkout
hpp-rbprm.configure.dep: hpp-core.install hpp-centroidal-dynamics.install \
	hpp-rbprm-robot-data.install hpp-affordance.install curves.install \
	hpp-bezier-com-traj.install talos-rbprm.install hpp-rbprm.checkout
353
354
355
356
hpp-rbprm-robot-data.configure.dep: hpp-rbprm-robot-data.checkout
hpp-rbprm-corba.configure.dep: hpp-rbprm.install hpp-affordance-corba.install \
 hpp-corbaserver.install hpp-rbprm-robot-data.install hpp-rbprm-corba.checkout
hpp-centroidal-dynamics.configure.dep: eigenpy.install hpp-centroidal-dynamics.checkout
357
358
hpp-bezier-com-traj.configure.dep: hpp-centroidal-dynamics.install curves.install hpp-bezier-com-traj.checkout
curves.configure.dep: curves.checkout
359
eigenpy.configure.dep: eigenpy.checkout
Joseph Mirabel's avatar
Joseph Mirabel committed
360
hpp-tools.configure.dep: hpp-tools.checkout
361

362
363
364
365
# }}}
##################################
# {{{ Targets

366
status:
367
368
369
	@for child_dir in $$(ls ${SRC_DIR}); do \
		test -d "$$child_dir" || continue; \
		test -d "$$child_dir/.git" || continue; \
Florent Lamiraux's avatar
Florent Lamiraux committed
370
		${MAKE} "$$child_dir".status; \
371
	done
372

Florent Lamiraux's avatar
Florent Lamiraux committed
373
374
375
376
377
378
379
log:
	@for child_dir in $$(ls ${SRC_DIR}); do \
		test -d "$$child_dir" || continue; \
		test -d "$$child_dir/.git" || continue; \
		${MAKE} "$$child_dir".log; \
	done

380
381
382
383
384
385
386
fetch:
	@for child_dir in $$(ls ${SRC_DIR}); do \
		test -d "$$child_dir" || continue; \
		test -d "$$child_dir/.git" || continue; \
		${MAKE} "$$child_dir".fetch; \
	done

387
update:
388
389
390
391
392
	@for child_dir in $$(ls ${SRC_DIR}); do \
		test -d "$$child_dir" || continue; \
		test -d "$$child_dir/.git" || continue; \
		${MAKE} "$$child_dir".update; \
	done
Florent Lamiraux's avatar
Florent Lamiraux committed
393
394
395

%.checkout:
	if [ -d $(@:.checkout=) ]; then \
396
		echo "$(@:.checkout=) already checkout out."; \
Florent Lamiraux's avatar
Florent Lamiraux committed
397
	else \
Florent Lamiraux's avatar
Florent Lamiraux committed
398
		git clone ${GIT_QUIET} --recursive -b ${$(@:.checkout=)_branch} ${$(@:.checkout=)_repository}/$(@:.checkout=); \
Florent Lamiraux's avatar
Florent Lamiraux committed
399
400
	fi \

401
402
403
404
405
406
%.fetch:
	if [ "${$(@:.fetch=)_repository}" = "" ]; then \
		echo "$(@:.fetch=) is not referenced"; \
	else \
		cd ${SRC_DIR}/$(@:.fetch=);\
		git fetch ${GIT_QUIET} origin; \
407
		git fetch ${GIT_QUIET} origin --tags; \
408
409
	fi

Florent Lamiraux's avatar
Florent Lamiraux committed
410
%.update:
411
412
413
414
415
416
417
	if [ "${$(@:.update=)_repository}" = "" ]; then \
		echo "$(@:.update=) is not referenced"; \
	else \
		cd ${SRC_DIR}/$(@:.update=);\
		git remote rm origin;\
		git remote add origin ${$(@:.update=)_repository}/$(@:.update=);\
		git fetch origin;\
418
		git fetch origin --tags;\
Florent Lamiraux's avatar
Florent Lamiraux committed
419
420
421
		git checkout -q --detach;\
		git branch -f ${$(@:.update=)_branch} origin/${$(@:.update=)_branch};\
		git checkout -q ${$(@:.update=)_branch};\
422
423
424
		git submodule update; \
	fi

Florent Lamiraux's avatar
Florent Lamiraux committed
425

426
427
%.configure.dep: %.checkout

Florent Lamiraux's avatar
Florent Lamiraux committed
428
429
%.configure: %.configure.dep
	${MAKE} $(@:.configure=).configure_nodep
430

Florent Lamiraux's avatar
Florent Lamiraux committed
431
432
433
%.configure_nodep:%.checkout
	mkdir -p ${SRC_DIR}/$(@:.configure_nodep=)/${BUILD_FOLDER}; \
	cd ${SRC_DIR}/$(@:.configure_nodep=)/${BUILD_FOLDER}; \
434
	cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_HPP_DIR} -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=${BUILD_TYPE} \
435
436
437
			-DINSTALL_DOCUMENTATION=${INSTALL_DOCUMENTATION} \
			-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="-g -O3 -DNDEBUG" \
			${$(@:.configure_nodep=)_extra_flags} ..
Florent Lamiraux's avatar
Florent Lamiraux committed
438

Florent Lamiraux's avatar
Florent Lamiraux committed
439
%.install:%.configure
440
441
	${MAKE} -C ${SRC_DIR}/$(@:.install=)/${BUILD_FOLDER} install

Florent Lamiraux's avatar
Florent Lamiraux committed
442
443
%.install_nodep:%.configure_nodep
	${MAKE} -C ${SRC_DIR}/$(@:.install_nodep=)/${BUILD_FOLDER} install
Florent Lamiraux's avatar
Florent Lamiraux committed
444
445

%.uninstall:
446
	${MAKE} -C ${SRC_DIR}/$(@:.uninstall=)/${BUILD_FOLDER} uninstall
Florent Lamiraux's avatar
Florent Lamiraux committed
447
448

%.clean:
449
	${MAKE} -C ${SRC_DIR}/$(@:.clean=)/${BUILD_FOLDER} clean
Florent Lamiraux's avatar
Florent Lamiraux committed
450

451
%.very-clean:
452
	rm -rf ${SRC_DIR}/$(@:.very-clean=)/${BUILD_FOLDER}/*
453

Florent Lamiraux's avatar
Florent Lamiraux committed
454
%.status:
Florent Lamiraux's avatar
Florent Lamiraux committed
455
456
457
458
	@cd ${SRC_DIR}/$(@:.status=); \
	echo \
	"\033[1;36m------- Folder $(@:.status=) ---------------\033[0m"; \
	git --no-pager -c status.showUntrackedFiles=no status --short --branch;\
Florent Lamiraux's avatar
Florent Lamiraux committed
459

Florent Lamiraux's avatar
Florent Lamiraux committed
460
461
462
463
464
465
466
%.log:
	@cd ${SRC_DIR}/$(@:.log=); \
	if [ -f .git/refs/heads/${$(@:.log=)_branch} ]; then \
		echo -n "$(@:.log=): "; \
		cat .git/refs/heads/${$(@:.log=)_branch}; \
	fi

467
468
469
470
471
472
473
474
475
OpenSceneGraph-3.4.0.checkout:
	if [ -d $(@:.checkout=) ]; then \
		echo "$(@:.checkout=) already checkout out."; \
	else \
		wget http://www.openscenegraph.org/downloads/stable_releases/OpenSceneGraph-3.4.0/source/OpenSceneGraph-3.4.0.zip;\
		cd ${SRC_DIR}; unzip OpenSceneGraph-3.4.0.zip;\
		rm -f OpenSceneGraph-3.4.0.zip;\
	fi

476
robot_model_py.configure: robot_model_py.configure.dep
Florent Lamiraux's avatar
Florent Lamiraux committed
477
	cd ${SRC_DIR}/$(@:.configure=)/xml_reflection;\
478
479
	mkdir -p ${BUILD_FOLDER}; \
	cd ${BUILD_FOLDER}; \
480
	cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_HPP_DIR} -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=${BUILD_TYPE} ..
Florent Lamiraux's avatar
Florent Lamiraux committed
481
	cd ${SRC_DIR}/$(@:.configure=)/urdf_parser_py;\
482
483
	mkdir -p ${BUILD_FOLDER}; \
	cd ${BUILD_FOLDER}; \
484
	cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_HPP_DIR} -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=${BUILD_TYPE} ..
Marine Heckler's avatar
Marine Heckler committed
485

Florent Lamiraux's avatar
Florent Lamiraux committed
486
robot_model_py.install: robot_model_py.configure
487
488
	${MAKE} -C ${SRC_DIR}/$(@:.install=)/xml_reflection/${BUILD_FOLDER} install; \
	${MAKE} -C ${SRC_DIR}/$(@:.install=)/urdf_parser_py/${BUILD_FOLDER} install;
Florent Lamiraux's avatar
Florent Lamiraux committed
489
490
491
492

universal_robot.configure_nodep:
	mkdir -p ${SRC_DIR}/$(@:.configure_nodep=)/ur_description/${BUILD_FOLDER}; \
	cd ${SRC_DIR}/$(@:.configure_nodep=)/ur_description/${BUILD_FOLDER}; \
493
	cmake -DCMAKE_INSTALL_PREFIX=${DEVEL_HPP_DIR}/install -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="-g -O3 -DNDEBUG" ${$(@:.configure_nodep=)_extra_flags} ..
Florent Lamiraux's avatar
Florent Lamiraux committed
494
495
496
497
498
499
500
501

universal_robot.install_nodep:universal_robot.configure_nodep
	cd ${SRC_DIR}/$(@:.install_nodep=)/ur_description/${BUILD_FOLDER};\
	make install

universal_robot.install:universal_robot.configure
	cd ${SRC_DIR}/$(@:.install=)/ur_description/${BUILD_FOLDER};\
	make install
Florent Lamiraux's avatar
Florent Lamiraux committed
502

503
504
505
# }}}

# vim: foldmethod=marker foldlevel=0