[go: up one dir, main page]

Menu

[1da77c]: / Makefile  Maximize  Restore  History

Download this file

156 lines (117 with data), 5.3 kB

  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
143
144
145
146
147
148
149
150
151
152
153
154
# Toplevel Makefile
#
# (C) 2011, 2012 CEDET Developers
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Emacs; see the file COPYING. If not, write to the
# Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
PROJECTS=lisp/cedet lisp/speedbar lisp/cedet/cogre lisp/cedet/semantic \
lisp/cedet/ede lisp/cedet/srecode lisp/cedet/semantic/bovine lisp/cedet/semantic/wisent \
lisp/cedet/semantic/analyze lisp/cedet/semantic/decorate lisp/cedet/semantic/ectags \
lisp/cedet/semantic/symref doc/texi doc/texi/semantic
PROJECTS_AUTOLOADS=lisp/cedet lisp/speedbar lisp/cedet/cogre lisp/cedet/semantic \
lisp/cedet/ede lisp/cedet/srecode
EMACS=emacs
EMACSFLAGS=-batch --no-site-file -l cedet-remove-builtin.el
LOADDEFS=loaddefs.el
BOOTSTRAP=(progn (global-ede-mode) (find-file "$(CURDIR)/lisp/Project.ede") (ede-proj-regenerate) (find-file "$(CURDIR)/doc/texi/Project.ede") (ede-proj-regenerate))
UTEST=(progn (add-to-list (quote load-path) "$(CURDIR)/tests") (require (quote cedet-utests)) (semantic-mode))
GETVERSION=(princ (format "%s %s %s" emacs-major-version emacs-minor-version (bound-and-true-p emacs-repository-version)))
RM=rm
FIND=find
INSTALL-INFO=install-info
INFO_FILES=$(shell $(FIND) $(CURDIR)/doc/texi -type f -name '*.info')
INFODIR=$(CURDIR)/doc/info
EMACS_VERSION=$(shell $(EMACS) -Q --batch --eval '$(GETVERSION)')
EMACS_MAJOR=$(firstword $(EMACS_VERSION))
EMACS_MINOR=$(word 2,$(EMACS_VERSION))
ifeq ($(EMACS_MAJOR),23)
$(error Aborting: CEDET needs Emacs 24.x)
endif
ifneq (,$(filter $(EMACS_MINOR),1 2))
FALLBACK_EIEIO=1
endif
$(info Emacs version: $(EMACS_VERSION))
all: touch-makefiles clean-autoloads autoloads compile info install-info
ebuild:
$(EMACS) -Q --batch -l cedet-build.el -f cedet-build
compile:
ifdef FALLBACK_EIEIO
$(MAKE) -C etc/fallback-libraries/eieio -f Makefile.eieio
endif
$(MAKE) -C lisp
makefiles: $(addsuffix /Makefile,$(PROJECTS))
$(addsuffix /Makefile,$(PROJECTS)): $(addsuffix /Project.ede,$(PROJECTS))
@echo "Creating Makefiles using EDE."
@$(EMACS) $(EMACSFLAGS) --eval '(setq cedet-bootstrap-in-progress t ede-project-directories t)' -f toggle-debug-on-error -l cedet-devel-load.el --eval '$(BOOTSTRAP)'
makefiles-bootstrap:
@echo "Creating Makefiles using EDE and builtin Emacs-CEDET as fallback."
@$(EMACS) -batch --no-site-file --eval '(setq cedet-bootstrap-in-progress t ede-project-directories t)' -l cedet-devel-load.el --eval '$(BOOTSTRAP)'
touch-makefiles:
@echo Updating timestamps on all Makefiles.
$(FIND) lisp -name "Makefile" -exec touch '{}' \;
autoloads:
@echo "Generating autoloads."
@$(foreach proj,$(PROJECTS_AUTOLOADS),cd $(CURDIR)/$(proj) && $(MAKE) autoloads;)
info:
$(MAKE) -C doc -C texi
install-info:
@echo Installing info files under $(INFODIR)
@mkdir -p $(INFODIR)
@$(foreach infofile,$(INFO_FILES),cp $(infofile) $(INFODIR);$(INSTALL-INFO) --info-dir=$(INFODIR) $(infofile);)
clean-autoloads:
@echo Removing loaddefs.el files from subprojects.
@$(foreach proj,$(PROJECTS_AUTOLOADS),cd $(CURDIR)/$(proj) && if [ -f $(LOADDEFS) ];then $(RM) -f $(LOADDEFS);fi;)
clean-all: clean-autoloads
@echo Calling \"$(MAKE) clean\" in all projects.
@$(foreach proj,$(PROJECTS),echo " > $(proj)";cd $(CURDIR)/$(proj) && $(MAKE) clean;)
ifdef FALLBACK_EIEIO
$(MAKE) -C etc/fallback-libraries/eieio -f Makefile.eieio clean
endif
utest:
$(EMACS) -Q -l cedet-devel-load.el --eval '$(UTEST)' -f cedet-utest
utest-batch:
$(EMACS) $(EMACSFLAGS) -l cedet-devel-load.el --eval '$(UTEST)' -f cedet-utest-batch
itest: itest-make itest-automake itest-cpproot itest-javaroot
itest-make:
cd $(CURDIR)/tests;./cit-test.sh Make
itest-automake:
cd $(CURDIR)/tests;./cit-test.sh Automake
itest-cpproot:
cd $(CURDIR)/tests;./cit-test.sh cpproot
itest-javaroot:
cd $(CURDIR)/tests;./cit-test.sh javaroot
itest-android:
cd $(CURDIR)/tests;./cit-test.sh Android
itest-arduino:
cd $(CURDIR)/tests;./cit-test.sh Arduino
itest-globalref:
cd $(CURDIR)/tests;./cit-test.sh globalref
itest-batch: itest-make-batch itest-automake-batch itest-cpproot-batch itest-javaroot-batch itest-android-batch itest-arduino-batch # itest-globalref-batch itest-stl-batch
itest-make-batch:
cd $(CURDIR)/tests;./cit-test.sh Make --batch
itest-automake-batch:
cd $(CURDIR)/tests;./cit-test.sh Automake --batch
itest-cpproot-batch:
cd $(CURDIR)/tests;./cit-test.sh cpproot --batch
itest-javaroot-batch:
cd $(CURDIR)/tests;./cit-test.sh javaroot --batch
itest-android-batch:
cd $(CURDIR)/tests;./cit-test.sh Android --batch
itest-arduino-batch:
cd $(CURDIR)/tests;./cit-test.sh Arduino --batch
itest-globalref-batch:
cd $(CURDIR)/tests;./cit-test.sh globalref --batch
itest-stl-batch:
$(EMACS) $(EMACSFLAGS) -l cedet-devel-load.el -l $(CURDIR)/tests/cedet/semantic/stltest.el