forked from TITUS-EVD/gallery-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGNUmakefile
57 lines (53 loc) · 1.9 KB
/
GNUmakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#####################################################################################
#
# A top Makefile for building my project.
# One needs to define $GALLERY_FMWK_BASEDIR to build the sub directories.
#
#####################################################################################
#
# IMPOSE CONDITION BETWEEN GALLERY_FMWK_BASEDIR & PWD =>
# do not compile if PWD !=$GALLERY_FMWK_BASEDIR is set elsewhere
#
ifndef GALLERY_FMWK_BASEDIR
GALLERY_FMWK_BASEDIR := $(shell cd . && pwd -P)
endif
NORMALIZED_GALLERY_FMWK_BASEDIR := $(shell cd ${GALLERY_FMWK_BASEDIR} && pwd -P)
ifneq ($(NORMALIZED_GALLERY_FMWK_BASEDIR), $(shell cd . && pwd -P))
ifneq ($(wildcard ./PMTDecoder/*),)
ERROR_MESSAGE := $(error Your source code detected in current dir, but GALLERY_FMWK_BASEDIR is not current dir. \
To avoid recompiling the wrong installation,\
GALLERY_FMWK_BASEDIR must be set to the current directory when making. \
Currently it is set to ${GALLERY_FMWK_BASEDIR} [$(NORMALIZED_GALLERY_FMWK_BASEDIR)]. \
Current directory is $(shell pwd).)
endif
endif
export GALLERY_FMWK_BASEDIR
all:
@mkdir -p $(GALLERY_FMWK_BASEDIR)/lib
@echo "Start building core"
@+make --directory=$(GALLERY_FMWK_COREDIR)
@echo
@echo "Start building UserDev"
@+make --directory=$(GALLERY_FMWK_USERDEVDIR)
@echo
@echo "Exiting"
clean:
@echo "Cleaning core"
@+make clean --directory=$(GALLERY_FMWK_COREDIR)
@echo
@echo "Cleaning UserDev"
@+make clean --directory=$(GALLERY_FMWK_USERDEVDIR)
@echo
@echo "Exiting"
#####################################################################################
#
# DOCUMENTATION...
#
doxygen:
@echo 'dOxygenising your code...'
@doxygen $(GALLERY_FMWK_BASEDIR)/doc/doxygenMyProject.script
doxygen+:
@echo 'dOxygenising MyProject + local-ROOT...'
@doxygen $(GALLERY_FMWK_BASEDIR)/doc/doxygenMyProject+.script
#
#####################################################################################