-
Notifications
You must be signed in to change notification settings - Fork 54
/
Makefile.in
142 lines (128 loc) · 4.81 KB
/
Makefile.in
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
CP = cp -p
MV = mv
MKDIR = mkdir -p
RMDIR = rm -rf
STRIP = strip
AWK = @AWK@
PERL = perl
PYTHON = python
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
GNATCOLL_INSTALL = @GNATCOLL_INSTALL@
prefix = @prefix@
bindir = $(prefix)/bin
sharedir = $(prefix)/share
examplesdir = $(prefix)/share/examples/gnatstudio
SYS := $(shell gcc -dumpmachine)
all default:
$(MAKE) -C gnatstudio default
$(MAKE) -C cli default
$(MAKE) -C testsuite default
codepeer:
$(MAKE) -C gnatstudio scil
codepeer -all -lib gps.library -quiet -baseline -level 1 \
-jobs 0 $(CODEPEER_FLAGS)
clean:
$(MAKE) -C gnatstudio $@
$(MAKE) -C cli $@
$(MAKE) -C testsuite $@
test-clean:
(cd scripts; ./testsuites clean)
install-common:
$(MKDIR) $(bindir)
$(MKDIR) $(sharedir)
$(MKDIR) $(examplesdir)
$(MKDIR) $(sharedir)/gnatstudio
$(MKDIR) $(sharedir)/gnatstudio/gnatdoc
$(RM) -rf $(sharedir)/gnatstudio/color_themes/
$(RM) -rf $(sharedir)/gnatstudio/library/
$(RM) -rf $(sharedir)/gnatstudio/plug-ins/
$(RM) -rf $(sharedir)/gnatstudio/support/core/
$(RM) -rf $(sharedir)/gnatstudio/support/ui/
${RM} ${sharedir}/gnatstudio/perspectives.xml
$(RMDIR) $(sharedir)/gnatstudio/templates
(cd share; tar cf - plug-ins/*) | (cd $(sharedir)/gnatstudio; tar xf -)
# Regenerate predefined_ada.xml before we install it
-${PYTHON} design/scripts/update_predefined_ada.py
(cd share; tar cf - library/*.py) | (cd $(sharedir)/gnatstudio; tar xf -)
(cd share; tar cf - support/) | (cd $(sharedir)/gnatstudio; tar xf -)
-${PYTHON} distrib/gnat_switches.py > $(sharedir)/gnatstudio/support/core/gnat_switches.py
$(RM) $(sharedir)/gnatstudio/plug-ins/emacs.xml
$(RM) $(sharedir)/gnatstudio/plug-ins/python_doc.py
$(RM) $(sharedir)/gnatstudio/plug-ins/python_doc.pyc
$(RM) $(sharedir)/gnatstudio/shell_commands.xml
(cd share; tar cf - icons/) | (cd $(sharedir)/gnatstudio; tar xf -)
$(RM) $(sharedir)/gnatstudio/icons/hicolor/scalable/*sketch
(cd share; tar cf - fonts/) | (cd $(sharedir)/gnatstudio; tar xf -)
(cd share; tar cf - color_themes/) | (cd $(sharedir)/gnatstudio; tar xf -)
(cd share; tar cf - templates/) | (cd $(sharedir)/gnatstudio; tar xf -)
(cd share; tar cf - key_themes/) | (cd $(sharedir)/gnatstudio; tar xf -)
(cd share; tar cf - *.*) | (cd $(sharedir)/gnatstudio; tar xf -)
(cd gnatdoc/resources; tar cf - * ) \
| (cd $(sharedir)/gnatstudio/gnatdoc; tar xf -)
$(MAKE) -C docs install
(cd examples; tar cf - --exclude .svn . ) | (cd $(examplesdir); tar xf -)
# Install the gnatcoll plugin(s)
ifneq ($(GNATCOLL_INSTALL),)
(cd $(GNATCOLL_INSTALL)/share/gnatstudio/plug-ins; tar cf - --exclude .svn gnatcoll/) \
| (cd $(sharedir)/gnatstudio/support/core/; tar xf -)
endif
install: install-common
ifeq ($(OS),Windows_NT)
$(INSTALL_PROGRAM) gnatstudio/obj/gnatstudio.exe $(bindir)
$(INSTALL_PROGRAM) cli/obj/gnatdoc3.exe $(bindir)
$(INSTALL_PROGRAM) cli/obj/gnatstudio_cli.exe $(bindir)
ifneq ($(GNATCOLL_INSTALL),)
ifneq ($(GNATCOLL_INSTALL)/bin, $(bindir))
$(INSTALL_PROGRAM) $(GNATCOLL_INSTALL)/bin/gnatinspect.exe $(bindir)
endif
endif
else
$(INSTALL_PROGRAM) gnatstudio/obj/gnatstudio $(bindir)
$(INSTALL_PROGRAM) cli/obj/gnatdoc3 $(bindir)
$(INSTALL_PROGRAM) cli/obj/gnatstudio_cli $(bindir)
ifneq ($(GNATCOLL_INSTALL),)
ifneq ($(GNATCOLL_INSTALL)/bin, $(bindir))
$(INSTALL_PROGRAM) $(GNATCOLL_INSTALL)/bin/gnatinspect $(bindir)
endif
endif
endif
install-strip: install-common
ifeq ($(OS),Windows_NT)
$(INSTALL_PROGRAM) -s gnatstudio/obj/gnatstudio.exe $(bindir)
$(INSTALL_PROGRAM) -s cli/obj/gnatdoc3.exe $(bindir)
$(INSTALL_PROGRAM) -s cli/obj/gnatstudio_cli.exe $(bindir)
ifneq ($(GNATCOLL_INSTALL),)
ifneq ($(GNATCOLL_INSTALL)/bin, $(bindir))
$(INSTALL_PROGRAM) -s $(GNATCOLL_INSTALL)/bin/gnatinspect.exe $(bindir)
endif
endif
$(INSTALL_PROGRAM) distrib/gps_run.cmd $(bindir)
else
ifneq (, $(findstring darwin, $(SYS)))
$(INSTALL_PROGRAM) gnatstudio/obj/gnatstudio $(bindir)/gnatstudio_exe
$(INSTALL_PROGRAM) cli/obj/gnatdoc3 $(bindir)
$(INSTALL_PROGRAM) cli/obj/gnatstudio_cli $(bindir)
ifneq ($(GNATCOLL_INSTALL),)
ifneq ($(GNATCOLL_INSTALL)/bin, $(bindir))
$(INSTALL_PROGRAM) $(GNATCOLL_INSTALL)/bin/gnatinspect $(bindir)
endif
endif
$(INSTALL_PROGRAM) distrib/gps_wrapper $(bindir)/gnatstudio
else
$(INSTALL_PROGRAM) -s gnatstudio/obj/gnatstudio $(bindir)/gnatstudio_exe
$(INSTALL_PROGRAM) -s cli/obj/gnatdoc3 $(bindir)
$(INSTALL_PROGRAM) -s cli/obj/gnatstudio_cli $(bindir)
ifneq ($(GNATCOLL_INSTALL),)
ifneq ($(GNATCOLL_INSTALL)/bin, $(bindir))
$(INSTALL_PROGRAM) -s $(GNATCOLL_INSTALL)/bin/gnatinspect $(bindir)
endif
endif
$(INSTALL_PROGRAM) distrib/gps_wrapper $(bindir)/gnatstudio
endif
endif
test: force
@cd scripts; ./testsuites
.PHONY: install install-common install-strip test force
force: