Merge from emacs-24; up to 2012-12-01T13:25:13Z!cyd@gnu.org
[bpt/emacs.git] / doc / misc / ede.texi
1 \input texinfo
2 @setfilename ../../info/ede
3 @settitle Emacs Development Environment
4
5 @copying
6 This file describes EDE, the Emacs Development Environment.
7
8 Copyright @copyright{} 1998-2001, 2004-2005, 2008-2012
9 Free Software Foundation, Inc.
10
11 @quotation
12 Permission is granted to copy, distribute and/or modify this document
13 under the terms of the GNU Free Documentation License, Version 1.3 or
14 any later version published by the Free Software Foundation; with no
15 Invariant Sections, with the Front-Cover texts being ``A GNU Manual,''
16 and with the Back-Cover Texts as in (a) below. A copy of the license
17 is included in the section entitled ``GNU Free Documentation License.''
18
19 (a) The FSF's Back-Cover Text is: ``You have the freedom to copy and
20 modify this GNU manual.''
21 @end quotation
22 @end copying
23
24 @dircategory Emacs misc features
25 @direntry
26 * EDE: (ede). The Emacs Development Environment.
27 @end direntry
28
29 @titlepage
30 @center @titlefont{EDE (The Emacs Development Environment)}
31 @sp 4
32 @center by Eric Ludlam
33 @end titlepage
34 @page
35
36 @macro cedet{}
37 @i{CEDET}
38 @end macro
39
40 @macro semantic{}
41 @i{Semantic}
42 @end macro
43
44 @macro srecode{}
45 @i{SRecode}
46 @end macro
47
48 @macro eieio{}
49 @i{EIEIO}
50 @end macro
51
52 @macro ede{}
53 @i{EDE}
54 @end macro
55
56 @macro cogre{}
57 @i{COGRE}
58 @end macro
59
60 @macro speedbar{}
61 @i{Speedbar}
62 @end macro
63
64 @contents
65
66 @node top, EDE Project Concepts, (dir), (dir)
67 @top EDE
68 @comment node-name, next, previous, up
69
70 @ede{} is the Emacs Development Environment: an Emacs extension that
71 simplifies building and debugging programs in Emacs. It attempts to
72 emulate a typical IDE (Integrated Development Environment). @ede{}
73 can manage or create your makefiles and other building environment
74 duties, allowing you to concentrate on writing code rather than
75 support files. It aims to make it much easier for new programmers to
76 learn and adopt GNU ways of doing things.
77
78 @ifnottex
79 @insertcopying
80 @end ifnottex
81
82 @menu
83 * EDE Project Concepts:: @ede{} Project Concepts
84 * EDE Mode:: Turning on @ede{} mode.
85 * Quick Start:: Quick start to building a project.
86 * Creating a project:: Creating a project.
87 * Modifying your project:: Adding and removing files and targets.
88 * Building and Debugging:: Initiating a build or debug session.
89 * Miscellaneous commands:: Other project related commands.
90 * Extending EDE:: Programming and extending @ede{}.
91 * GNU Free Documentation License:: The license for this documentation.
92 @end menu
93
94 @node EDE Project Concepts, EDE Mode, top, top
95 @chapter @ede{} Project Concepts
96
97 @ede{} is a generic interface for managing projects. It specifies a
98 single set of menus and keybindings, while supporting multiple ways to
99 express a project via a build system.
100
101 In the subsequent chapters, we will describe the different project
102 types (@pxref{Creating a project}), as well as the commands to build
103 and debug projects (@pxref{Building and Debugging}).
104
105 In @ede{}, a project hierarchy matches a directory hierarchy. The
106 project's topmost directory is called the @dfn{project root}, and its
107 subdirectories are @dfn{subprojects}.
108
109 Each project can contain multiple @dfn{targets}. A target, at the
110 simplest level, is a named collection of files within a project. A
111 target can specify two different types of information:
112
113 @enumerate
114 @item
115 A collection of files to be added to a distribution (e.g., a tarball
116 that you intend to distribute to others).
117
118 @item
119 A collection of files that can be built into something else (e.g., a
120 program or compiled documentation).
121 @end enumerate
122
123 Lastly, @ede{} provides a way for other tools to easily learn file
124 associations. For example, a program might need to restrict some sort
125 of search to files in a single target, or to discover the location of
126 documentation or interface files. @ede{} can provide this
127 information.
128
129 @node EDE Mode, Quick Start, EDE Project Concepts, top
130 @chapter @ede{} Mode
131
132 @ede{} is implemented as a minor mode, which augments other modes such
133 as C mode, and Texinfo mode. You can enable @ede{} for all buffers by
134 running the command @code{global-ede-mode}, or by putting this in your
135 init file:
136
137 @example
138 (global-ede-mode t)
139 @end example
140
141 Activating @ede{} adds a menu named @samp{Development} to the menu
142 bar. This menu provides several menu items for high-level @ede{}
143 commands. These menu items, and their corresponding keybindings, are
144 independent of the type of project you are actually working on.
145
146 @node Quick Start, Creating a project, EDE Mode, top
147 @chapter Quick Start
148
149 Once you have @ede{} enabled, you can create a project. This chapter
150 provides an example C++ project that will create Automake files for
151 compilation.
152
153 @section Step 1: Create root directory
154
155 First, lets create a directory for our project. For this example,
156 we'll start with something in @file{/tmp}.
157
158 @example
159 C-x C-f /tmp/myproject/README RET
160 M-x make-directory RET RET
161 @end example
162
163 Now put some plain text in your README file to start.
164
165 Now, lets create the project:
166
167 @example
168 M-x ede-new RET Automake RET myproject RET
169 @end example
170
171
172 Nothing visible happened, but if you use @code{dired} to look at the
173 directory, you should see this:
174
175 @example
176 /tmp/myproject:
177 total used in directory 32 available 166643476
178 drwxr-xr-x 2 zappo users 4096 2012-02-23 22:10 .
179 drwxrwxrwt 73 root root 20480 2012-02-23 22:10 ..
180 -rw-r--r-- 1 zappo users 195 2012-02-23 22:10 Project.ede
181 -rw-r--r-- 1 zappo users 10 2012-02-23 22:09 README
182 @end example
183
184 @section Step 2: Create Subdirectories and Files
185
186 We'll make a more complex project, so use dired to create some more
187 directories using the @kbd{+} key, and typing in new directories:
188
189 @example
190 + include RET
191 + src RET
192 @end example
193
194 Now I'll short-cut in this tutorial. Create the following files:
195
196 @file{include/myproj.hh}
197 @example
198 /** myproj.hh ---
199 */
200
201 #ifndef myproj_hh
202 #define myproj_hh 1
203
204 #define IMPORTANT_MACRO 1
205
206 int my_lib_function();
207
208 #endif // myproj_hh
209 @end example
210
211
212 @file{src/main.cpp}
213 @example
214 /** main.cpp ---
215 */
216
217 #include <iostream>
218 #include "myproj.hh"
219
220 int main() @{
221
222 @}
223
224 #ifdef IMPORTANT_MACRO
225 int my_fcn() @{
226
227 @}
228 #endif
229 @end example
230
231 @file{src/mylib.cpp}
232 @example
233 /** mylib.cpp ---
234 *
235 * Shared Library to build
236 */
237
238 int my_lib_function() @{
239
240 @}
241 @end example
242
243 @section Step 3: Create subprojects
244
245 @ede{} needs subdirectories to also have projects in them. You can
246 now create those projects.
247
248 With @file{main.cpp} as your current buffer, type:
249
250 @example
251 M-x ede-new RET Automake RET src RET
252 @end example
253
254 and in @file{myproj.hh} as your current buffer, type:
255
256 @example
257 M-x ede-new RET Automake RET include RET
258 @end example
259
260 These steps effectively only create the Project.ede file in which you
261 will start adding targets.
262
263 @section Step 4: Create targets
264
265 In order to build a program, you must have targets in your @ede{}
266 Projects. You can create targets either from a buffer, or from a
267 @code{dired} directory buffer.
268
269 Note: If for some reason a directory list buffer, or file does not have the
270 @samp{Project} menu item, or if @ede{} keybindings don't work, just
271 use @kbd{M-x revert-buffer RET} to force a refresh. Sometimes
272 creating a new project doesn't restart buffers correctly.
273
274 Lets start with the header file. In @file{include/myproj.hh}, you
275 could use the menu, but we will now start using the @ede{} command prefix
276 which is @kbd{C-c .}.
277
278 @example
279 C-c . t includes RET miscellaneous RET y
280 @end example
281
282
283 This creates a misc target for holding your includes, and then adds
284 myproj.hh to the target. Automake (the tool) has better ways to do
285 this, but for this project, it is sufficient.
286
287 Next, visit the @file{src} directory using dired. There should be a
288 @samp{Project} menu. You can create a new target with
289
290 @example
291 . t myprogram RET program RET
292 @end example
293
294 Note that @kbd{. t} is a command for creating a target. This command
295 is also in the menu. This will create a target that will build a
296 program. If you want, visit @file{Project.ede} to see the structure
297 built so far.
298
299 Next, place the cursor on @file{main.cpp}, and use @kbd{. a} to add
300 that file to your target.
301
302 @example
303 . a myprogram RET
304 @end example
305
306 Note that these prompts often have completion, so you can just press
307 @kbd{TAB} to complete the name @file{myprogram}.
308
309 If you had many files to add to the same target, you could mark them
310 all in your dired buffer, and add them all at the same time.
311
312 Next, do the same for the library by placing the cursor on @file{mylib.cpp}.
313
314 @example
315 . t mylib RET sharedobject RET
316 . a mylib RET
317 @end example
318
319 @section Step 5: Compile, and fail
320
321 Next, we'll try to compile the project, but we aren't done yet, so it
322 won't work right away.
323
324 Visit @file{/tmp/myproject/Project.ede}. We're starting here because
325 we don't have any program files in this directory yet. Now we can use
326 the compile command:
327
328 @example
329 C-c . C
330 @end example
331
332 Because this is the very first time, it will create a bunch of files
333 for you that are required by Automake. It will then use automake to
334 build the support infrastructure it needs. This step is skipped if
335 you choose just a @file{Makefile} build system.
336
337 After the Automake init, it runs compile. You will immediately
338 discover the error in main.cpp can't find @file{myproj.hh}. We need
339 to go fix this.
340
341 @section Step 6: Customizing your project
342
343 To fix the failed compile, we need to add
344 @file{/tmp/myproject/include} to the include path.
345
346 Visit @file{main.cpp}.
347
348 @example
349 M-x customize-project RET
350 @end example
351
352 Select the @samp{[Settings]} subgroup of options. Under
353 @samp{Variable :} click @samp{[INS]}. At this point, you need to be
354 somewhat savvy with Automake. Add a variable named @samp{CPPFLAGS},
355 and set the value to @samp{../include}.
356
357 You should see something like this:
358
359 @example
360 Variables :
361 [INS] [DEL] Cons-cell:
362 Name: AM_CPPFLAGS
363 Value: -I../include
364 [INS]
365 Variables to set in this Makefile.
366 @end example
367
368 Click @samp{[Apply]}. Feel free to visit @file{Project.ede} to see
369 how it changed the config file.
370
371 Compile the whole project again with @kbd{C-c . C} from
372 @file{main.cpp}. It should now compile.
373
374 @section Step 7: Shared library dependency
375
376 Note: Supporting shared libraries for Automake in this way is easy,
377 but doing so from a project of type Makefile is a bit tricky. If you
378 are creating shared libraries too, stick to Automake projects.
379
380 Next, lets add a dependency from @file{main.cpp} on our shared
381 library. To do that, update main like this:
382
383 @example
384 int main() @{
385
386 my_lib_function();
387
388 @}
389 @end example
390
391 Now compile with:
392
393 @example
394 C-c . c
395 @end example
396
397 where the lower case @kbd{c} compiles just that target. You should
398 see an error.
399
400 This time, we need to add a dependency from @file{main.cpp} on our shared
401 library. To do that, we need to customize our target instead of the
402 project. This is because variables such as the include path are
403 treated globally, whereas dependencies for a target are target specific.
404
405 @example
406 M-x customize-target RET
407 @end example
408
409 On the first page, you will see an Ldlibs-local section. Add mylib to
410 it by first clicking @samp{[INS]}, and they adding the library. It
411 should look like this:
412
413 @example
414 Ldlibs-Local :
415 [INS] [DEL] Local Library: libmylib.la
416 [INS]
417 Libraries that are part of this project. [Hide Rest]
418 The full path to these libraries should be specified, such as:
419 ../lib/libMylib.la or ../ar/myArchive.a
420 @end example
421
422 You will also see other variables for library related flags and system
423 libraries if you need them. Click @samp{[Accept]}, and from
424 @file{main.cpp}, again compile the whole project to force all
425 dependent elements to compile:
426
427 @example
428 C-c . C
429 @end example
430
431 @section Step 8: Run your program
432
433 You can run your program directly from @ede{}.
434
435 @example
436 C-c . R RET RET
437 @end example
438
439 If your program takes command line arguments, you can type them in
440 when it offers the command line you want to use to run your program.
441
442 @node Creating a project, Modifying your project, Quick Start, top
443 @chapter Creating a project
444
445 To create a new project, first visit a file that you want to include
446 in that project. If you have a hierarchy of directories, first visit
447 a file in the topmost directory. From this buffer, type @kbd{M-x
448 ede-new}, or click on the @samp{Create Project} item in the
449 @samp{Development} menu.
450
451 The @command{ede-new} command prompts for the type of project you
452 would like to create. Each project type has its own benefits or
453 language specific enhancements. @ede{} supports four different
454 project types: @samp{Make}, @samp{Automake}, @samp{direct Automake},
455 and @samp{Simple}.
456
457 @itemize
458 @item
459 For the @samp{Make} project type, @ede{} creates a @dfn{project file},
460 called @file{Project.ede}, in each project directory. Information
461 about the project is stored in this file. This project autogenerates
462 a @file{Makefile}.
463
464 @item
465 For the @samp{Automake} project type, @ede{} creates a
466 @file{Project.ede} project file similar to a @samp{Make} project.
467 Unlike a @samp{Make} project, this project autogenerates a
468 @file{Makefile.am} file. @ede{} handles the Automake bootstrapping
469 routines, which import and maintain a @file{configure.am} script and
470 other required files.
471
472 @item
473 For the @samp{direct Automake} project type, @ede{} reads directly
474 from the Automake files.
475
476 You cannot create direct Automake projects with the @command{ede-new}
477 command. Instead, when you visit a project with existing Automake
478 files, @ede{} automatically detects them.
479
480 @item
481 The @samp{Simple} project type provides light-weight constructs for
482 identifying a project root and looking up files. If you already have
483 a non-@ede{} project infrastructure, you can use a @samp{Simple}
484 project to provide other Emacs packages, such as Semantic, with some
485 information about the project. @xref{Simple projects}.
486 @end itemize
487
488 A subproject is merely a project in a subdirectory of another project.
489 You can create a subproject by using the @command{ede-new} command (or
490 the @samp{Create Project} menu item), while visiting a buffer in a
491 subdirectory of the project root. This new project is automatically
492 added to the parent project, and will be automatically loaded when
493 @ede{} reads the parent project.
494
495 When using a project command that involves a makefile, @ede{} uses
496 the top-most project's makefile as a starting place for the build. How
497 the toplevel project handles subprojects in the build process is
498 dependent on that project's type.
499
500 @node Modifying your project, Building and Debugging, Creating a project, top
501 @chapter Modifying your project
502
503 In this chapter, we describe the generic features for manipulating
504 projects, including the targets and files within them. Subsequent
505 chapters, which describe specific project types, will provide more
506 detailed information about exactly what these features do.
507
508 @menu
509 * Add/Remove target::
510 * Add/Remove files::
511 * Customize Features::
512 * Project Local Variables::
513 * EDE Project Features::
514 @end menu
515
516 @node Add/Remove target, Add/Remove files, Modifying your project, Modifying your project
517 @section Add/Remove target
518
519 To create a new target, type @kbd{C-c . t} (@code{ede-new-target}) or
520 use the @samp{Add Target} menu item in the @samp{Project Options}
521 submenu. This prompts for a target name, and adds the current buffer
522 to that target.
523
524 The @command{ede-new-target} command also prompts for a @dfn{target
525 type}. Each target type has its own build process and class of files
526 that it will accept.
527
528 To remove a target from the project, type @kbd{M-x ede-delete-target},
529 or use the @samp{Remove Target} menu item in the @samp{Project
530 Options} submenu.
531
532 @node Add/Remove files, Customize Features, Add/Remove target, Modifying your project
533 @section Add/Remove files
534
535 To add the current file to an existing target, type @kbd{C-c . a}
536 (@code{ede-add-file}), or use the @samp{Add File} menu item in the
537 @samp{Target Options} submenu.
538
539 You can add a file to more than one target; this is OK.
540
541 To remove the current file from a target, type @kbd{C-c . d}
542 (@code{ede-remove-file}), or use the @samp{Remove File} menu item
543 in the @samp{Target Options} submenu. If the file belongs to multiple
544 targets, this command prompts for each target it could be removed
545 from.
546
547 While working in a project, if you visit a file that is not part of an
548 existing target, @ede{} automatically prompts for a target. If you do
549 not wish to add the file to any target, you can choose @samp{none}.
550 You can customize this behavior with the variable
551 @command{ede-auto-add-method}.
552
553 @node Customize Features, Project Local Variables, Add/Remove files, Modifying your project
554 @section Customize Features
555
556 A project, and its targets, are objects using the @samp{EIEIO} object
557 system. @xref{Top,,,eieio,EIEIO manual}. These objects have data
558 fields containing important information related to your work.
559
560 If the high-level functions aren't enough, you can tweak all
561 user-customizable fields at any time by running the command
562 @command{customize-project} or @command{customize-target}. This loads
563 the current project or target into a customization buffer, where you
564 can tweak individual slots. This is usually necessary for complex
565 projects.
566
567 Some project modes do not have a project file, but directly read a
568 Makefile or other existing file. Instead of directly editing the
569 object, you can edit the file by typing @kbd{C-c . e}
570 (@code{ede-edit-file-target}). You should ``rescan'' the project
571 afterwards (@pxref{Miscellaneous commands}).
572
573 @node Project Local Variables, EDE Project Features, Customize Features, Modifying your project
574 @section Project Local Variables
575
576 EDE projects can store and manager project local variables. The
577 variables are stored in the project, and will be restored when a
578 project reloads.
579
580 Projects which are not stored on disk WILL NOT restore your project
581 local variables later.
582
583 You can use @ref{Customize Features} to of the project to edit the
584 project local variables. They are under the 'Settings' group as
585 ``Project Local Variables''.
586
587 You can also use @kbd{M-x ede-set} to set a new variable local in the
588 mini buffer.
589
590 In multi-level projects such as Automake and Make generating projects,
591 project local variables are installed from both the TOP most project,
592 and the local directory's project. In that way, you can have some
593 variables across your whole project, and some specific to a
594 subdirectory.
595
596 You can use project local variables to set any Emacs variable so that
597 buffers belonging to different projects can have different settings.
598
599 NOTE: When you use project-local variables with @ref{ede-cpp-root},
600 the format is an association list. For example:
601
602 @example
603 (ede-cpp-root-project "SOMENAME"
604 :file "/dir/to/some/file"
605 :local-variables
606 '((grep-command . "grep -nHi -e ")
607 (compile-command . "make -f MyCustomMakefile all")))
608 @end example
609
610 The same is true when you use project-local variables with
611 @ref{ede-java-root}. For example:
612
613 @example
614 (ede-java-root-project "SOMENAME"
615 :file "/dir/to/some/file"
616 :local-variables
617 '((grep-command . "grep -nHi -e ")
618 (compile-command . "ant")))
619 @end example
620
621 @node EDE Project Features, , Project Local Variables, Modifying your project
622 @section EDE Project Features
623
624 This section details user facing features of an @ede{} @samp{Make}
625 style project. An @samp{Automake} project has similar options (but a
626 direct Automake project does not).
627
628 To modify any of the specific features mentioned here, you need to
629 customize the project or target with @command{customize-project} or
630 @command{customize-target}.
631
632 When you are customizing, you are directly manipulating slot values in
633 @eieio{} objects. @xref{Extending EDE}, if you are interested in
634 additional details.
635
636 @menu
637 * Changing Compilers and Flags::
638 * Configurations::
639 @end menu
640
641 @node Changing Compilers and Flags, Configurations, EDE Project Features, EDE Project Features
642 @subsection Changing Compilers and Flags
643
644 Targets that build stuff need compilers. To change compilers, you
645 need to customize the desired target.
646
647 In the @samp{[Make]} section, you can choose a new compiler or linker
648 from the list. If a linker you need is not available, you will need
649 to create a new one. @xref{Compiler and Linker objects}.
650
651 If an existing compiler or linker is close, but you need to modify
652 some flag set such as adding an include path you will need to add a
653 configuration variable.
654
655 To start, you should create the basic setup, and construct a makefile
656 with @command{ede-proj-regenerate}. Look in the @file{Makefile} to
657 see what commands are inserted. Once you have determined the variable
658 you need to modify, you can add a configuration for it.
659 @xref{Configurations}.
660
661 @node Configurations, , Changing Compilers and Flags, EDE Project Features
662 @subsection Configurations
663
664 Configurations specify different ways to build a project. For
665 example, you may configure a project to be in ``debug'' mode, or
666 perhaps in ``release'' mode.
667
668 The project, and each target type all have a slot named
669 @code{configuration-variables}. To add new variables to a
670 configuration find this slot in the custom buffer, and insert a new
671 configuration. Name it either ``debug'' or ``release'', then insert
672 some number of name/value pairs to it.
673
674 You can have any number of valid configurations too. To add a new
675 configuration, customize your project. Work in the @samp{[Settings]}
676 block for ``configurations''. Add a new named configuration here.
677
678 To switch between different active configurations, modify the
679 ``configuration default'' slot.
680
681 @node Building and Debugging, Miscellaneous commands, Modifying your project, top
682 @chapter Building and Debugging
683
684 @ede{} provides the following ``project-aware'' compilation and
685 debugging commands:
686
687 @table @kbd
688 @item C-c . c
689 Compile the current target (@code{ede-compile-target}).
690 @item C-c . C
691 Compile the entire project (@code{ede-compile-project}).
692 @item c-c . D
693 Debug the current target (@code{ede-debug-target}).
694 @item M-x ede-make-dist
695 Build a distribution file for your project.
696 @end table
697
698 These commands are also available from the @samp{Development} menu.
699
700 @node Miscellaneous commands, Extending EDE, Building and Debugging, top
701 @chapter Miscellaneous commands
702
703 If you opt to go in and edit @ede{} project files directly---for
704 instance, by using @kbd{C-c . e} (@pxref{Customize Features})---you
705 must then ``rescan'' the project files to update the internal data
706 structures. To rescan the current project, type @kbd{C-c . g}
707 (@code{ede-rescan-toplevel}).
708
709 @ede{} can help you find files in your project, via the command
710 @kbd{C-c . f} (@code{ede-find-file}). This prompts for a file name;
711 you need not specify the directory. EDE then tries to visit a file
712 with that name somewhere in your project.
713
714 @ede{} can use external tools to help with file finding. To do this,
715 customize @code{ede-locate-setup-options}.
716
717 @defvar ede-locate-setup-options
718 @anchor{ede-locate-setup-options}
719 List of locate objects to try out by default.
720 Listed in order of preference. If the first item cannot be used in
721 a particular project, then the next one is tried.
722 It is always assumed that @dfn{ede-locate-base} is at end of the list.
723 @end defvar
724
725 @ede{} also provides a project display mode for the speedbar
726 (@pxref{Speedbar,,,emacs,GNU Emacs Manual}). This allows you to view
727 your source files as they are structured in your project: as a
728 hierarchical tree, grouped according to target.
729
730 To activate the speedbar in this mode, type @kbd{C-c . s}
731 (@code{ede-speedbar}).
732
733 @menu
734 * Make and Automake projects:: Project types of @samp{ede-project}
735 * Automake direct projects:: Project interface on hand-written automake files.
736 * Android projects:: Projects for Android development
737 * Arduino projects:: Projects for Arduino sketches
738 * Simple projects:: Projects @ede{} doesn't manage.
739 @end menu
740
741 @node Make and Automake projects
742 @section Make and Automake projects
743
744 A project of @samp{ede-project} type creates a file called
745 @file{Project.ede} in every project directory. This is used to track
746 your configuration information. If you configure this project to be
747 in @samp{Makefile} mode, then this project will autogenerate a
748 @file{Makefile}. If you configure it in @samp{Automake} mode a
749 @file{Makefile.am} file will be created. The automake bootstrapping
750 routines will also import and maintain a configure.am script and a
751 host of other files required by Automake.
752
753 @node Automake direct projects
754 @section Automake direct projects
755
756 The project type that reads @file{Makefile.am} directly is derived
757 from the sources of the original @file{project-am.el} mode that was
758 distributed independently. This mode eventually became @ede{}. The
759 @samp{project-am} project will read existing automake files, but will
760 not generate them automatically, or create new ones. As such, it is
761 useful as a browsing tool, or as maintenance in managing file lists.
762
763 @node Android projects
764 @section Android projects
765
766 An Android project of type @samp{ede-android-project} will detect and
767 support development of Android apps. Android projects use an
768 @file{AndroidManifest.xml} file. Always load your Manifest first in a
769 running Emacs to make sure the project is identified correctly.
770
771 Android projects can be created with @code{ede-new} but depend on a
772 correctly configured Android SDK via @cedet{} support.
773
774 @defun cedet-android-sdk-root
775 @anchor{cedet-android-sdk-root}
776 The root to the android @var{SDK}.
777 @end defun
778
779 Android projects support different configurations including compile,
780 and install, which will upload a program to your Android device. It
781 also supports several debugging tools via @file{android.el}.
782
783 @node Arduino projects
784 @section Arduino projects
785
786 An arduino project of type @samp{ede-arduino-project} will read your
787 @file{~/.arduino/preferences.txt} file, and identify your sketches.
788 You will still need the Arduino IDE to set up your preferences and
789 locate your arduino. After quitting the IDE, Emacs will be able to
790 find your sketches, compile them, and upload them to your arduino.
791
792 If you have the @file{arduino} command on your path, @ede{} will be
793 able to find your SDK and compile your programs.
794
795 @node Simple projects
796 @section Simple Projects
797
798 There is a wide array of Simple projects. The root for simple
799 projects is the class @code{ede-simple-project}. This handles the
800 infrastructure of storing a .ede file if needed.
801
802 The class @code{ede-simple-project} is designed to be subclassed.
803 Then key @ede{} methods can be overridden to provide a quick wrapper
804 over any project.
805
806 A second project type is @code{ede-cpp-root}. This project type is
807 designed to be created for a directory hierarchy full of C/C++ code.
808 It can be configured with minimal lisp knowledge to do header file
809 lookup for @semantic{}, improving code completion performance.
810
811 @menu
812 * ede-cpp-root:: This project marks the root of a C/C++ code project.
813 * ede-java-root:: This project marks the root of a Java project.
814 * ede-emacs:: A project for working with Emacs.
815 * ede-linux:: A project for working with Linux kernels.
816 * Custom Locate:: Customizing how to locate files in a simple project
817 @end menu
818
819 @node ede-cpp-root, ede-java-root, Simple projects, Simple projects
820 @subsection ede-cpp-root
821
822 The @code{ede-cpp-root} project type allows you to create a single
823 object with no save-file in your @file{.emacs} file. It allows @ede{}
824 to provide the @semantic{} package with the ability to find header
825 files quickly.
826
827 The @code{ede-cpp-root} class knows a few things about C++ projects,
828 such as the prevalence of "include" directories, and typical
829 file-layout stuff. If this isn't sufficient, you can subclass
830 @code{ede-cpp-root-project} and add your own tweaks in just a few
831 lines. See the end of this file for an example.
832
833 In the most basic case, add this to your @file{.emacs} file, modifying
834 appropriate bits as needed.
835
836 @example
837 (ede-cpp-root-project "SOMENAME" :file "/dir/to/some/file")
838 @end example
839
840 Replace @var{SOMENAME} with whatever name you want, and the filename
841 to an actual file at the root of your project. It might be a
842 Makefile, a README file. Whatever. It doesn't matter. It's just a
843 key to hang the rest of @ede{} off of.
844
845 The most likely reason to create this project, is to speed up
846 searching for includes files, or to simplify bootstrapping @semantic{}'s
847 ability to find files without much user interaction. In conjunction
848 with @semantic{} completion, having a short include path is key. You can
849 override the default include path and system include path like this:
850
851 @example
852 (ede-cpp-root-project "NAME" :file "FILENAME"
853 :include-path '( "/include" "../include" "/c/include" )
854 :system-include-path '( "/usr/include/c++/3.2.2/" )
855 :spp-table '( ("MOOSE" . "")
856 ("CONST" . "const") ) )
857 @end example
858
859 In this case each item in the include path list is searched. If the
860 directory starts with "/", then that expands to the project root
861 directory. If a directory does not start with "/", then it is
862 relative to the default-directory of the current buffer when the file
863 name is expanded.
864
865 The include path only affects C/C++ header files. Use the slot
866 @code{:header-match-regexp} to change it.
867
868 The @code{:system-include-path} allows you to specify full directory
869 names to include directories where system header files can be found.
870 These will be applied to files in this project only.
871
872 The @code{:spp-table} provides a list of project specific #define
873 style macros that are unique to this project, passed in to the
874 compiler on the command line, or are in special headers.
875 See the @code{semantic-lex-c-preprocessor-symbol-map} for more
876 on how to format this entry.
877
878 If there is a single file in your project, you can instead set the
879 @code{:spp-files} to a list of file names relative to the root of your
880 project. Specifying this is like setting the variable
881 @code{semantic-lex-c-preprocessor-symbol-file} in semantic.
882
883 If you want to override the file-finding tool with your own
884 function you can do this:
885
886 @example
887 (ede-cpp-root-project "NAME" :file "FILENAME" :locate-fcn 'MYFCN)
888 @end example
889
890 Where @var{MYFCN} is a symbol for a function. The locate function can
891 be used in place of @code{ede-expand-filename} so you can quickly
892 customize your custom target to use specialized local routines instead
893 of the default @ede{} routines. The function symbol must take two
894 arguments:
895
896 @table @var
897 @item NAME
898 The name of the file to find.
899 @item DIR
900 The directory root for this cpp-root project.
901 @end table
902
903 When creating a project with @code{ede-cpp-root}, you can get
904 additional configurations via @ref{Project Local Variables}. Be aware
905 that the format for project local variables is an association list.
906 You cannot use @kbd{M-x ede-set} and have your project local variables
907 persist between sessions.
908
909 If the cpp-root project style is right for you, but you want a dynamic
910 loader, instead of hard-coding path name values in your @file{.emacs}, you
911 can do that too, but you will need to write some lisp code.
912
913 To do that, you need to add an entry to the
914 @code{ede-project-class-files} list, and also provide two functions to
915 teach @ede{} how to load your project pattern
916
917 It would look like this:
918
919 @example
920 (defun MY-FILE-FOR-DIR (&optional dir)
921 "Return a full file name to the project file stored in DIR."
922 <write your code here, or return nil>
923 )
924
925 (defun MY-ROOT-FCN ()
926 "Return the root fcn for `default-directory'"
927 ;; You might be able to use `ede-cpp-root-project-root'
928 ;; and not write this at all.
929 )
930
931 (defun MY-LOAD (dir)
932 "Load a project of type `cpp-root' for the directory DIR.
933 Return nil if there isn't one."
934 ;; Use your preferred construction method here.
935 (ede-cpp-root-project "NAME" :file (expand-file-name "FILE" dir)
936 :locate-fcn 'MYFCN)
937 )
938
939 (add-to-list 'ede-project-class-files
940 (ede-project-autoload "cpp-root"
941 :name "CPP ROOT"
942 :file 'ede-cpp-root
943 :proj-file 'MY-FILE-FOR-DIR
944 :proj-root 'MY-ROOT-FCN
945 :load-type 'MY-LOAD
946 :class-sym 'ede-cpp-root)
947 t)
948 @end example
949
950 This example only creates an auto-loader, and does not create a new kind
951 of project.
952
953 @xref{ede-cpp-root-project}, for details about the class that defines
954 the @code{ede-cpp-root} project type.
955
956 @node ede-java-root, ede-emacs, ede-cpp-root, Simple projects
957 @subsection ede-java-root
958
959 Much like the project type @ref{ede-cpp-root}, the java variant is
960 can be setup in your @file{.emacs} file and just marks a directory as
961 the root of a java source tree.
962
963 The @code{ede-java-root} project class knows a few things about Java
964 projects. In particular, you can use it to control your classpath at
965 both the system level, and for your project. If it is insufficient,
966 you can subclass @code{ede-java-root-project} and add your own tweaks
967 in just a few lines. See @ref{ede-cpp-root} for an example using the
968 C++ variant.
969
970 In the most basic case, add this to your @file{.emacs} file, modifying
971 appropriate bits as needed.
972
973 @example
974 (ede-java-root-project "SOMENAME" :file "/dir/to/some/file" :srcroot '("src"))
975 @end example
976
977 Replace @var{SOMENAME} with whatever name you want, and the filename
978 to an actual file at the root of your project. It might be a
979 Makefile, a README file. Whatever. It doesn't matter. It's just a
980 key to hang the rest of @ede{} off of.
981
982 Replace the value of :srcroot with a list of directories under the
983 project root which contains Java sources. For example, if you have:
984
985 @example
986 ~/myprojects/P1/
987 ~/myprojects/P1/src/
988 ~/myprojects/P1/src/com/ericsoft/MyCode.java
989 ~/myprojects/P1/doc/
990 @end example
991
992 Then @file{src} represents the directory under which all your Java
993 code is. It is important that @file{src} is one step above the
994 directory that is the base of your package name, such as
995 @file{com/ericsoft} in the example above so that new files can be
996 discovered via fully qualified name. You can have multiple such
997 directories in one project, and each will be accessible.
998
999 You can specify your classpath like this:
1000
1001 @example
1002 (ede-java-root-project "NAME" :file "FILENAME"
1003 :srcroot '("src")
1004 :classpath '("/absolute/path.jar")
1005 :localclasspath '( "/relative/path.jar" ))
1006 @end example
1007
1008 In this example, @code{:classpath} specifies absolute paths somewhere
1009 on your system, and the explicit jar or source root directories
1010 @semantic{} will search when performing completions.
1011
1012 The @code{:localclasspath} is like @code{:classpath}, but it will
1013 contain path names relative to the root of your project.
1014
1015 If you want to override the file-finding tool with your own
1016 function you can do this:
1017
1018 @example
1019 (ede-java-root-project "NAME" :file "FILENAME" :locate-fcn 'MYFCN)
1020 @end example
1021
1022 Where @var{MYFCN} is a symbol for a function. The locate function can
1023 be used in place of @code{ede-expand-filename} so you can quickly
1024 customize your custom target to use specialized local routines instead
1025 of the default @ede{} routines. The function symbol must take two
1026 arguments:
1027
1028 @table @var
1029 @item NAME
1030 The name of the file to find.
1031 @item DIR
1032 The directory root for this java-root project.
1033 @end table
1034
1035 If you would like to create your Java projects dynamically, instead of
1036 putting them all in your @file{.emacs}, you can do that too. See
1037 @ref{ede-cpp-root} for details that can be applied to this project type.
1038
1039 @node ede-emacs, ede-linux, ede-java-root, Simple projects
1040 @subsection ede-emacs
1041
1042 The @code{ede-emacs} project automatically identifies an Emacs source
1043 tree, and enables EDE project mode for it.
1044
1045 It pre-populates the C Preprocessor symbol map for correct parsing,
1046 and has an optimized include file identification function.
1047
1048 @node ede-linux, Custom Locate, ede-emacs, Simple projects
1049 @subsection ede-linux
1050
1051 The @code{ede-linux} project will automatically identify a Linux
1052 Kernel source tree, and enable EDE project mode for it.
1053
1054 It pre-populates the C Preprocessor symbol map for reasonable parsing,
1055 and has an optimized include file identification function.
1056
1057 @node Custom Locate, , ede-linux, Simple projects
1058 @subsection Custom Locate
1059
1060 The various simple project styles all have one major drawback, which
1061 is that the files in the project are not completely known to EDE@.
1062 When the EDE API is used to try and file files by some reference name
1063 in the project, then that could fail.
1064
1065 @@TODO - Add ID Utils and CScope examples
1066
1067 @ede{} can therefore use some external locate commands, such as the unix
1068 ``locate'' command, or ``GNU Global''.
1069
1070 Configuration of the tool you want to use such as @code{locate}, or
1071 @code{global} will need to be done without the aid of @ede{}. Once
1072 configured, however, @ede{} can use it.
1073
1074 To enable one of these tools, set the variable
1075 @code{ede-locate-setup-options} with the names of different locate
1076 objects. @ref{Miscellaneous commands}.
1077
1078 Configure this in your @file{.emacs} before loading in CEDET or EDE@.
1079 If you want to add support for GNU Global, your configuration would
1080 look like this:
1081
1082 @example
1083 (setq ede-locate-setup-options '(ede-locate-global ede-locate-base))
1084 @end example
1085
1086 That way, when a search needs to be done, it will first try using
1087 GLOBAL@. If global is not available for that directory, then it will
1088 revert to the base locate object. The base object always fails to
1089 find a file.
1090
1091 You can add your own locate tool but subclassing from
1092 @code{ede-locate-base}. The subclass should also implement two
1093 methods. See the code in @file{ede-locate.el} for GNU Global as a
1094 simple example.
1095
1096 @node Extending EDE, GNU Free Documentation License, Miscellaneous commands, top
1097 @chapter Extending @ede{}
1098
1099 This chapter is intended for users who want to write new parts or fix
1100 bugs in @ede{}. A knowledge of Emacs Lisp, and some @eieio{}(CLOS) is
1101 required.
1102
1103 @ede{} uses @eieio{}, the CLOS package for Emacs, to define two object
1104 superclasses, specifically the PROJECT and TARGET@. All commands in
1105 @ede{} are usually meant to address the current project, or current
1106 target.
1107
1108 All specific projects in @ede{} derive subclasses of the @ede{}
1109 superclasses. In this way, specific behaviors such as how a project
1110 is saved, or how a target is compiled can be customized by a project
1111 author in detail. @ede{} communicates to these project objects via an
1112 API using methods. The commands you use in @ede{} mode are high-level
1113 functional wrappers over these methods. @xref{(eieio)Top}. For
1114 details on using @eieio{} to extending classes, and writing methods.
1115
1116 If you intend to extend @ede{}, it is most likely that a new target type is
1117 needed in one of the existing project types. The rest of this chapter
1118 will discuss extending the @code{ede-project} class, and it's targets.
1119 See @file{project-am.el} for basic details on adding targets to it.
1120
1121 For the @code{ede-project} type, the core target class is called
1122 @code{ede-proj-target}. Inheriting from this will give you everything
1123 you need to start, including adding your sources into the makefile. If
1124 you also need additional rules in the makefile, you will want to inherit
1125 from @code{ede-proj-target-makefile} instead. You may want to also add
1126 new fields to track important information.
1127
1128 If you are building currently unsupported code into a program or shared
1129 library, it is unlikely you need a new target at all. Instead you
1130 would need to create a new compiler or linker object that compiles
1131 source code of the desired type. @ref{Compiler and Linker objects}.
1132
1133 Once your new class exists, you will want to fill in some basic methods.
1134 See the @file{ede-skel.el} file for examples of these. The files
1135 @file{ede-proj-info.el} and @file{ede-proj-elisp.el} are two interesting
1136 examples.
1137
1138 @menu
1139 * Development Overview::
1140 * Detecting a Project::
1141 * User interface methods:: Methods associated with keybindings
1142 * Base project methods:: The most basic methods on @ede{} objects.
1143 * Sourcecode objects:: Defining new sourcecode classes.
1144 * Compiler and Linker objects:: Defining new compilers and linkers.
1145 * Project:: Details of project classes.
1146 * Targets:: Details of target classes.
1147 * Sourcecode:: Details of source code classes.
1148 * Compilers:: Details of compiler classes.
1149 @end menu
1150
1151 @node Development Overview, Detecting a Project, Extending EDE, Extending EDE
1152 @section Development Overview
1153
1154 @ede{} is made up of a series of classes implemented with @eieio{}.
1155 These classes define an interface that can be used to create different
1156 types of projects.
1157
1158 @ede{} defines two superclasses which are @code{ede-project} and
1159 @code{ede-target}. All commands in @ede{} are usually meant to
1160 address the current project, or current target.
1161
1162 All specific projects in @ede{} derive subclasses of the @ede{} superclasses.
1163 In this way, specific behaviors such as how a project is saved, or how a
1164 target is compiled can be customized by a project author in detail. @ede{}
1165 communicates to these project objects via an API using methods. The
1166 commands you use in @ede{} mode are high-level functional wrappers over
1167 these methods.
1168
1169 Some example project types are:
1170
1171 @table @code
1172 @item project-am
1173 Automake project which reads existing Automake files.
1174 @item ede-proj-project
1175 This project type will create @file{Makefiles},
1176 or @file{Makefile.am} files to compile your project.
1177 @item ede-linux
1178 This project type will detect linux source trees.
1179 @item ede-emacs
1180 This project will detect an Emacs source tree.
1181 @end table
1182
1183 There are several other project types as well.
1184
1185 The first class you need to know to create a new project type is
1186 @code{ede-project-autoload}. New instances of this class are needed
1187 to define how Emacs associates different files/buffers with different
1188 project types. All the autoloads are kept in the variable
1189 @code{ede-project-class-files}.
1190
1191 The next most important class to know is @code{ede-project}. This is
1192 the baseclass defines how all projects behave. The basic pattern for
1193 a project is that there is one project per directory, and the topmost
1194 project or directory defines the project as a whole.
1195
1196 Key features of @code{ede-project} are things like name and version
1197 number. It also holds a list of @code{ede-target} objects and a list
1198 of sub projects, or more @code{ede-project} objects.
1199
1200 New project types must subclass @code{ede-project} to add special
1201 behavior. New project types also need to subclass @code{ede-target} to
1202 add specialty behavior.
1203
1204 In this way, the common @ede{} interface is designed to work against
1205 @code{ede-project}, and thus all subclasses.
1206
1207 @code{ede-project} subclasses @code{ede-project-placeholder}. This is
1208 the minimum necessary project needed to be cached between runs of
1209 Emacs. This way, Emacs can track all projects ever seen, without
1210 loading those projects into memory.
1211
1212 Here is a high-level UML diagram for the @ede{} system created with @cogre{}..
1213
1214 @example
1215 +-----------------------+ +-----------------------+
1216 | | |ede-project-placeholder|
1217 |ede-project-class-files| +-----------------------+
1218 | | +-----------------------+
1219 +-----------------------+ +-----------------------+
1220 /\ ^
1221 \/ /_\
1222 | |
1223 +--------------------+ +-----------+ +----------+
1224 |ede-project-autoload| |ede-project| |ede-target|
1225 +--------------------+<>--------------+-----------+<>-------+----------+
1226 +--------------------+ +-----------+ +----------+
1227 +--------------------+ +-----------+ +----------+
1228 ^
1229 /_\
1230 |
1231 +---------------------+-----------------+
1232 | | |
1233 | | |
1234 | | |
1235 +----------------+ +-------------------+ +---------+
1236 |ede-proj-project| |project-am-makefile| |ede-emacs|
1237 +----------------+ +-------------------+ +---------+
1238 +----------------+ +-------------------+ +---------+
1239 +----------------+ +-------------------+ +---------+
1240 @end example
1241
1242
1243 @node Detecting a Project, User interface methods, Development Overview, Extending EDE
1244 @section Detecting a Project
1245
1246 Project detection happens with the list of @code{ede-project-autoload}
1247 instances stored in @code{ede-project-class-files}. The full project
1248 detection scheme works like this:
1249
1250 @table @asis
1251 @item Step 1:
1252 @code{find-file-hook} calls @code{ede-turn-on-hook} on BUFFER.
1253 @item Step 2:
1254 @code{ede-turn-on-hook} turns on @code{ede-minor-mode}
1255 @item Step 3:
1256 @code{ede-minor-mode} looks to see if BUFFER is associated with any
1257 open projects. If not, it calls @code{ede-load-project-file} to find
1258 a project associated with the current directory BUFFER is in.
1259 @item Step 4:
1260 @code{ede-minor-mode} associates the found project with the current
1261 buffer with a series of variables, such as @code{ede-object}, and
1262 @code{ede-object-project} and @code{ede-object-root-project}.
1263 @end table
1264
1265 Once a buffer is associated, @ede{} minor mode commands will operate
1266 on that buffer.
1267
1268 The function @code{ede-load-project-file} is at the heart of detecting
1269 projects, and it works by looping over all the known project autoload
1270 types in @code{ede-project-autoload} using the utility
1271 @code{ede-directory-project-p}.
1272
1273 The function @code{ede-directory-project-p} will call
1274 @code{ede-dir-to-projectfile} on every @code{ede-project-autoload}
1275 until one of them returns true. The method
1276 @code{ede-dir-to-projectfile} in turn gets the @code{:proj-file} slot
1277 from the autoload. If it is a string (i.e., a project file name), it
1278 checks to see if that exists in BUFFER's directory. If it is a
1279 function, then it calls that function and expects it to return a file
1280 name or nil. If the file exists, then this directory is assumed to be
1281 part of a project, and @code{ede-directory-project-p} returns the
1282 instance of @code{ede-project-autoload} that matched.
1283
1284 If the current directory contains the file @code{.ede-ignore} then
1285 that directory is automatically assumed to contain no projects, even
1286 if there is a matching pattern. Use this type of file in a directory
1287 that may contain many other sub projects, but still has a Makefile of
1288 some sort.
1289
1290 If the current directory is a project, then @ede{} scans upwards till
1291 it finds the top of the project. It does this by calling
1292 @code{ede-toplevel-project}. If this hasn't already been discovered,
1293 the directories as scanned upward one at a time until a directory with
1294 no project is found. The last found project becomes the project
1295 root. If the found instance of @code{ede-project-autoload} has a
1296 valid @code{proj-root} slot value, then that function is called instead
1297 of scanning the project by hand. Some project types have a short-cut
1298 for determining the root of a project, so this comes in handy.
1299
1300 Getting back to @code{ede-load-project-file}, this now has an instance
1301 of @code{ede-project-autoload}. It uses the @code{load-type} slot to
1302 both autoload in the project type, and to create a new instance of the
1303 project type found for the root of the project. That project is added
1304 to the global list of all projects. All subprojects are then created
1305 and assembled into the project data structures.
1306
1307
1308 @node User interface methods, Base project methods, Detecting a Project, Extending EDE
1309 @section User interface methods
1310
1311 These methods are core behaviors associated with user commands.
1312 If you do not implement a method, there is a reasonable default that
1313 may do what you need.
1314
1315 @table @code
1316 @item project-add-file
1317 Add a file to your project. Override this if you want to put new
1318 sources into different fields depending on extension, or other details.
1319 @item project-remove-file
1320 Reverse of project-add-file.
1321 @item project-compile-target
1322 Override this if you want to do something special when the user
1323 "compiles" this target.
1324 @item project-debug-target
1325 What to do when a user wants to debug your target.
1326 @item project-update-version
1327 Easily update the version number of your project.
1328 @item project-edit-file-target
1329 Edit the file the project's information is stored in.
1330 @item project-new-target
1331 Create a new target in a project.
1332 @item project-delete-target
1333 Delete a target from a project.
1334 @item project-make-dist
1335 Make a distribution (tar archive) of the project.
1336 @item project-rescan
1337 Rescan a project file, changing the data in the existing objects.
1338 @end table
1339
1340 @node Base project methods, Sourcecode objects, User interface methods, Extending EDE
1341 @section Base project methods
1342
1343 These methods are important for querying base information from project
1344 and target types:
1345
1346 @table @code
1347 @item ede-name
1348 Return a string that is the name of this target.
1349 @item ede-target-name
1350 Return a string that is the name of the target used by a Make system.
1351 @item ede-description
1352 A brief description of the project or target. This is currently used
1353 by the @samp{ede-speedbar} interface.
1354 @item ede-want-file-p
1355 Return non-nil if a target will accept a given file.
1356 It is generally unnecessary to override this. See the section on source
1357 code.
1358 @item ede-buffer-mine
1359 Return non-nil if a buffer belongs to this target. Used during
1360 association when a file is loaded. It is generally unnecessary to
1361 override this unless you keep auxiliary files.
1362 @end table
1363
1364 These methods are used by the semantic package extensions @xref{(semantic)Top}.
1365
1366 @table @code
1367 @item ede-buffer-header-file
1368 Return a header file belonging to a given buffer. Prototypes are place
1369 there when appropriate
1370 @item ede-buffer-documentation-files
1371 Return the documentation file information about this file would be
1372 stored in.
1373 @item ede-documentation
1374 List all documentation a project or target is responsible for.
1375 @end table
1376
1377 @node Sourcecode objects, Compiler and Linker objects, Base project methods, Extending EDE
1378 @section Sourcecode objects
1379
1380 @ede{} projects track source file / target associates via source code
1381 objects. The definitions for this is in @file{ede-source.el}. A source
1382 code object contains methods that know how to identify a file as being
1383 of that class, (i.e., a C file ends with @file{.c}). Some targets can
1384 handle many different types of sources which must all be compiled
1385 together. For example, a mixed C and C++ program would have
1386 instantiations of both sourcecode types.
1387
1388 When a target needs to know if it will accept a source file, it
1389 references its list of source code objects. These objects then make
1390 that decision.
1391
1392 Source code objects are stored in the target objects as a list of
1393 symbols, where the symbol's value is the object. This enables the
1394 project save file mechanism to work.
1395
1396 Here is an example for an instantiation of an Emacs Lisp source code object:
1397
1398 @example
1399 (defvar ede-source-emacs
1400 (ede-sourcecode "ede-emacs-source"
1401 :name "Emacs Lisp"
1402 :sourcepattern "\\.el$"
1403 :garbagepattern '("*.elc"))
1404 "Emacs Lisp source code definition.")
1405 @end example
1406
1407 If you want to recycle parts of an existing sourcecode object, you can
1408 clone the original, and then just tweak the parts that are different.
1409 For example:
1410
1411 @example
1412 (defvar ede-source-emacs-autoload
1413 (clone ede-source-emacs "ede-source-emacs-autoload"
1414 :name "Emacs Lisp Autoload"
1415 :sourcepattern "-loaddefs\\.el")
1416 "Emacs Lisp autoload source code.")
1417 @end example
1418
1419 In this case, the garbage pattern is the same.
1420
1421 @xref{Sourcecode}.
1422
1423 @node Compiler and Linker objects, Project, Sourcecode objects, Extending EDE
1424 @section Compiler and Linker objects
1425
1426 In order for a target to create a @file{Makefile}, it must know how to
1427 compile the sources into the program or desired data file, and
1428 possibly link them together.
1429
1430 A compiler object instantiation is used to associate a given target
1431 with a given source code type. Some targets can handle many types of
1432 sources, and thus has many compilers available to it. Some targets
1433 may have multiple compilers for a given type of source code.
1434
1435 @ede{} will examine the actual source files in a target, cross reference
1436 that against the compiler list to come up with the final set of
1437 compilers that will be inserted into the Makefile.
1438
1439 Compiler instantiations must also insert variables specifying the
1440 compiler it plans to use, in addition to creating Automake settings for
1441 @file{configure.ac} when appropriate.
1442
1443 Compiler objects are stored in the target objects as a list of
1444 symbols, where the symbols value is the object. This enables the
1445 project output mechanism to work more efficiently.
1446
1447 Targets will also have a special "compiler" slot which lets a user
1448 explicitly choose the compiler they want to use.
1449
1450 Here is an example for texinfo:
1451
1452 @example
1453 (defvar ede-makeinfo-compiler
1454 (ede-compiler
1455 "ede-makeinfo-compiler"
1456 :name "makeinfo"
1457 :variables '(("MAKEINFO" . "makeinfo"))
1458 :commands '("makeinfo -o $@ $<")
1459 :autoconf '(("AC_CHECK_PROG" . "MAKEINFO, makeinfo"))
1460 :sourcetype '(ede-makeinfo-source)
1461 )
1462 "Compile texinfo files into info files.")
1463 @end example
1464
1465 @xref{Compilers}.
1466
1467 When creating compiler instantiations, it may be useful to @code{clone}
1468 an existing compiler variable. Cloning allows you to only modify
1469 parts of the original, while keeping the rest of the same.
1470 Modification of the original will result in the clone also being
1471 changed for shared value slots.
1472
1473 The second important object is the linker class. The linker is similar
1474 to the compiler, except several compilers might be used to create some
1475 object files, and only one linker is used to link those objects together.
1476
1477 See @file{ede-proj-obj.el} for examples of the combination.
1478
1479 @defindex pj
1480 @defindex tg
1481 @defindex sc
1482 @defindex cm
1483
1484 @node Project, Targets, Compiler and Linker objects, Extending EDE
1485 @section Project
1486
1487 @menu
1488 * ede-project-placeholder::
1489 * ede-project::
1490 * ede-cpp-root-project::
1491 * ede-simple-project::
1492 * ede-simple-base-project::
1493 * ede-proj-project::
1494 * project-am-makefile::
1495 * ede-step-project::
1496 @end menu
1497
1498 @node ede-project-placeholder, ede-project, Project, Project
1499 @subsection ede-project-placeholder
1500 @pjindex ede-project-placeholder
1501
1502 @table @asis
1503 @item Inheritance Tree:
1504 @table @code
1505 @item eieio-speedbar
1506 @table @code
1507 @item eieio-speedbar-directory-button
1508 @table @code
1509 @item ede-project-placeholder
1510 @table @asis
1511 @item Children:
1512 @w{@xref{ede-project}.}
1513 @end table
1514 @end table
1515 @end table
1516 @end table
1517 @end table
1518
1519 @table @asis
1520 @item Slots:
1521
1522 @table @code
1523 @item :name
1524 Type: @code{string} @*
1525 Default Value: @code{"Untitled"}
1526
1527 The name used when generating distribution files.
1528 @refill
1529
1530 @item :version
1531 Type: @code{string} @*
1532 Default Value: @code{"1.0"}
1533
1534 The version number used when distributing files.
1535 @refill
1536
1537 @item :directory
1538 Type: @code{string}
1539
1540 Directory this project is associated with.
1541 @refill
1542
1543 @item :file
1544 Type: @code{string}
1545
1546 File name where this project is stored.
1547 @refill
1548
1549 @end table
1550
1551 @end table
1552
1553 @subsubsection Specialized Methods
1554
1555 @deffn Method ede--project-inode :AFTER proj
1556 Get the inode of the directory project @var{PROJ} is in.
1557 @end deffn
1558
1559 @deffn Method ede-project-root :AFTER this
1560 If a project knows it's root, return it here.
1561 Allows for one-project-object-for-a-tree type systems.
1562 @end deffn
1563
1564 @deffn Method ede-find-subproject-for-directory :AFTER proj dir
1565 Find a subproject of @var{PROJ} that corresponds to @var{DIR}.
1566 @end deffn
1567
1568 @deffn Method ede-project-root-directory :AFTER this &optional file
1569 If a project knows it's root, return it here.
1570 Allows for one-project-object-for-a-tree type systems.
1571 Optional @var{FILE} is the file to test. It is ignored in preference
1572 of the anchor file for the project.
1573 @end deffn
1574
1575 @deffn Method ede-project-force-load :AFTER this
1576 Make sure the placeholder @var{THIS} is replaced with the real thing.
1577 Return the new object created in its place.
1578 @end deffn
1579
1580 @deffn Method project-interactive-select-target :AFTER this prompt
1581 Make sure placeholder @var{THIS} is replaced with the real thing, and pass through.
1582 @end deffn
1583
1584 @deffn Method project-add-file :AFTER this file
1585 Make sure placeholder @var{THIS} is replaced with the real thing, and pass through.
1586 @end deffn
1587
1588 @node ede-project, ede-cpp-root-project, ede-project-placeholder, Project
1589 @subsection ede-project
1590 @pjindex ede-project
1591
1592 @table @asis
1593 @item Inheritance Tree:
1594 @table @code
1595 @item eieio-speedbar
1596 @table @code
1597 @item eieio-speedbar-directory-button
1598 @table @code
1599 @item @w{@xref{ede-project-placeholder}.}
1600 @table @code
1601 @item ede-project
1602 @table @asis
1603 @item Children:
1604 @w{@xref{ede-cpp-root-project},} @w{ede-emacs-project,} @w{ede-linux-project,} @w{ede-maven-project,} @w{@xref{ede-simple-project},} @w{@xref{ede-simple-base-project},} @w{@xref{ede-proj-project},} @w{@xref{project-am-makefile},} @w{@xref{ede-step-project}.}
1605 @end table
1606 @end table
1607 @end table
1608 @end table
1609 @end table
1610 @end table
1611
1612 @table @asis
1613 @item Slots:
1614
1615 @table @code
1616 @item :targets
1617 Type: @code{list}
1618
1619 List of top level targets in this project.
1620 @refill
1621
1622 @item :tool-cache
1623 Type: @code{list}
1624
1625 List of tool cache configurations in this project.
1626 This allows any tool to create, manage, and persist project-specific settings.
1627 @refill
1628
1629 @item :web-site-url
1630 Type: @code{string} @*
1631
1632 URL to this projects web site.
1633 This is a URL to be sent to a web site for documentation.
1634 @refill
1635
1636 @item :web-site-directory @*
1637
1638 A directory where web pages can be found by Emacs.
1639 For remote locations use a path compatible with ange-ftp or EFS@.
1640 You can also use TRAMP for use with rcp & scp.
1641 @refill
1642
1643 @item :web-site-file @*
1644
1645 A file which contains the home page for this project.
1646 This file can be relative to slot @code{web-site-directory}.
1647 This can be a local file, use ange-ftp, EFS, or TRAMP.
1648 @refill
1649
1650 @item :ftp-site
1651 Type: @code{string} @*
1652
1653 FTP site where this project's distribution can be found.
1654 This FTP site should be in Emacs form, as needed by @code{ange-ftp}, but can
1655 also be of a form used by TRAMP for use with scp, or rcp.
1656 @refill
1657
1658 @item :ftp-upload-site
1659 Type: @code{string} @*
1660
1661 FTP Site to upload new distributions to.
1662 This FTP site should be in Emacs form as needed by @code{ange-ftp}.
1663 If this slot is @code{nil}, then use @code{ftp-site} instead.
1664 @refill
1665
1666 @item :configurations
1667 Type: @code{list} @*
1668 Default Value: @code{("debug" "release")}
1669
1670 List of available configuration types.
1671 Individual target/project types can form associations between a configuration,
1672 and target specific elements such as build variables.
1673 @refill
1674
1675 @item :configuration-default @*
1676 Default Value: @code{"debug"}
1677
1678 The default configuration.
1679 @refill
1680
1681 @item :local-variables @*
1682 Default Value: @code{nil}
1683
1684 Project local variables
1685 @refill
1686
1687 @end table
1688
1689 @end table
1690 @subsubsection Specialized Methods
1691
1692 @deffn Method ede-preprocessor-map :AFTER this
1693 Get the pre-processor map for project @var{THIS}.
1694 @end deffn
1695
1696 @deffn Method ede-subproject-relative-path :AFTER proj &optional parent-in
1697 Get a path name for @var{PROJ} which is relative to the parent project.
1698 If PARENT is specified, then be relative to the PARENT project.
1699 Specifying PARENT is useful for sub-sub projects relative to the root project.
1700 @end deffn
1701
1702 @deffn Method eieio-speedbar-description :AFTER obj
1703 Provide a speedbar description for @var{OBJ}.
1704 @end deffn
1705
1706 @deffn Method ede-map-any-target-p :AFTER this proc
1707 For project @var{THIS}, map @var{PROC} to all targets and return if any non-nil.
1708 Return the first non-@code{nil} value returned by @var{PROC}.
1709 @end deffn
1710
1711 @deffn Method ede-map-subprojects :AFTER this proc
1712 For object @var{THIS}, execute @var{PROC} on all direct subprojects.
1713 This function does not apply @var{PROC} to sub-sub projects.
1714 See also @dfn{ede-map-all-subprojects}.
1715 @end deffn
1716
1717 @deffn Method ede-convert-path :AFTER this path
1718 Convert path in a standard way for a given project.
1719 Default to making it project relative.
1720 Argument @var{THIS} is the project to convert @var{PATH} to.
1721 @end deffn
1722
1723 @deffn Method ede-name :AFTER this
1724 Return a short-name for @var{THIS} project file.
1725 Do this by extracting the lowest directory name.
1726 @end deffn
1727
1728 @deffn Method ede-set-project-variables :AFTER project &optional buffer
1729 Set variables local to @var{PROJECT} in @var{BUFFER}.
1730 @end deffn
1731
1732 @deffn Method eieio-speedbar-derive-line-path :AFTER obj &optional depth
1733 Return the path to @var{OBJ}.
1734 Optional @var{DEPTH} is the depth we start at.
1735 @end deffn
1736
1737 @deffn Method ede-map-all-subprojects :AFTER this allproc
1738 For object @var{THIS}, execute PROC on @var{THIS} and all subprojects.
1739 This function also applies PROC to sub-sub projects.
1740 See also @dfn{ede-map-subprojects}.
1741 @end deffn
1742
1743 @deffn Method project-update-version :AFTER ot
1744 The @code{:version} of the project @var{OT} has been updated.
1745 Handle saving, or other detail.
1746 @end deffn
1747
1748 @deffn Method ede-buffer-header-file :AFTER this buffer
1749 Return @code{nil}, projects don't have header files.
1750 @end deffn
1751
1752 @deffn Method ede-buffer-documentation-files :AFTER this buffer
1753 Return all documentation in project @var{THIS} based on @var{BUFFER}.
1754 @end deffn
1755
1756 @deffn Method ede-map-targets :AFTER this proc
1757 For object @var{THIS}, execute @var{PROC} on all targets.
1758 @end deffn
1759
1760 @deffn Method ede-buffer-mine :AFTER this buffer
1761 Return non-@code{nil} if object @var{THIS} lays claim to the file in @var{BUFFER}.
1762 @end deffn
1763
1764 @deffn Method ede-object-keybindings :BEFORE this
1765 Retrieves the slot @code{keybindings} from an object of class @code{ede-project}
1766 @end deffn
1767
1768 @deffn Method ede-description :AFTER this
1769 Return a description suitable for the minibuffer about @var{THIS}.
1770 @end deffn
1771
1772 @deffn Method eieio-speedbar-object-children :AFTER this
1773 Return the list of speedbar display children for @var{THIS}.
1774 @end deffn
1775
1776 @deffn Method project-make-dist :AFTER this
1777 Build a distribution for the project based on @var{THIS} project.
1778 @end deffn
1779
1780 @deffn Method ede-system-include-path :AFTER this
1781 Get the system include path used by project @var{THIS}.
1782 @end deffn
1783
1784 @deffn Method project-new-target-custom :AFTER proj
1785 Create a new target. It is up to the project @var{PROJ} to get the name.
1786 @end deffn
1787
1788 @deffn Method ede-subproject-p :AFTER proj
1789 Return non-@code{nil} if @var{PROJ} is a sub project.
1790 @end deffn
1791
1792 @deffn Method ede-expand-filename :AFTER this filename &optional force
1793 Return a fully qualified file name based on project @var{THIS}.
1794 @var{FILENAME} should be just a filename which occurs in a directory controlled
1795 by this project.
1796 Optional argument @var{FORCE} forces the default filename to be provided even if it
1797 doesn't exist.
1798 @end deffn
1799
1800 @deffn Method ede-menu-items-build :AFTER obj &optional current
1801 Return a list of menu items for building project @var{OBJ}.
1802 If optional argument @var{CURRENT} is non-@code{nil}, return sub-menu code.
1803 @end deffn
1804
1805 @deffn Method ede-update-version-in-source :AFTER this version
1806 Change occurrences of a version string in sources.
1807 In project @var{THIS}, cycle over all targets to give them a chance to set
1808 their sources to @var{VERSION}.
1809 @end deffn
1810
1811 @deffn Method project-new-target :AFTER proj &rest args
1812 Create a new target. It is up to the project @var{PROJ} to get the name.
1813 @end deffn
1814
1815 @deffn Method project-compile-project :AFTER obj &optional command
1816 Compile the entire current project @var{OBJ}.
1817 Argument @var{COMMAND} is the command to use when compiling.
1818 @end deffn
1819
1820 @deffn Method eieio-speedbar-object-buttonname :AFTER object
1821 Return a string to use as a speedbar button for @var{OBJECT}.
1822 @end deffn
1823
1824 @deffn Method ede-map-project-buffers :AFTER this proc
1825 For @var{THIS}, execute @var{PROC} on all buffers belonging to @var{THIS}.
1826 @end deffn
1827
1828 @deffn Method ede-expand-filename-impl :AFTER this filename &optional force
1829 Return a fully qualified file name based on project @var{THIS}.
1830 @var{FILENAME} should be just a filename which occurs in a directory controlled
1831 by this project.
1832 Optional argument @var{FORCE} forces the default filename to be provided even if it
1833 doesn't exist.
1834 @end deffn
1835
1836 @deffn Method eieio-done-customizing :AFTER proj
1837 Call this when a user finishes customizing @var{PROJ}.
1838 @end deffn
1839
1840 @deffn Method ede-html-documentation :AFTER this
1841 Return a list of HTML files provided by project @var{THIS}.
1842 @end deffn
1843
1844 @deffn Method ede-documentation :AFTER this
1845 Return a list of files that provides documentation.
1846 Documentation is not for object @var{THIS}, but is provided by @var{THIS} for other
1847 files in the project.
1848 @end deffn
1849
1850 @deffn Method project-interactive-select-target :AFTER this prompt
1851 Interactively query for a target that exists in project @var{THIS}.
1852 Argument @var{PROMPT} is the prompt to use when querying the user for a target.
1853 @end deffn
1854
1855 @deffn Method ede-target-in-project-p :AFTER proj target
1856 Is @var{PROJ} the parent of @var{TARGET}?
1857 If @var{TARGET} belongs to a subproject, return that project file.
1858 @end deffn
1859
1860 @deffn Method ede-find-target :AFTER proj buffer
1861 Fetch the target in @var{PROJ} belonging to @var{BUFFER} or nil.
1862 @end deffn
1863
1864 @deffn Method ede-add-subproject :AFTER proj-a proj-b
1865 Add into @var{PROJ-A}, the subproject @var{PROJ-B}.
1866 @end deffn
1867
1868 @deffn Method ede-commit-project :AFTER proj
1869 Commit any change to @var{PROJ} to its file.
1870 @end deffn
1871
1872 @deffn Method project-dist-files :AFTER this
1873 Return a list of files that constitutes a distribution of @var{THIS} project.
1874 @end deffn
1875
1876 @deffn Method ede-object-menu :BEFORE this
1877 Retrieves the slot @code{menu} from an object of class @code{ede-project}
1878 @end deffn
1879
1880 @deffn Method ede-commit-local-variables :AFTER proj
1881 Commit change to local variables in @var{PROJ}.
1882 @end deffn
1883
1884 @node ede-cpp-root-project, ede-simple-project, ede-project, Project
1885 @subsection ede-cpp-root-project
1886 @pjindex ede-cpp-root-project
1887
1888 @table @asis
1889 @item Inheritance Tree:
1890 @table @code
1891 @item eieio-speedbar
1892 @table @code
1893 @item eieio-speedbar-directory-button
1894 @table @code
1895 @item @w{@xref{ede-project-placeholder}.}
1896 @table @code
1897 @item @w{@xref{ede-project}.}
1898 @table @code
1899 @item ede-cpp-root-project
1900 No children
1901 @end table
1902 @end table
1903 @end table
1904 @end table
1905 @end table
1906 @end table
1907
1908 This class implements the @code{ede-cpp-root} project type.
1909 @xref{ede-cpp-root}, for information about using this project type.
1910
1911 @table @asis
1912 @item Slots:
1913
1914 @table @code
1915 @item :include-path
1916 Type: @code{list} @*
1917 Default Value: @code{(quote ("/include" "../include/"))}
1918
1919 The default locate function expands filenames within a project.
1920 If a header file (.h, .hh, etc) name is expanded, and
1921 the @code{:locate-fcn} slot is @code{nil}, then the include path is checked
1922 first, and other directories are ignored. For very large
1923 projects, this optimization can save a lot of time.
1924
1925 Directory names in the path can be relative to the current
1926 buffer's @code{default-directory} (not starting with a /). Directories
1927 that are relative to the project's root should start with a /, such
1928 as "/include", meaning the directory @code{include} off the project root
1929 directory.
1930 @refill
1931
1932 @item :system-include-path
1933 Type: @code{list} @*
1934 Default Value: @code{nil}
1935
1936 The system include path for files in this project.
1937 C files initialized in an ede-cpp-root-project have their semantic
1938 system include path set to this value. If this is @code{nil}, then the
1939 semantic path is not modified.
1940 @refill
1941
1942 @item :spp-table
1943 Type: @code{list} @*
1944 Default Value: @code{nil}
1945
1946 C Preprocessor macros for your files.
1947 Preprocessor symbols will be used while parsing your files.
1948 These macros might be passed in through the command line compiler, or
1949 are critical symbols derived from header files. Providing header files
1950 macro values through this slot improves accuracy and performance.
1951 Use `:spp-files' to use these files directly.
1952 @refill
1953
1954 @item :spp-files
1955 Type: @code{list} @*
1956 Default Value: @code{nil}
1957
1958 C header file with Preprocessor macros for your files.
1959 The PreProcessor symbols appearing in these files will be used while
1960 parsing files in this project.
1961 See @code{semantic-lex-c-preprocessor-symbol-map} for more on how this works.
1962 @refill
1963
1964 @item :header-match-regexp
1965 Type: @code{string} @*
1966 Default Value: @code{"\\.\\(h\\(h\\|xx\\|pp\\|\\+\\+\\)?\\|H\\)$\\|\\<\\w+$"}
1967
1968 Regexp used to identify C/C++ header files.
1969 @refill
1970
1971 @item :locate-fcn
1972 Type: @code{(or null function)} @*
1973 Default Value: @code{nil}
1974
1975 The locate function can be used in place of
1976 @dfn{ede-expand-filename} so you can quickly customize your custom target
1977 to use specialized local routines instead of the EDE routines.
1978 The function symbol must take two arguments:
1979 NAME - The name of the file to find.
1980 DIR - The directory root for this cpp-root project.
1981
1982 It should return the fully qualified file name passed in from NAME@. If that file does not
1983 exist, it should return nil.
1984 @refill
1985
1986 @end table
1987
1988 @end table
1989 @subsubsection Specialized Methods
1990
1991 @deffn Method initialize-instance :AFTER this &rest fields
1992 Make sure the @code{:file} is fully expanded.
1993 @end deffn
1994
1995 @deffn Method ede-preprocessor-map :AFTER this
1996 Get the pre-processor map for project @var{THIS}.
1997 @end deffn
1998
1999 @deffn Method ede-cpp-root-header-file-p :AFTER proj name
2000 Non @code{nil} if in @var{PROJ} the filename @var{NAME} is a header.
2001 @end deffn
2002
2003 @deffn Method ede-system-include-path :AFTER this
2004 Get the system include path used by project @var{THIS}.
2005 @end deffn
2006
2007 @deffn Method ede-expand-filename-impl :AFTER proj name
2008 Within this project @var{PROJ}, find the file @var{NAME}.
2009 This knows details about or source tree.
2010 @end deffn
2011
2012 @node ede-simple-project, ede-simple-base-project, ede-cpp-root-project, Project
2013 @subsection ede-simple-project
2014 @pjindex ede-simple-project
2015
2016 @table @asis
2017 @item Inheritance Tree:
2018 @table @code
2019 @item eieio-speedbar
2020 @table @code
2021 @item eieio-speedbar-directory-button
2022 @table @code
2023 @item @w{@xref{ede-project-placeholder}.}
2024 @table @code
2025 @item @w{@xref{ede-project}.}
2026 @table @code
2027 @item ede-simple-project
2028 No children
2029 @end table
2030 @end table
2031 @end table
2032 @end table
2033 @end table
2034 @end table
2035
2036 @subsubsection Specialized Methods
2037
2038 @deffn Method ede-commit-project :AFTER proj
2039 Commit any change to @var{PROJ} to its file.
2040 @end deffn
2041
2042 @node ede-simple-base-project, ede-proj-project, ede-simple-project, Project
2043 @subsection ede-simple-base-project
2044 @pjindex ede-simple-base-project
2045
2046 @table @asis
2047 @item Inheritance Tree:
2048 @table @code
2049 @item eieio-speedbar
2050 @table @code
2051 @item eieio-speedbar-directory-button
2052 @table @code
2053 @item @w{@xref{ede-project-placeholder}.}
2054 @table @code
2055 @item @w{@xref{ede-project}.}
2056 @table @code
2057 @item ede-simple-base-project
2058 No children
2059 @end table
2060 @end table
2061 @end table
2062 @end table
2063 @end table
2064 @end table
2065
2066 EDE Simple project base class.
2067 This one project could control a tree of subdirectories.
2068
2069 @table @asis
2070 @end table
2071
2072 @node ede-proj-project, project-am-makefile, ede-simple-base-project, Project
2073 @subsection ede-proj-project
2074 @pjindex ede-proj-project
2075
2076 @table @asis
2077 @item Inheritance Tree:
2078 @table @code
2079 @item eieio-speedbar
2080 @table @code
2081 @item eieio-speedbar-directory-button
2082 @table @code
2083 @item @w{@xref{ede-project-placeholder}.}
2084 @table @code
2085 @item @w{@xref{ede-project}.}
2086 @table @code
2087 @item ede-proj-project
2088 No children
2089 @end table
2090 @end table
2091 @end table
2092 @end table
2093 @end table
2094 @end table
2095
2096 @table @asis
2097 @item Slots:
2098
2099 @table @code
2100 @item :makefile-type
2101 Type: @code{symbol} @*
2102 Default Value: @code{Makefile}
2103
2104 The type of Makefile to generate.
2105 Can be one of @code{'Makefile}, 'Makefile.in, or 'Makefile.am.
2106 If this value is NOT @code{'Makefile}, then that overrides the @code{:makefile} slot
2107 in targets.
2108 @refill
2109
2110 @item :variables
2111 Type: @code{list} @*
2112 Default Value: @code{nil}
2113
2114 Variables to set in this Makefile.
2115 @refill
2116
2117 @item :configuration-variables
2118 Type: @code{list} @*
2119 Default Value: @code{("debug" (("DEBUG" . "1")))}
2120
2121 Makefile variables to use in different configurations.
2122 These variables are used in the makefile when a configuration becomes active.
2123 @refill
2124
2125 @item :inference-rules @*
2126 Default Value: @code{nil}
2127
2128 Inference rules to add to the makefile.
2129 @refill
2130
2131 @item :include-file @*
2132 Default Value: @code{nil}
2133
2134 Additional files to include.
2135 These files can contain additional rules, variables, and customizations.
2136 @refill
2137
2138 @item :automatic-dependencies
2139 Type: @code{boolean} @*
2140 Default Value: @code{t}
2141
2142 Non-@code{nil} to do implement automatic dependencies in the Makefile.
2143 @refill
2144
2145 @item :metasubproject
2146 Type: @code{boolean} @*
2147 Default Value: @code{nil}
2148
2149 Non-@code{nil} if this is a metasubproject.
2150 Usually, a subproject is determined by a parent project. If multiple top level
2151 projects are grouped into a large project not maintained by EDE, then you need
2152 to set this to non-nil. The only effect is that the @code{dist} rule will then avoid
2153 making a tar file.
2154 @refill
2155
2156 @end table
2157
2158 @end table
2159 @subsubsection Specialized Methods
2160
2161 @deffn Method ede-proj-makefile-create :AFTER this mfilename
2162 Create a Makefile for all Makefile targets in @var{THIS}.
2163 @var{MFILENAME} is the makefile to generate.
2164 @end deffn
2165
2166 @deffn Method ede-proj-makefile-insert-rules :AFTER this
2167 Insert rules needed by @var{THIS} target.
2168 @end deffn
2169
2170 @deffn Method ede-proj-makefile-tags :AFTER this targets
2171 Insert into the current location rules to make recursive TAGS files.
2172 Argument @var{THIS} is the project to create tags for.
2173 Argument @var{TARGETS} are the targets we should depend on for TAGS.
2174 @end deffn
2175
2176 @deffn Method ede-proj-makefile-insert-variables :AFTER this
2177 Insert variables needed by target @var{THIS}.
2178 @end deffn
2179
2180 @deffn Method project-make-dist :AFTER this
2181 Build a distribution for the project based on @var{THIS} target.
2182 @end deffn
2183
2184 @deffn Method ede-proj-makefile-insert-dist-rules :AFTER this
2185 Insert distribution rules for @var{THIS} in a Makefile, such as CLEAN and DIST.
2186 @end deffn
2187
2188 @deffn Method ede-proj-makefile-insert-dist-dependencies :AFTER this
2189 Insert any symbols that the DIST rule should depend on.
2190 Argument @var{THIS} is the project that should insert stuff.
2191 @end deffn
2192
2193 @deffn Method ede-proj-makefile-insert-subproj-rules :AFTER this
2194 Insert a rule for the project @var{THIS} which should be a subproject.
2195 @end deffn
2196
2197 @deffn Method ede-proj-makefile-create-maybe :AFTER this mfilename
2198 Create a Makefile for all Makefile targets in @var{THIS} if needed.
2199 @var{MFILENAME} is the makefile to generate.
2200 @end deffn
2201
2202 @deffn Method ede-proj-configure-test-required-file :AFTER this file
2203 For project @var{THIS}, test that the file @var{FILE} exists, or create it.
2204 @end deffn
2205
2206 @deffn Method ede-proj-setup-buildenvironment :AFTER this &optional force
2207 Setup the build environment for project @var{THIS}.
2208 Handles the Makefile, or a Makefile.am configure.ac combination.
2209 Optional argument @var{FORCE} will force items to be regenerated.
2210 @end deffn
2211
2212 @deffn Method ede-proj-makefile-garbage-patterns :AFTER this
2213 Return a list of patterns that are considered garbage to @var{THIS}.
2214 These are removed with make clean.
2215 @end deffn
2216
2217 @deffn Method ede-proj-configure-synchronize :AFTER this
2218 Synchronize what we know about project @var{THIS} into configure.ac.
2219 @end deffn
2220
2221 @deffn Method ede-proj-makefile-insert-variables-new :AFTER this
2222 Insert variables needed by target @var{THIS}.
2223
2224 NOTE: Not yet in use! This is part of an SRecode conversion of
2225 EDE that is in progress.
2226 @end deffn
2227
2228 @deffn Method ede-proj-makefile-configuration-variables :AFTER this configuration
2229 Return a list of configuration variables from @var{THIS}.
2230 Use @var{CONFIGURATION} as the current configuration to query.
2231 @end deffn
2232
2233 @deffn Method eieio-done-customizing :AFTER proj
2234 Call this when a user finishes customizing this object.
2235 Argument @var{PROJ} is the project to save.
2236 @end deffn
2237
2238 @deffn Method ede-proj-configure-recreate :AFTER this
2239 Delete project @var{THIS}'s configure script and start over.
2240 @end deffn
2241
2242 @deffn Method ede-proj-makefile-insert-user-rules :AFTER this
2243 Insert user specified rules needed by @var{THIS} target.
2244 This is different from @dfn{ede-proj-makefile-insert-rules} in that this
2245 function won't create the building rules which are auto created with
2246 automake.
2247 @end deffn
2248
2249 @deffn Method ede-proj-dist-makefile :AFTER this
2250 Return the name of the Makefile with the DIST target in it for @var{THIS}.
2251 @end deffn
2252
2253 @deffn Method ede-proj-configure-file :AFTER this
2254 The configure.ac script used by project @var{THIS}.
2255 @end deffn
2256
2257 @deffn Method ede-commit-project :AFTER proj
2258 Commit any change to @var{PROJ} to its file.
2259 @end deffn
2260
2261 @deffn Method project-dist-files :AFTER this
2262 Return a list of files that constitutes a distribution of @var{THIS} project.
2263 @end deffn
2264
2265 @deffn Method ede-commit-local-variables :AFTER proj
2266 Commit change to local variables in @var{PROJ}.
2267 @end deffn
2268
2269 @node project-am-makefile, ede-step-project, ede-proj-project, Project
2270 @subsection project-am-makefile
2271 @pjindex project-am-makefile
2272
2273 @table @asis
2274 @item Inheritance Tree:
2275 @table @code
2276 @item eieio-speedbar
2277 @table @code
2278 @item eieio-speedbar-directory-button
2279 @table @code
2280 @item @w{@xref{ede-project-placeholder}.}
2281 @table @code
2282 @item @w{@xref{ede-project}.}
2283 @table @code
2284 @item project-am-makefile
2285 No children
2286 @end table
2287 @end table
2288 @end table
2289 @end table
2290 @end table
2291 @end table
2292
2293 @subsubsection Specialized Methods
2294
2295 @deffn Method project-am-subtree :AFTER ampf subdir
2296 Return the sub project in @var{AMPF} specified by @var{SUBDIR}.
2297 @end deffn
2298
2299 @deffn Method project-targets-for-file :AFTER proj
2300 Return a list of targets the project @var{PROJ}.
2301 @end deffn
2302
2303 @deffn Method project-new-target :AFTER proj &optional name type
2304 Create a new target named @var{NAME}.
2305 Argument @var{TYPE} is the type of target to insert. This is a string
2306 matching something in @code{project-am-type-alist} or type class symbol.
2307 Despite the fact that this is a method, it depends on the current
2308 buffer being in order to provide a smart default target type.
2309 @end deffn
2310
2311 @node ede-step-project, , project-am-makefile, Project
2312 @subsection ede-step-project
2313 @pjindex ede-step-project
2314
2315 @table @asis
2316 @item Inheritance Tree:
2317 @table @code
2318 @item eieio-speedbar
2319 @table @code
2320 @item eieio-speedbar-directory-button
2321 @table @code
2322 @item @w{@xref{ede-project-placeholder}.}
2323 @table @code
2324 @item @w{@xref{ede-project}.}
2325 @table @code
2326 @item ede-step-project
2327 No children
2328 @end table
2329 @end table
2330 @end table
2331 @end table
2332 @end table
2333 @end table
2334
2335 @table @asis
2336 @item Slots:
2337
2338 @table @code
2339 @item :init-variables
2340 Type: @code{list} @*
2341 Default Value: @code{nil}
2342
2343 Variables to set in this Makefile, at top of file.
2344 @refill
2345
2346 @item :additional-variables
2347 Type: @code{(or null list)} @*
2348 Default Value: @code{nil}
2349
2350 Arbitrary variables needed from this project.
2351 It is safe to leave this blank.
2352 @refill
2353
2354 @item :additional-rules
2355 Type: @code{(or null list)} @*
2356 Default Value: @code{nil}
2357
2358 Arbitrary rules and dependencies needed to make this target.
2359 It is safe to leave this blank.
2360 @refill
2361
2362 @item :installation-domain
2363 Type: @code{symbol} @*
2364 Default Value: @code{user}
2365
2366 Installation domain specification.
2367 The variable GNUSTEP_INSTALLATION_DOMAIN is set at this value.
2368 @refill
2369
2370 @item :preamble
2371 Type: @code{(or null list)} @*
2372 Default Value: @code{(quote ("GNUmakefile.preamble"))}
2373
2374 The auxiliary makefile for additional variables.
2375 Included just before the specific target files.
2376 @refill
2377
2378 @item :postamble
2379 Type: @code{(or null list)} @*
2380 Default Value: @code{(quote ("GNUmakefile.postamble"))}
2381
2382 The auxiliary makefile for additional rules.
2383 Included just after the specific target files.
2384 @refill
2385
2386 @item :metasubproject
2387 Type: @code{boolean} @*
2388 Default Value: @code{nil}
2389
2390 Non-@code{nil} if this is a metasubproject.
2391 Usually, a subproject is determined by a parent project. If multiple top level
2392 projects are grouped into a large project not maintained by EDE, then you need
2393 to set this to non-nil. The only effect is that the @code{dist} rule will then avoid
2394 making a tar file.
2395 @refill
2396
2397 @end table
2398
2399 @end table
2400 @subsubsection Specialized Methods
2401
2402 @deffn Method ede-proj-makefile-create :AFTER this mfilename
2403 Create a GNUmakefile for all Makefile targets in @var{THIS}.
2404 @var{MFILENAME} is the makefile to generate.
2405 @end deffn
2406
2407 @deffn Method project-make-dist :AFTER this
2408 Build a distribution for the project based on @var{THIS} target.
2409 @end deffn
2410
2411 @deffn Method ede-proj-makefile-create-maybe :AFTER this mfilename
2412 Create a Makefile for all Makefile targets in @var{THIS} if needed.
2413 @var{MFILENAME} is the makefile to generate.
2414 @end deffn
2415
2416 @deffn Method ede-proj-setup-buildenvironment :AFTER this &optional force
2417 Setup the build environment for project @var{THIS}.
2418 Handles the Makefile, or a Makefile.am configure.ac combination.
2419 Optional argument @var{FORCE} will force items to be regenerated.
2420 @end deffn
2421
2422 @deffn Method eieio-done-customizing :AFTER proj
2423 Call this when a user finishes customizing this object.
2424 Argument @var{PROJ} is the project to save.
2425 @end deffn
2426
2427 @deffn Method ede-proj-dist-makefile :AFTER this
2428 Return the name of the Makefile with the DIST target in it for @var{THIS}.
2429 @end deffn
2430
2431 @deffn Method ede-commit-project :AFTER proj
2432 Commit any change to @var{PROJ} to its file.
2433 @end deffn
2434
2435 @deffn Method project-dist-files :AFTER this
2436 Return a list of files that constitutes a distribution of @var{THIS} project.
2437 @end deffn
2438
2439 @deffn Method ede-commit-local-variables :AFTER proj
2440 Commit change to local variables in @var{PROJ}.
2441 @end deffn
2442
2443 @node Targets, Sourcecode, Project, Extending EDE
2444 @section Targets
2445
2446 @menu
2447 * ede-target::
2448 * ede-proj-target::
2449 * ede-proj-target-makefile::
2450 * semantic-ede-proj-target-grammar::
2451 * ede-proj-target-makefile-objectcode::
2452 * ede-proj-target-makefile-archive::
2453 * ede-proj-target-makefile-program::
2454 * ede-proj-target-makefile-shared-object::
2455 * ede-proj-target-elisp::
2456 * ede-proj-target-elisp-autoloads::
2457 * ede-proj-target-makefile-miscelaneous::
2458 * ede-proj-target-makefile-info::
2459 * ede-proj-target-scheme::
2460 * project-am-target::
2461 * project-am-objectcode::
2462 * project-am-program::
2463 * project-am-header-noinst::
2464 * project-am-header-inst::
2465 * project-am-lisp::
2466 * project-am-texinfo::
2467 * project-am-man::
2468 @end menu
2469
2470
2471 @node ede-target, ede-proj-target, Targets, Targets
2472 @subsection ede-target
2473 @tgindex ede-target
2474
2475 @table @asis
2476 @item Inheritance Tree:
2477 @table @code
2478 @item eieio-speedbar
2479 @table @code
2480 @item eieio-speedbar-directory-button
2481 @table @code
2482 @item ede-target
2483 @table @asis
2484 @item Children:
2485 @w{ede-cpp-root-target,} @w{ede-emacs-target-c,} @w{ede-emacs-target-el,} @w{ede-emacs-target-misc,} @w{ede-linux-target-c,} @w{ede-linux-target-misc,} @w{ede-maven-target-java,} @w{ede-maven-target-c,} @w{ede-maven-target-misc,} @w{ede-simple-target,} @w{@xref{ede-proj-target},} @w{@xref{project-am-target}.}
2486 @end table
2487 @end table
2488 @end table
2489 @end table
2490 @end table
2491
2492 @table @asis
2493 @item Slots:
2494
2495 @table @code
2496 @item :name
2497 Type: @code{string}
2498
2499 Name of this target.
2500 @refill
2501
2502 @item :path
2503 Type: @code{string}
2504
2505 The path to the sources of this target.
2506 Relative to the path of the project it belongs to.
2507 @refill
2508
2509 @item :source
2510 Type: @code{list} @*
2511 Default Value: @code{nil}
2512
2513 Source files in this target.
2514 @refill
2515
2516 @item :versionsource
2517 Type: @code{list} @*
2518 Default Value: @code{nil}
2519
2520 Source files with a version string in them.
2521 These files are checked for a version string whenever the EDE version
2522 of the master project is changed. When strings are found, the version
2523 previously there is updated.
2524 @refill
2525
2526 @end table
2527
2528 @end table
2529 @subsubsection Specialized Methods
2530
2531 @deffn Method ede-preprocessor-map :AFTER this
2532 Get the pre-processor map for project @var{THIS}.
2533 @end deffn
2534
2535 @deffn Method eieio-speedbar-description :AFTER obj
2536 Provide a speedbar description for @var{OBJ}.
2537 @end deffn
2538
2539 @deffn Method project-compile-target :AFTER obj &optional command
2540 Compile the current target @var{OBJ}.
2541 Argument @var{COMMAND} is the command to use for compiling the target.
2542 @end deffn
2543
2544 @deffn Method project-debug-target :AFTER obj
2545 Run the current project target @var{OBJ} in a debugger.
2546 @end deffn
2547
2548 @deffn Method ede-convert-path :AFTER this path
2549 Convert path in a standard way for a given project.
2550 Default to making it project relative.
2551 Argument @var{THIS} is the project to convert @var{PATH} to.
2552 @end deffn
2553
2554 @deffn Method ede-name :AFTER this
2555 Return the name of @var{THIS} targt.
2556 @end deffn
2557
2558 @deffn Method ede-target-buffer-in-sourcelist :AFTER this buffer source
2559 Return non-@code{nil} if object @var{THIS} is in @var{BUFFER} to a @var{SOURCE} list.
2560 Handles complex path issues.
2561 @end deffn
2562
2563 @deffn Method eieio-speedbar-derive-line-path :AFTER obj &optional depth
2564 Return the path to @var{OBJ}.
2565 Optional @var{DEPTH} is the depth we start at.
2566 @end deffn
2567
2568 @deffn Method ede-buffer-header-file :AFTER this buffer
2569 There are no default header files in EDE@.
2570 Do a quick check to see if there is a Header tag in this buffer.
2571 @end deffn
2572
2573 @deffn Method project-remove-file :AFTER ot fnnd
2574 Remove the current buffer from project target @var{OT}.
2575 Argument @var{FNND} is an argument.
2576 @end deffn
2577
2578 @deffn Method ede-buffer-documentation-files :AFTER this buffer
2579 Check for some documentation files for @var{THIS}.
2580 Also do a quick check to see if there is a Documentation tag in this @var{BUFFER}.
2581 @end deffn
2582
2583 @deffn Method ede-map-target-buffers :AFTER this proc
2584 For @var{THIS}, execute @var{PROC} on all buffers belonging to @var{THIS}.
2585 @end deffn
2586
2587 @deffn Method eieio-speedbar-child-description :AFTER obj
2588 Provide a speedbar description for a plain-child of @var{OBJ}.
2589 A plain child is a child element which is not an EIEIO object.
2590 @end deffn
2591
2592 @deffn Method ede-object-keybindings :BEFORE this
2593 Retrieves the slot @code{keybindings} from an object of class @code{ede-target}
2594 @end deffn
2595
2596 @deffn Method ede-description :AFTER this
2597 Return a description suitable for the minibuffer about @var{THIS}.
2598 @end deffn
2599
2600 @deffn Method eieio-speedbar-object-children :AFTER this
2601 Return the list of speedbar display children for @var{THIS}.
2602 @end deffn
2603
2604 @deffn Method ede-system-include-path :AFTER this
2605 Get the system include path used by project @var{THIS}.
2606 @end deffn
2607
2608 @deffn Method ede-object-sourcecode :BEFORE this
2609 Retrieves the slot @code{sourcetype} from an object of class @code{ede-target}
2610 @end deffn
2611
2612 @deffn Method ede-expand-filename :AFTER this filename &optional force
2613 Return a fully qualified file name based on target @var{THIS}.
2614 @var{FILENAME} should be a filename which occurs in a directory in which @var{THIS} works.
2615 Optional argument @var{FORCE} forces the default filename to be provided even if it
2616 doesn't exist.
2617 @end deffn
2618
2619 @deffn Method ede-menu-items-build :AFTER obj &optional current
2620 Return a list of menu items for building target @var{OBJ}.
2621 If optional argument @var{CURRENT} is non-@code{nil}, return sub-menu code.
2622 @end deffn
2623
2624 @deffn Method ede-want-file-p :AFTER this file
2625 Return non-@code{nil} if @var{THIS} target wants @var{FILE}.
2626 @end deffn
2627
2628 @deffn Method ede-update-version-in-source :AFTER this version
2629 In sources for @var{THIS}, change version numbers to @var{VERSION}.
2630 @end deffn
2631
2632 @deffn Method project-delete-target :AFTER ot
2633 Delete the current target @var{OT} from it's parent project.
2634 @end deffn
2635
2636 @deffn Method ede-target-sourcecode :AFTER this
2637 Return the sourcecode objects which @var{THIS} permits.
2638 @end deffn
2639
2640 @deffn Method eieio-speedbar-child-make-tag-lines :AFTER this depth
2641 Create a speedbar tag line for a child of @var{THIS}.
2642 It has depth @var{DEPTH}.
2643 @end deffn
2644
2645 @deffn Method eieio-speedbar-object-buttonname :AFTER object
2646 Return a string to use as a speedbar button for @var{OBJECT}.
2647 @end deffn
2648
2649 @deffn Method eieio-done-customizing :AFTER target
2650 Call this when a user finishes customizing @var{TARGET}.
2651 @end deffn
2652
2653 @deffn Method project-edit-file-target :AFTER ot
2654 Edit the target @var{OT} associated w/ this file.
2655 @end deffn
2656
2657 @deffn Method ede-documentation :AFTER this
2658 Return a list of files that provides documentation.
2659 Documentation is not for object @var{THIS}, but is provided by @var{THIS} for other
2660 files in the project.
2661 @end deffn
2662
2663 @deffn Method ede-want-file-source-p :AFTER this file
2664 Return non-@code{nil} if @var{THIS} target wants @var{FILE}.
2665 @end deffn
2666
2667 @deffn Method ede-want-file-auxiliary-p :AFTER this file
2668 Return non-@code{nil} if @var{THIS} target wants @var{FILE}.
2669 @end deffn
2670
2671 @deffn Method project-add-file :AFTER ot file
2672 Add the current buffer into project project target @var{OT}.
2673 Argument @var{FILE} is the file to add.
2674 @end deffn
2675
2676 @deffn Method ede-target-name :AFTER this
2677 Return the name of @var{THIS} target, suitable for make or debug style commands.
2678 @end deffn
2679
2680 @deffn Method ede-object-menu :BEFORE this
2681 Retrieves the slot @code{menu} from an object of class @code{ede-target}
2682 @end deffn
2683
2684 @node ede-proj-target, ede-proj-target-makefile, ede-target, Targets
2685 @subsection ede-proj-target
2686 @tgindex ede-proj-target
2687
2688 @table @asis
2689 @item Inheritance Tree:
2690 @table @code
2691 @item eieio-speedbar
2692 @table @code
2693 @item eieio-speedbar-directory-button
2694 @table @code
2695 @item @w{@xref{ede-target}.}
2696 @table @code
2697 @item ede-proj-target
2698 @table @asis
2699 @item Children:
2700 @w{@xref{ede-proj-target-makefile},} @w{ede-proj-target-aux,} @w{@xref{ede-proj-target-scheme}.}
2701 @end table
2702 @end table
2703 @end table
2704 @end table
2705 @end table
2706 @end table
2707
2708 @table @asis
2709 @item Slots:
2710
2711 @table @code
2712 @item :name
2713 Type: @code{string}
2714
2715 Name of this target.
2716 @refill
2717
2718 @item :path
2719 Type: @code{string}
2720
2721 The path to the sources of this target.
2722 Relative to the path of the project it belongs to.
2723 @refill
2724
2725 @item :auxsource
2726 Type: @code{list} @*
2727 Default Value: @code{nil}
2728
2729 Auxiliary source files included in this target.
2730 Each of these is considered equivalent to a source file, but it is not
2731 distributed, and each should have a corresponding rule to build it.
2732 @refill
2733
2734 @item :compiler
2735 Type: @code{(or null symbol)} @*
2736 Default Value: @code{nil}
2737
2738 The compiler to be used to compile this object.
2739 This should be a symbol, which contains the object defining the compiler.
2740 This enables save/restore to do so by name, permitting the sharing
2741 of these compiler resources, and global customization thereof.
2742 @refill
2743
2744 @item :linker
2745 Type: @code{(or null symbol)} @*
2746 Default Value: @code{nil}
2747
2748 The linker to be used to link compiled sources for this object.
2749 This should be a symbol, which contains the object defining the linker.
2750 This enables save/restore to do so by name, permitting the sharing
2751 of these linker resources, and global customization thereof.
2752 @refill
2753
2754 @end table
2755
2756 @end table
2757 @subsubsection Specialized Methods
2758
2759 @deffn Method project-compile-target :AFTER obj &optional command
2760 Compile the current target @var{OBJ}.
2761 Argument @var{COMMAND} is the command to use for compiling the target.
2762 @end deffn
2763
2764 @deffn Method project-debug-target :AFTER obj
2765 Run the current project target @var{OBJ} in a debugger.
2766 @end deffn
2767
2768 @deffn Method ede-proj-configure-add-missing :AFTER this
2769 Query if any files needed by @var{THIS} provided by automake are missing.
2770 Results in --add-missing being passed to automake.
2771 @end deffn
2772
2773 @deffn Method ede-proj-flush-autoconf :AFTER this
2774 Flush the configure file (current buffer) to accommodate @var{THIS}.
2775 By flushing, remove any cruft that may be in the file. Subsequent
2776 calls to @dfn{ede-proj-tweak-autoconf} can restore items removed by flush.
2777 @end deffn
2778
2779 @deffn Method ede-proj-makefile-insert-rules :AFTER this
2780 Insert rules needed by @var{THIS} target.
2781 @end deffn
2782
2783 @deffn Method project-remove-file :AFTER target file
2784 For @var{TARGET}, remove @var{FILE}.
2785 @var{FILE} must be massaged by @dfn{ede-convert-path}.
2786 @end deffn
2787
2788 @deffn Method ede-proj-configure-create-missing :AFTER this
2789 Add any missing files for @var{THIS} by creating them.
2790 @end deffn
2791
2792 @deffn Method ede-proj-makefile-sourcevar :AFTER this
2793 Return the variable name for @var{THIS}'s sources.
2794 @end deffn
2795
2796 @deffn Method ede-proj-makefile-insert-variables :AFTER this &optional moresource
2797 Insert variables needed by target @var{THIS}.
2798 Optional argument @var{MORESOURCE} is a list of additional sources to add to the
2799 sources variable.
2800 @end deffn
2801
2802 @deffn Method ede-proj-makefile-insert-automake-post-variables :AFTER this
2803 Insert variables needed by target @var{THIS} in Makefile.am after SOURCES.
2804 @end deffn
2805
2806 @deffn Method ede-proj-makefile-insert-dist-dependencies :AFTER this
2807 Insert any symbols that the DIST rule should depend on.
2808 Argument @var{THIS} is the target that should insert stuff.
2809 @end deffn
2810
2811 @deffn Method ede-proj-linkers :AFTER obj
2812 List of linkers being used by @var{OBJ}.
2813 If the @code{linker} slot is empty, concoct one on a first match found
2814 basis for any given type from the @code{availablelinkers} slot.
2815 Otherwise, return the @code{linker} slot.
2816 Converts all symbols into the objects to be used.
2817 @end deffn
2818
2819 @deffn Method ede-proj-makefile-garbage-patterns :AFTER this
2820 Return a list of patterns that are considered garbage to @var{THIS}.
2821 These are removed with make clean.
2822 @end deffn
2823
2824 @deffn Method ede-proj-tweak-autoconf :AFTER this
2825 Tweak the configure file (current buffer) to accommodate @var{THIS}.
2826 @end deffn
2827
2828 @deffn Method ede-proj-compilers :AFTER obj
2829 List of compilers being used by @var{OBJ}.
2830 If the @code{compiler} slot is empty, concoct one on a first match found
2831 basis for any given type from the @code{availablecompilers} slot.
2832 Otherwise, return the @code{compiler} slot.
2833 Converts all symbols into the objects to be used.
2834 @end deffn
2835
2836 @deffn Method project-delete-target :AFTER this
2837 Delete the current target @var{THIS} from it's parent project.
2838 @end deffn
2839
2840 @deffn Method ede-proj-makefile-target-name :AFTER this
2841 Return the name of the main target for @var{THIS} target.
2842 @end deffn
2843
2844 @deffn Method eieio-done-customizing :AFTER target
2845 Call this when a user finishes customizing this object.
2846 Argument @var{TARGET} is the project we are completing customization on.
2847 @end deffn
2848
2849 @deffn Method ede-proj-makefile-insert-user-rules :AFTER this
2850 Insert user specified rules needed by @var{THIS} target.
2851 @end deffn
2852
2853 @deffn Method project-add-file :AFTER this file
2854 Add to target @var{THIS} the current buffer represented as @var{FILE}.
2855 @end deffn
2856
2857 @deffn Method ede-proj-makefile-insert-automake-pre-variables :AFTER this
2858 Insert variables needed by target @var{THIS} in Makefile.am before SOURCES.
2859 @end deffn
2860
2861 @deffn Method ede-proj-makefile-insert-dist-filepatterns :AFTER this
2862 Insert any symbols that the DIST rule should depend on.
2863 Argument @var{THIS} is the target that should insert stuff.
2864 @end deffn
2865
2866 @deffn Method ede-proj-makefile-dependency-files :AFTER this
2867 Return a list of source files to convert to dependencies.
2868 Argument @var{THIS} is the target to get sources from.
2869 @end deffn
2870
2871 @deffn Method ede-proj-makefile-insert-source-variables :AFTER this &optional moresource
2872 Insert the source variables needed by @var{THIS}.
2873 Optional argument @var{MORESOURCE} is a list of additional sources to add to the
2874 sources variable.
2875 @end deffn
2876
2877
2878 @node ede-proj-target-makefile, semantic-ede-proj-target-grammar, ede-proj-target, Targets
2879 @subsection ede-proj-target-makefile
2880 @tgindex ede-proj-target-makefile
2881
2882 @table @asis
2883 @item Inheritance Tree:
2884 @table @code
2885 @item eieio-speedbar
2886 @table @code
2887 @item eieio-speedbar-directory-button
2888 @table @code
2889 @item @w{@xref{ede-target}.}
2890 @table @code
2891 @item @w{@xref{ede-proj-target}.}
2892 @table @code
2893 @item ede-proj-target-makefile
2894 @table @asis
2895 @item Children:
2896 @w{@xref{semantic-ede-proj-target-grammar},} @w{@xref{ede-proj-target-makefile-objectcode},} @w{@xref{ede-proj-target-elisp},} @w{@xref{ede-proj-target-makefile-miscelaneous},} @w{@xref{ede-proj-target-makefile-info}.}
2897 @end table
2898 @end table
2899 @end table
2900 @end table
2901 @end table
2902 @end table
2903 @end table
2904
2905 @table @asis
2906 @item Slots:
2907
2908 @table @code
2909 @item :makefile
2910 Type: @code{string} @*
2911 Default Value: @code{"Makefile"}
2912
2913 File name of generated Makefile.
2914 @refill
2915
2916 @item :partofall
2917 Type: @code{boolean} @*
2918 Default Value: @code{t}
2919
2920 Non @code{nil} means the rule created is part of the all target.
2921 Setting this to @code{nil} creates the rule to build this item, but does not
2922 include it in the ALL`all:' rule.
2923 @refill
2924
2925 @item :configuration-variables
2926 Type: @code{list} @*
2927 Default Value: @code{nil}
2928
2929 Makefile variables appended to use in different configurations.
2930 These variables are used in the makefile when a configuration becomes active.
2931 Target variables are always renamed such as foo_CFLAGS, then included into
2932 commands where the variable would usually appear.
2933 @refill
2934
2935 @item :rules
2936 Type: @code{list} @*
2937 Default Value: @code{nil}
2938
2939 Arbitrary rules and dependencies needed to make this target.
2940 It is safe to leave this blank.
2941 @refill
2942
2943 @end table
2944
2945 @end table
2946 @subsubsection Specialized Methods
2947
2948 @deffn Method ede-proj-makefile-dependencies :AFTER this
2949 Return a string representing the dependencies for @var{THIS}.
2950 Some compilers only use the first element in the dependencies, others
2951 have a list of intermediates (object files), and others don't care.
2952 This allows customization of how these elements appear.
2953 @end deffn
2954
2955 @deffn Method project-compile-target :AFTER obj &optional command
2956 Compile the current target program @var{OBJ}.
2957 Optional argument @var{COMMAND} is the s the alternate command to use.
2958 @end deffn
2959
2960 @deffn Method ede-proj-makefile-insert-rules :AFTER this
2961 Insert rules needed by @var{THIS} target.
2962 @end deffn
2963
2964 @deffn Method ede-proj-makefile-insert-variables :AFTER this &optional moresource
2965 Insert variables needed by target @var{THIS}.
2966 Optional argument @var{MORESOURCE} is a list of additional sources to add to the
2967 sources variable.
2968 @end deffn
2969
2970 @deffn Method ede-proj-makefile-insert-commands :AFTER this
2971 Insert the commands needed by target @var{THIS}.
2972 For targets, insert the commands needed by the chosen compiler.
2973 @end deffn
2974
2975 @deffn Method ede-proj-makefile-configuration-variables :AFTER this configuration
2976 Return a list of configuration variables from @var{THIS}.
2977 Use @var{CONFIGURATION} as the current configuration to query.
2978 @end deffn
2979
2980 @node semantic-ede-proj-target-grammar, ede-proj-target-makefile-objectcode, ede-proj-target-makefile, Targets
2981 @subsection semantic-ede-proj-target-grammar
2982 @tgindex semantic-ede-proj-target-grammar
2983
2984 @table @asis
2985 @item Inheritance Tree:
2986 @table @code
2987 @item eieio-speedbar
2988 @table @code
2989 @item eieio-speedbar-directory-button
2990 @table @code
2991 @item @w{@xref{ede-target}.}
2992 @table @code
2993 @item @w{@xref{ede-proj-target}.}
2994 @table @code
2995 @item @w{@xref{ede-proj-target-makefile}.}
2996 @table @code
2997 @item semantic-ede-proj-target-grammar
2998 No children
2999 @end table
3000 @end table
3001 @end table
3002 @end table
3003 @end table
3004 @end table
3005 @end table
3006
3007 @subsubsection Specialized Methods
3008
3009 @deffn Method project-compile-target :AFTER obj
3010 Compile all sources in a Lisp target @var{OBJ}.
3011 @end deffn
3012
3013 @deffn Method ede-proj-makefile-insert-rules :AFTER this
3014 Insert rules needed by @var{THIS} target.
3015 @end deffn
3016
3017 @deffn Method ede-buffer-mine :AFTER this buffer
3018 Return @code{t} if object @var{THIS} lays claim to the file in @var{BUFFER}.
3019 Lays claim to all -by.el, and -wy.el files.
3020 @end deffn
3021
3022 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3023 Return the variable name for @var{THIS}'s sources.
3024 @end deffn
3025
3026 @deffn Method ede-proj-makefile-insert-dist-dependencies :AFTER this
3027 Insert dist dependencies, or intermediate targets.
3028 This makes sure that all grammar lisp files are created before the dist
3029 runs, so they are always up to date.
3030 Argument @var{THIS} is the target that should insert stuff.
3031 @end deffn
3032
3033
3034 @node ede-proj-target-makefile-objectcode, ede-proj-target-makefile-archive, semantic-ede-proj-target-grammar, Targets
3035 @subsection ede-proj-target-makefile-objectcode
3036 @tgindex ede-proj-target-makefile-objectcode
3037
3038 @table @asis
3039 @item Inheritance Tree:
3040 @table @code
3041 @item eieio-speedbar
3042 @table @code
3043 @item eieio-speedbar-directory-button
3044 @table @code
3045 @item @w{@xref{ede-target}.}
3046 @table @code
3047 @item @w{@xref{ede-proj-target}.}
3048 @table @code
3049 @item @w{@xref{ede-proj-target-makefile}.}
3050 @table @code
3051 @item ede-proj-target-makefile-objectcode
3052 @table @asis
3053 @item Children:
3054 @w{@xref{ede-proj-target-makefile-archive},} @w{@xref{ede-proj-target-makefile-program}.}
3055 @end table
3056 @end table
3057 @end table
3058 @end table
3059 @end table
3060 @end table
3061 @end table
3062 @end table
3063
3064 @table @asis
3065 @item Slots:
3066
3067 @table @code
3068 @item :configuration-variables
3069 Type: @code{list} @*
3070 Default Value: @code{("debug" ("CFLAGS" . "-g") ("LDFLAGS" . "-g"))}
3071
3072 @xref{ede-proj-target-makefile}.
3073 @end table
3074 @end table
3075 @subsubsection Specialized Methods
3076
3077 @deffn Method ede-buffer-header-file :AFTER this buffer
3078 There are no default header files.
3079 @end deffn
3080
3081 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3082 Return the variable name for @var{THIS}'s sources.
3083 @end deffn
3084
3085 @deffn Method ede-proj-makefile-insert-variables :AFTER this &optional moresource
3086 Insert variables needed by target @var{THIS}.
3087 Optional argument @var{MORESOURCE} is not used.
3088 @end deffn
3089
3090 @deffn Method ede-proj-makefile-dependency-files :AFTER this
3091 Return a list of source files to convert to dependencies.
3092 Argument @var{THIS} is the target to get sources from.
3093 @end deffn
3094
3095
3096 @node ede-proj-target-makefile-archive, ede-proj-target-makefile-program, ede-proj-target-makefile-objectcode, Targets
3097 @subsection ede-proj-target-makefile-archive
3098 @tgindex ede-proj-target-makefile-archive
3099
3100 @table @asis
3101 @item Inheritance Tree:
3102 @table @code
3103 @item eieio-speedbar
3104 @table @code
3105 @item eieio-speedbar-directory-button
3106 @table @code
3107 @item @w{@xref{ede-target}.}
3108 @table @code
3109 @item @w{@xref{ede-proj-target}.}
3110 @table @code
3111 @item @w{@xref{ede-proj-target-makefile}.}
3112 @table @code
3113 @item @w{@xref{ede-proj-target-makefile-objectcode}.}
3114 @table @code
3115 @item ede-proj-target-makefile-archive
3116 No children
3117 @end table
3118 @end table
3119 @end table
3120 @end table
3121 @end table
3122 @end table
3123 @end table
3124 @end table
3125
3126 @subsubsection Specialized Methods
3127
3128 @deffn Method ede-proj-makefile-insert-rules :AFTER this
3129 Create the make rule needed to create an archive for @var{THIS}.
3130 @end deffn
3131
3132 @deffn Method ede-proj-makefile-insert-source-variables :PRIMARY this
3133 Insert bin_PROGRAMS variables needed by target @var{THIS}.
3134 We aren't actually inserting SOURCE details, but this is used by the
3135 Makefile.am generator, so use it to add this important bin program.
3136 @end deffn
3137
3138
3139 @node ede-proj-target-makefile-program, ede-proj-target-makefile-shared-object, ede-proj-target-makefile-archive, Targets
3140 @subsection ede-proj-target-makefile-program
3141 @tgindex ede-proj-target-makefile-program
3142
3143 @table @asis
3144 @item Inheritance Tree:
3145 @table @code
3146 @item eieio-speedbar
3147 @table @code
3148 @item eieio-speedbar-directory-button
3149 @table @code
3150 @item @w{@xref{ede-target}.}
3151 @table @code
3152 @item @w{@xref{ede-proj-target}.}
3153 @table @code
3154 @item @w{@xref{ede-proj-target-makefile}.}
3155 @table @code
3156 @item @w{@xref{ede-proj-target-makefile-objectcode}.}
3157 @table @code
3158 @item ede-proj-target-makefile-program
3159 @table @asis
3160 @item Children:
3161 @w{@xref{ede-proj-target-makefile-shared-object}.}
3162 @end table
3163 @end table
3164 @end table
3165 @end table
3166 @end table
3167 @end table
3168 @end table
3169 @end table
3170 @end table
3171
3172 @table @asis
3173 @item Slots:
3174
3175 @table @code
3176 @item :ldlibs
3177 Type: @code{list} @*
3178 Default Value: @code{nil}
3179
3180 Libraries, such as "m" or "Xt" which this program depends on.
3181 The linker flag "-l" is automatically prepended. Do not include a "lib"
3182 prefix, or a ".so" suffix.
3183
3184 Note: Currently only used for Automake projects.
3185 @refill
3186
3187 @item :ldflags
3188 Type: @code{list} @*
3189 Default Value: @code{nil}
3190
3191 Additional flags to add when linking this target.
3192 Use ldlibs to add addition libraries. Use this to specify specific
3193 options to the linker.
3194
3195 Note: Not currently used. This bug needs to be fixed.
3196 @refill
3197
3198 @end table
3199
3200 @end table
3201 @subsubsection Specialized Methods
3202
3203 @deffn Method project-debug-target :AFTER obj
3204 Debug a program target @var{OBJ}.
3205 @end deffn
3206
3207 @deffn Method ede-proj-makefile-insert-rules :AFTER this
3208 Insert rules needed by @var{THIS} target.
3209 @end deffn
3210
3211 @deffn Method ede-proj-makefile-insert-automake-post-variables :AFTER this
3212 Insert bin_PROGRAMS variables needed by target @var{THIS}.
3213 @end deffn
3214
3215 @deffn Method ede-proj-makefile-insert-automake-pre-variables :AFTER this
3216 Insert bin_PROGRAMS variables needed by target @var{THIS}.
3217 @end deffn
3218
3219
3220 @node ede-proj-target-makefile-shared-object, ede-proj-target-elisp, ede-proj-target-makefile-program, Targets
3221 @subsection ede-proj-target-makefile-shared-object
3222 @tgindex ede-proj-target-makefile-shared-object
3223
3224 @table @asis
3225 @item Inheritance Tree:
3226 @table @code
3227 @item eieio-speedbar
3228 @table @code
3229 @item eieio-speedbar-directory-button
3230 @table @code
3231 @item @w{@xref{ede-target}.}
3232 @table @code
3233 @item @w{@xref{ede-proj-target}.}
3234 @table @code
3235 @item @w{@xref{ede-proj-target-makefile}.}
3236 @table @code
3237 @item @w{@xref{ede-proj-target-makefile-objectcode}.}
3238 @table @code
3239 @item @w{@xref{ede-proj-target-makefile-program}.}
3240 @table @code
3241 @item ede-proj-target-makefile-shared-object
3242 No children
3243 @end table
3244 @end table
3245 @end table
3246 @end table
3247 @end table
3248 @end table
3249 @end table
3250 @end table
3251 @end table
3252
3253 @subsubsection Specialized Methods
3254
3255 @deffn Method ede-proj-configure-add-missing :AFTER this
3256 Query if any files needed by @var{THIS} provided by automake are missing.
3257 Results in --add-missing being passed to automake.
3258 @end deffn
3259
3260 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3261 Return the variable name for @var{THIS}'s sources.
3262 @end deffn
3263
3264 @deffn Method ede-proj-makefile-insert-automake-post-variables :AFTER this
3265 Insert bin_PROGRAMS variables needed by target @var{THIS}.
3266 We need to override -program which has an LDADD element.
3267 @end deffn
3268
3269 @deffn Method ede-proj-makefile-target-name :AFTER this
3270 Return the name of the main target for @var{THIS} target.
3271 @end deffn
3272
3273 @deffn Method ede-proj-makefile-insert-automake-pre-variables :AFTER this
3274 Insert bin_PROGRAMS variables needed by target @var{THIS}.
3275 We aren't actually inserting SOURCE details, but this is used by the
3276 Makefile.am generator, so use it to add this important bin program.
3277 @end deffn
3278
3279
3280 @node ede-proj-target-elisp, ede-proj-target-elisp-autoloads, ede-proj-target-makefile-shared-object, Targets
3281 @subsection ede-proj-target-elisp
3282 @tgindex ede-proj-target-elisp
3283
3284 @table @asis
3285 @item Inheritance Tree:
3286 @table @code
3287 @item eieio-speedbar
3288 @table @code
3289 @item eieio-speedbar-directory-button
3290 @table @code
3291 @item @w{@xref{ede-target}.}
3292 @table @code
3293 @item @w{@xref{ede-proj-target}.}
3294 @table @code
3295 @item @w{@xref{ede-proj-target-makefile}.}
3296 @table @code
3297 @item ede-proj-target-elisp
3298 @table @asis
3299 @item Children:
3300 @w{@xref{ede-proj-target-elisp-autoloads}.}
3301 @end table
3302 @end table
3303 @end table
3304 @end table
3305 @end table
3306 @end table
3307 @end table
3308 @end table
3309
3310 @table @asis
3311 @item Slots:
3312
3313 @table @code
3314 @item :aux-packages
3315 Type: @code{list} @*
3316 Default Value: @code{nil}
3317
3318 Additional packages needed.
3319 There should only be one toplevel package per auxiliary tool needed.
3320 These packages location is found, and added to the compile time
3321 load path.
3322 @refill
3323
3324 @end table
3325
3326 @end table
3327 @subsubsection Specialized Methods
3328
3329 @deffn Method project-compile-target :AFTER obj
3330 Compile all sources in a Lisp target @var{OBJ}.
3331 Bonus: Return a cons cell: (COMPILED . UPTODATE).
3332 @end deffn
3333
3334 @deffn Method ede-proj-flush-autoconf :AFTER this
3335 Flush the configure file (current buffer) to accommodate @var{THIS}.
3336 @end deffn
3337
3338 @deffn Method ede-buffer-mine :AFTER this buffer
3339 Return @code{t} if object @var{THIS} lays claim to the file in @var{BUFFER}.
3340 Lays claim to all .elc files that match .el files in this target.
3341 @end deffn
3342
3343 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3344 Return the variable name for @var{THIS}'s sources.
3345 @end deffn
3346
3347 @deffn Method ede-proj-tweak-autoconf :AFTER this
3348 Tweak the configure file (current buffer) to accommodate @var{THIS}.
3349 @end deffn
3350
3351 @deffn Method ede-update-version-in-source :AFTER this version
3352 In a Lisp file, updated a version string for @var{THIS} to @var{VERSION}.
3353 There are standards in Elisp files specifying how the version string
3354 is found, such as a @code{-version} variable, or the standard header.
3355 @end deffn
3356
3357 @node ede-proj-target-elisp-autoloads, ede-proj-target-makefile-miscelaneous, ede-proj-target-elisp, Targets
3358 @subsection ede-proj-target-elisp-autoloads
3359 @tgindex ede-proj-target-elisp-autoloads
3360
3361 @table @asis
3362 @item Inheritance Tree:
3363 @table @code
3364 @item eieio-speedbar
3365 @table @code
3366 @item eieio-speedbar-directory-button
3367 @table @code
3368 @item @w{@xref{ede-target}.}
3369 @table @code
3370 @item @w{@xref{ede-proj-target}.}
3371 @table @code
3372 @item @w{@xref{ede-proj-target-makefile}.}
3373 @table @code
3374 @item @w{@xref{ede-proj-target-elisp}.}
3375 @table @code
3376 @item ede-proj-target-elisp-autoloads
3377 No children
3378 @end table
3379 @end table
3380 @end table
3381 @end table
3382 @end table
3383 @end table
3384 @end table
3385 @end table
3386
3387 @table @asis
3388 @item Slots:
3389
3390 @table @code
3391 @item :aux-packages
3392 Type: @code{list} @*
3393 Default Value: @code{("cedet-autogen")}
3394
3395 @xref{ede-proj-target-elisp}.
3396 @item :autoload-file
3397 Type: @code{string} @*
3398 Default Value: @code{"loaddefs.el"}
3399
3400 The file that autoload definitions are placed in.
3401 There should be one load defs file for a given package. The load defs are created
3402 for all Emacs Lisp sources that exist in the directory of the created target.
3403 @refill
3404
3405 @item :autoload-dirs
3406 Type: @code{list} @*
3407 Default Value: @code{nil}
3408
3409 The directories to scan for autoload definitions.
3410 If @code{nil} defaults to the current directory.
3411 @refill
3412
3413 @end table
3414
3415 @end table
3416 @subsubsection Specialized Methods
3417
3418 @deffn Method ede-proj-makefile-dependencies :AFTER this
3419 Return a string representing the dependencies for @var{THIS}.
3420 Always return an empty string for an autoloads generator.
3421 @end deffn
3422
3423 @deffn Method project-compile-target :AFTER obj
3424 Create or update the autoload target.
3425 @end deffn
3426
3427 @deffn Method ede-proj-flush-autoconf :AFTER this
3428 Flush the configure file (current buffer) to accommodate @var{THIS}.
3429 @end deffn
3430
3431 @deffn Method ede-buffer-mine :AFTER this buffer
3432 Return @code{t} if object @var{THIS} lays claim to the file in @var{BUFFER}.
3433 Lays claim to all .elc files that match .el files in this target.
3434 @end deffn
3435
3436 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3437 Return the variable name for @var{THIS}'s sources.
3438 @end deffn
3439
3440 @deffn Method ede-proj-makefile-insert-dist-dependencies :AFTER this
3441 Insert any symbols that the DIST rule should depend on.
3442 Emacs Lisp autoload files ship the generated .el files.
3443 Argument @var{THIS} is the target which needs to insert an info file.
3444 @end deffn
3445
3446 @deffn Method ede-proj-tweak-autoconf :AFTER this
3447 Tweak the configure file (current buffer) to accommodate @var{THIS}.
3448 @end deffn
3449
3450 @deffn Method ede-update-version-in-source :AFTER this version
3451 In a Lisp file, updated a version string for @var{THIS} to @var{VERSION}.
3452 There are standards in Elisp files specifying how the version string
3453 is found, such as a @code{-version} variable, or the standard header.
3454 @end deffn
3455
3456 @deffn Method ede-proj-compilers :AFTER obj
3457 List of compilers being used by @var{OBJ}.
3458 If the @code{compiler} slot is empty, get the car of the compilers list.
3459 @end deffn
3460
3461 @deffn Method ede-proj-makefile-insert-dist-filepatterns :AFTER this
3462 Insert any symbols that the DIST rule should distribute.
3463 Emacs Lisp autoload files ship the generated .el files.
3464 Argument @var{THIS} is the target which needs to insert an info file.
3465 @end deffn
3466
3467 @deffn Method ede-proj-makefile-insert-source-variables :AFTER this &optional moresource
3468 Insert the source variables needed by @var{THIS}.
3469 Optional argument @var{MORESOURCE} is a list of additional sources to add to the
3470 sources variable.
3471 @end deffn
3472
3473
3474 @node ede-proj-target-makefile-miscelaneous, ede-proj-target-makefile-info, ede-proj-target-elisp-autoloads, Targets
3475 @subsection ede-proj-target-makefile-miscelaneous
3476 @tgindex ede-proj-target-makefile-miscelaneous
3477
3478 @table @asis
3479 @item Inheritance Tree:
3480 @table @code
3481 @item eieio-speedbar
3482 @table @code
3483 @item eieio-speedbar-directory-button
3484 @table @code
3485 @item @w{@xref{ede-target}.}
3486 @table @code
3487 @item @w{@xref{ede-proj-target}.}
3488 @table @code
3489 @item @w{@xref{ede-proj-target-makefile}.}
3490 @table @code
3491 @item ede-proj-target-makefile-miscelaneous
3492 No children
3493 @end table
3494 @end table
3495 @end table
3496 @end table
3497 @end table
3498 @end table
3499 @end table
3500
3501 @table @asis
3502 @item Slots:
3503
3504 @table @code
3505 @item :submakefile
3506 Type: @code{string} @*
3507 Default Value: @code{""}
3508
3509 Miscellaneous sources which have a specialized makefile.
3510 The sub-makefile is used to build this target.
3511 @refill
3512
3513 @end table
3514
3515 @end table
3516 @subsubsection Specialized Methods
3517
3518 @deffn Method ede-proj-makefile-insert-rules :AFTER this
3519 Create the make rule needed to create an archive for @var{THIS}.
3520 @end deffn
3521
3522 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3523 Return the variable name for @var{THIS}'s sources.
3524 @end deffn
3525
3526 @deffn Method ede-proj-makefile-dependency-files :AFTER this
3527 Return a list of files which @var{THIS} target depends on.
3528 @end deffn
3529
3530
3531 @node ede-proj-target-makefile-info, ede-proj-target-scheme, ede-proj-target-makefile-miscelaneous, Targets
3532 @subsection ede-proj-target-makefile-info
3533 @tgindex ede-proj-target-makefile-info
3534
3535 @table @asis
3536 @item Inheritance Tree:
3537 @table @code
3538 @item eieio-speedbar
3539 @table @code
3540 @item eieio-speedbar-directory-button
3541 @table @code
3542 @item @w{@xref{ede-target}.}
3543 @table @code
3544 @item @w{@xref{ede-proj-target}.}
3545 @table @code
3546 @item @w{@xref{ede-proj-target-makefile}.}
3547 @table @code
3548 @item ede-proj-target-makefile-info
3549 No children
3550 @end table
3551 @end table
3552 @end table
3553 @end table
3554 @end table
3555 @end table
3556 @end table
3557
3558 @table @asis
3559 @item Slots:
3560
3561 @table @code
3562 @item :mainmenu
3563 Type: @code{string} @*
3564 Default Value: @code{""}
3565
3566 The main menu resides in this file.
3567 All other sources should be included independently.
3568 @refill
3569
3570 @end table
3571
3572 @end table
3573 @subsubsection Specialized Methods
3574
3575 @deffn Method ede-proj-configure-add-missing :AFTER this
3576 Query if any files needed by @var{THIS} provided by automake are missing.
3577 Results in --add-missing being passed to automake.
3578 @end deffn
3579
3580 @deffn Method object-write :AFTER this
3581 Before committing any change to @var{THIS}, make sure the mainmenu is first.
3582 @end deffn
3583
3584 @deffn Method ede-proj-makefile-sourcevar :AFTER this
3585 Return the variable name for @var{THIS}'s sources.
3586 @end deffn
3587
3588 @deffn Method ede-proj-makefile-insert-dist-dependencies :AFTER this
3589 Insert any symbols that the DIST rule should depend on.
3590 Texinfo files want to insert generated `.info' files.
3591 Argument @var{THIS} is the target which needs to insert an info file.
3592 @end deffn
3593
3594 @deffn Method ede-proj-makefile-target-name :AFTER this
3595 Return the name of the main target for @var{THIS} target.
3596 @end deffn
3597
3598 @deffn Method ede-documentation :AFTER this
3599 Return a list of files that provides documentation.
3600 Documentation is not for object @var{THIS}, but is provided by @var{THIS} for other
3601 files in the project.
3602 @end deffn
3603
3604 @deffn Method ede-proj-makefile-insert-dist-filepatterns :AFTER this
3605 Insert any symbols that the DIST rule should depend on.
3606 Texinfo files want to insert generated `.info' files.
3607 Argument @var{THIS} is the target which needs to insert an info file.
3608 @end deffn
3609
3610 @deffn Method ede-proj-makefile-insert-source-variables :AFTER this &optional moresource
3611 Insert the source variables needed by @var{THIS} info target.
3612 Optional argument @var{MORESOURCE} is a list of additional sources to add to the
3613 sources variable.
3614 Does the usual for Makefile mode, but splits source into two variables
3615 when working in Automake mode.
3616 @end deffn
3617
3618 @node ede-proj-target-scheme, project-am-target, ede-proj-target-makefile-info, Targets
3619 @subsection ede-proj-target-scheme
3620 @tgindex ede-proj-target-scheme
3621
3622 @table @asis
3623 @item Inheritance Tree:
3624 @table @code
3625 @item eieio-speedbar
3626 @table @code
3627 @item eieio-speedbar-directory-button
3628 @table @code
3629 @item @w{@xref{ede-target}.}
3630 @table @code
3631 @item @w{@xref{ede-proj-target}.}
3632 @table @code
3633 @item ede-proj-target-scheme
3634 No children
3635 @end table
3636 @end table
3637 @end table
3638 @end table
3639 @end table
3640 @end table
3641
3642 @table @asis
3643 @item Slots:
3644
3645 @table @code
3646 @item :interpreter
3647 Type: @code{string} @*
3648 Default Value: @code{"guile"}
3649
3650 The preferred interpreter for this code.
3651 @refill
3652
3653 @end table
3654
3655 @end table
3656 @subsubsection Specialized Methods
3657
3658 @deffn Method ede-proj-tweak-autoconf :AFTER this
3659 Tweak the configure file (current buffer) to accommodate @var{THIS}.
3660 @end deffn
3661
3662
3663 @node project-am-target, project-am-objectcode, ede-proj-target-scheme, Targets
3664 @subsection project-am-target
3665 @tgindex project-am-target
3666
3667 @table @asis
3668 @item Inheritance Tree:
3669 @table @code
3670 @item eieio-speedbar
3671 @table @code
3672 @item eieio-speedbar-directory-button
3673 @table @code
3674 @item @w{@xref{ede-target}.}
3675 @table @code
3676 @item project-am-target
3677 @table @asis
3678 @item Children:
3679 @w{@xref{project-am-objectcode},} @w{project-am-header,} @w{@xref{project-am-lisp},} @w{@xref{project-am-texinfo},} @w{@xref{project-am-man}.}
3680 @end table
3681 @end table
3682 @end table
3683 @end table
3684 @end table
3685 @end table
3686
3687 @subsubsection Specialized Methods
3688
3689 @deffn Method project-compile-target-command :AFTER this
3690 Default target to use when compiling a given target.
3691 @end deffn
3692
3693 @deffn Method project-make-dist :AFTER this
3694 Run the current project in the debugger.
3695 @end deffn
3696
3697 @deffn Method project-edit-file-target :AFTER obj
3698 Edit the target associated w/ this file.
3699 @end deffn
3700
3701 @node project-am-objectcode, project-am-program, project-am-target, Targets
3702 @subsection project-am-objectcode
3703 @tgindex project-am-objectcode
3704
3705 @table @asis
3706 @item Inheritance Tree:
3707 @table @code
3708 @item eieio-speedbar
3709 @table @code
3710 @item eieio-speedbar-directory-button
3711 @table @code
3712 @item @w{@xref{ede-target}.}
3713 @table @code
3714 @item @w{@xref{project-am-target}.}
3715 @table @code
3716 @item project-am-objectcode
3717 @table @asis
3718 @item Children:
3719 @w{@xref{project-am-program},} @w{project-am-lib.}
3720 @end table
3721 @end table
3722 @end table
3723 @end table
3724 @end table
3725 @end table
3726 @end table
3727
3728 @subsubsection Specialized Methods
3729
3730 @deffn Method project-am-macro :AFTER this
3731 Return the default macro to 'edit' for this object type.
3732 @end deffn
3733
3734 @deffn Method project-debug-target :AFTER obj
3735 Run the current project target in a debugger.
3736 @end deffn
3737
3738 @deffn Method project-compile-target-command :AFTER this
3739 Default target to use when compiling an object code target.
3740 @end deffn
3741
3742 @deffn Method ede-buffer-header-file :AFTER this buffer
3743 There are no default header files.
3744 @end deffn
3745
3746 @node project-am-program, project-am-header-noinst, project-am-objectcode, Targets
3747 @subsection project-am-program
3748 @tgindex project-am-program
3749
3750 @table @asis
3751 @item Inheritance Tree:
3752 @table @code
3753 @item eieio-speedbar
3754 @table @code
3755 @item eieio-speedbar-directory-button
3756 @table @code
3757 @item @w{@xref{ede-target}.}
3758 @table @code
3759 @item @w{@xref{project-am-target}.}
3760 @table @code
3761 @item @w{@xref{project-am-objectcode}.}
3762 @table @code
3763 @item project-am-program
3764 No children
3765 @end table
3766 @end table
3767 @end table
3768 @end table
3769 @end table
3770 @end table
3771 @end table
3772
3773 @table @asis
3774 @item Slots:
3775
3776 @table @code
3777 @item :ldadd @*
3778 Default Value: @code{nil}
3779
3780 Additional LD args.
3781 @refill
3782 @end table
3783 @end table
3784
3785 @node project-am-header-noinst, project-am-header-inst, project-am-program, Targets
3786 @subsection project-am-header-noinst
3787 @tgindex project-am-header-noinst
3788
3789 @table @asis
3790 @item Inheritance Tree:
3791 @table @code
3792 @item eieio-speedbar
3793 @table @code
3794 @item eieio-speedbar-directory-button
3795 @table @code
3796 @item @w{@xref{ede-target}.}
3797 @table @code
3798 @item @w{@xref{project-am-target}.}
3799 @table @code
3800 @item @w{project-am-header.}
3801 @table @code
3802 @item project-am-header-noinst
3803 No children
3804 @end table
3805 @end table
3806 @end table
3807 @end table
3808 @end table
3809 @end table
3810 @end table
3811
3812 @subsubsection Specialized Methods
3813
3814 @deffn Method project-am-macro :AFTER this
3815 Return the default macro to 'edit' for this object.
3816 @end deffn
3817
3818 @node project-am-header-inst, project-am-lisp, project-am-header-noinst, Targets
3819 @subsection project-am-header-inst
3820 @tgindex project-am-header-inst
3821
3822 @table @asis
3823 @item Inheritance Tree:
3824 @table @code
3825 @item eieio-speedbar
3826 @table @code
3827 @item eieio-speedbar-directory-button
3828 @table @code
3829 @item @w{@xref{ede-target}.}
3830 @table @code
3831 @item @w{@xref{project-am-target}.}
3832 @table @code
3833 @item @w{project-am-header.}
3834 @table @code
3835 @item project-am-header-inst
3836 No children
3837 @end table
3838 @end table
3839 @end table
3840 @end table
3841 @end table
3842 @end table
3843 @end table
3844
3845 @subsubsection Specialized Methods
3846
3847 @deffn Method project-am-macro :AFTER this
3848 Return the default macro to 'edit' for this object.
3849 @end deffn
3850
3851 @node project-am-lisp, project-am-texinfo, project-am-header-inst, Targets
3852 @subsection project-am-lisp
3853 @tgindex project-am-lisp
3854
3855 @table @asis
3856 @item Inheritance Tree:
3857 @table @code
3858 @item eieio-speedbar
3859 @table @code
3860 @item eieio-speedbar-directory-button
3861 @table @code
3862 @item @w{@xref{ede-target}.}
3863 @table @code
3864 @item @w{@xref{project-am-target}.}
3865 @table @code
3866 @item project-am-lisp
3867 No children
3868 @end table
3869 @end table
3870 @end table
3871 @end table
3872 @end table
3873 @end table
3874
3875 @subsubsection Specialized Methods
3876
3877 @deffn Method project-am-macro :AFTER this
3878 Return the default macro to 'edit' for this object.
3879 @end deffn
3880
3881 @node project-am-texinfo, project-am-man, project-am-lisp, Targets
3882 @subsection project-am-texinfo
3883 @tgindex project-am-texinfo
3884
3885 @table @asis
3886 @item Inheritance Tree:
3887 @table @code
3888 @item eieio-speedbar
3889 @table @code
3890 @item eieio-speedbar-directory-button
3891 @table @code
3892 @item @w{@xref{ede-target}.}
3893 @table @code
3894 @item @w{@xref{project-am-target}.}
3895 @table @code
3896 @item project-am-texinfo
3897 No children
3898 @end table
3899 @end table
3900 @end table
3901 @end table
3902 @end table
3903 @end table
3904
3905 @table @asis
3906 @item Slots:
3907
3908 @table @code
3909 @item :include @*
3910 Default Value: @code{nil}
3911
3912 Additional texinfo included in this one.
3913 @refill
3914
3915 @end table
3916 @end table
3917 @subsubsection Specialized Methods
3918
3919 @deffn Method project-am-macro :AFTER this
3920 Return the default macro to 'edit' for this object type.
3921 @end deffn
3922
3923 @deffn Method project-compile-target-command :AFTER this
3924 Default target to use when compiling a texinfo file.
3925 @end deffn
3926
3927 @deffn Method ede-documentation :AFTER this
3928 Return a list of files that provides documentation.
3929 Documentation is not for object @var{THIS}, but is provided by @var{THIS} for other
3930 files in the project.
3931 @end deffn
3932
3933 @node project-am-man, , project-am-texinfo, Targets
3934 @comment node-name, next, previous, up
3935 @subsection project-am-man
3936 @tgindex project-am-man
3937
3938 @table @asis
3939 @item Inheritance Tree:
3940 @table @code
3941 @item eieio-speedbar
3942 @table @code
3943 @item eieio-speedbar-directory-button
3944 @table @code
3945 @item @w{@xref{ede-target}.}
3946 @table @code
3947 @item @w{@xref{project-am-target}.}
3948 @table @code
3949 @item project-am-man
3950 No children
3951 @end table
3952 @end table
3953 @end table
3954 @end table
3955 @end table
3956 @end table
3957
3958 @subsubsection Specialized Methods
3959
3960 @deffn Method project-am-macro :AFTER this
3961 Return the default macro to 'edit' for this object type.
3962 @end deffn
3963
3964 @node Sourcecode, Compilers, Targets, Extending EDE
3965 @section Sourcecode
3966
3967 The source code type is an object designed to associated files with
3968 targets.
3969
3970 @menu
3971 * ede-sourcecode::
3972 @end menu
3973
3974
3975 @node ede-sourcecode, , Sourcecode, Sourcecode
3976 @subsection ede-sourcecode
3977 @scindex ede-sourcecode
3978
3979 @table @asis
3980 @item Inheritance Tree:
3981 @table @code
3982 @item eieio-instance-inheritor
3983 @table @code
3984 @item ede-sourcecode
3985 No children
3986 @end table
3987 @end table
3988 @end table
3989
3990 @table @asis
3991 @item Slots:
3992
3993 @table @code
3994 @item :parent-instance
3995 Type: @code{eieio-instance-inheritor-child}
3996
3997 The parent of this instance.
3998 If a slot of this class is reference, and is unbound, then the parent
3999 is checked for a value.
4000 @refill
4001
4002 @item :name
4003 Type: @code{string}
4004
4005 The name of this type of source code.
4006 Such as "C" or "Emacs Lisp"
4007 @refill
4008
4009 @item :sourcepattern
4010 Type: @code{string} @*
4011 Default Value: @code{".*"}
4012
4013 Emacs regex matching sourcecode this target accepts.
4014 @refill
4015
4016 @item :auxsourcepattern
4017 Type: @code{(or null string)} @*
4018 Default Value: @code{nil}
4019
4020 Emacs regex matching auxiliary source code this target accepts.
4021 Aux source are source code files needed for compilation, which are not compiled
4022 themselves.
4023 @refill
4024
4025 @item :enable-subdirectories
4026 Type: @code{boolean} @*
4027 Default Value: @code{nil}
4028
4029 Non @code{nil} if this sourcecode type uses subdirectores.
4030 If sourcecode always lives near the target creating it, this should be nil.
4031 If sourcecode can, or typically lives in a subdirectory of the owning
4032 target, set this to t.
4033 @refill
4034
4035 @item :garbagepattern
4036 Type: @code{list} @*
4037 Default Value: @code{nil}
4038
4039 Shell file regex matching files considered as garbage.
4040 This is a list of items added to an @code{rm} command when executing a @code{clean}
4041 type directive.
4042 @refill
4043
4044 @end table
4045
4046 @end table
4047 @subsubsection Specialized Methods
4048
4049 @deffn Method ede-want-any-files-p :AFTER this filenames
4050 Return non-@code{nil} if @var{THIS} will accept any files in @var{FILENAMES}.
4051 @end deffn
4052
4053 @deffn Method ede-want-any-source-files-p :AFTER this filenames
4054 Return non-@code{nil} if @var{THIS} will accept any source files in @var{FILENAMES}.
4055 @end deffn
4056
4057 @deffn Method ede-want-any-auxiliary-files-p :AFTER this filenames
4058 Return non-@code{nil} if @var{THIS} will accept any aux files in @var{FILENAMES}.
4059 @end deffn
4060
4061 @deffn Method ede-buffer-header-file :AFTER this filename
4062 Return a list of file names of header files for @var{THIS} with @var{FILENAME}.
4063 Used to guess header files, but uses the auxsource regular expression.
4064 @end deffn
4065
4066 @deffn Method ede-want-file-p :AFTER this filename
4067 Return non-@code{nil} if sourcecode definition @var{THIS} will take @var{FILENAME}.
4068 @end deffn
4069
4070 @deffn Method ede-want-file-source-p :AFTER this filename
4071 Return non-@code{nil} if @var{THIS} will take @var{FILENAME} as an auxiliary .
4072 @end deffn
4073
4074 @deffn Method ede-want-file-auxiliary-p :AFTER this filename
4075 Return non-@code{nil} if @var{THIS} will take @var{FILENAME} as an auxiliary .
4076 @end deffn
4077
4078 @node Compilers, , Sourcecode, Extending EDE
4079 @section Compilers
4080
4081 The compiler object is designed to associate source code with
4082 compilers. The target then references the compilers it can use.
4083 When the makefile is created, this object type knows how to create
4084 compile commands.
4085
4086 @menu
4087 * ede-compilation-program::
4088 * ede-compiler::
4089 * ede-object-compiler::
4090 * ede-linker::
4091 @end menu
4092
4093
4094 @node ede-compilation-program, ede-compiler, Compilers, Compilers
4095 @subsection ede-compilation-program
4096 @cmindex ede-compilation-program
4097
4098 @table @asis
4099 @item Inheritance Tree:
4100 @table @code
4101 @item eieio-instance-inheritor
4102 @table @code
4103 @item ede-compilation-program
4104 @table @asis
4105 @item Children:
4106 @w{@xref{ede-compiler},} @w{@xref{ede-linker}.}
4107 @end table
4108 @end table
4109 @end table
4110 @end table
4111
4112 @table @asis
4113 @item Slots:
4114
4115 @table @code
4116 @item :parent-instance
4117 Type: @code{eieio-instance-inheritor-child}
4118
4119 The parent of this instance.
4120 If a slot of this class is reference, and is unbound, then the parent
4121 is checked for a value.
4122 @refill
4123
4124 @item :name
4125 Type: @code{string}
4126
4127 Name of this type of compiler.
4128 @refill
4129
4130 @item :variables
4131 Type: @code{list}
4132
4133 Variables needed in the Makefile for this compiler.
4134 An assoc list where each element is (VARNAME . VALUE) where VARNAME
4135 is a string, and VALUE is either a string, or a list of strings.
4136 For example, GCC would define CC=gcc, and emacs would define EMACS=emacs.
4137 @refill
4138
4139 @item :sourcetype
4140 Type: @code{list}
4141
4142 A list of @code{ede-sourcecode} @xref{ede-sourcecode}. objects this class will handle.
4143 This is used to match target objects with the compilers and linkers
4144 they can use, and which files this object is interested in.
4145 @refill
4146
4147 @item :rules
4148 Type: @code{list} @*
4149 Default Value: @code{nil}
4150
4151 Auxiliary rules needed for this compiler to run.
4152 For example, yacc/lex files need additional chain rules, or inferences.
4153 @refill
4154
4155 @item :commands
4156 Type: @code{list}
4157
4158 The commands used to execute this compiler.
4159 The object which uses this compiler will place these commands after
4160 it's rule definition.
4161 @refill
4162
4163 @item :autoconf
4164 Type: @code{list} @*
4165 Default Value: @code{nil}
4166
4167 Autoconf function to call if this type of compiler is used.
4168 When a project is in Automake mode, this defines the autoconf function to
4169 call to initialize automake to use this compiler.
4170 For example, there may be multiple C compilers, but they all probably
4171 use the same autoconf form.
4172 @refill
4173
4174 @item :objectextention
4175 Type: @code{string}
4176
4177 A string which is the extension used for object files.
4178 For example, C code uses .o on unix, and Emacs Lisp uses .elc.
4179 @refill
4180
4181 @end table
4182
4183 @end table
4184 @subsubsection Specialized Methods
4185
4186 @deffn Method ede-proj-flush-autoconf :AFTER this
4187 Flush the configure file (current buffer) to accommodate @var{THIS}.
4188 @end deffn
4189
4190 @deffn Method ede-proj-makefile-insert-rules :AFTER this
4191 Insert rules needed for @var{THIS} compiler object.
4192 @end deffn
4193
4194 @deffn Method ede-proj-makefile-insert-variables :AFTER this
4195 Insert variables needed by the compiler @var{THIS}.
4196 @end deffn
4197
4198 @deffn Method ede-proj-makefile-insert-commands :AFTER this
4199 Insert the commands needed to use compiler @var{THIS}.
4200 The object creating makefile rules must call this method for the
4201 compiler it decides to use after inserting in the rule.
4202 @end deffn
4203
4204 @deffn Method ede-object-sourcecode :AFTER this
4205 Retrieves the slot @code{sourcetype} from an object of class @code{ede-compilation-program}
4206 @end deffn
4207
4208 @deffn Method ede-proj-tweak-autoconf :AFTER this
4209 Tweak the configure file (current buffer) to accommodate @var{THIS}.
4210 @end deffn
4211
4212
4213 @node ede-compiler, ede-object-compiler, ede-compilation-program, Compilers
4214 @subsection ede-compiler
4215 @cmindex ede-compiler
4216
4217 @table @asis
4218 @item Inheritance Tree:
4219 @table @code
4220 @item eieio-instance-inheritor
4221 @table @code
4222 @item @w{@xref{ede-compilation-program}.}
4223 @table @code
4224 @item ede-compiler
4225 @table @asis
4226 @item Children:
4227 @w{@xref{ede-object-compiler},} @w{semantic-ede-grammar-compiler-class.}
4228 @end table
4229
4230 @end table
4231
4232 @end table
4233
4234 @end table
4235 @end table
4236
4237 Create a new object with name NAME of class type ede-compiler
4238
4239 @table @asis
4240 @item Slots:
4241
4242 @table @code
4243 @item :parent-instance
4244 Type: @code{eieio-instance-inheritor-child}
4245
4246 The parent of this instance.
4247 If a slot of this class is reference, and is unbound, then the parent
4248 is checked for a value.
4249 @refill
4250
4251 @item :name
4252 Type: @code{string}
4253
4254 Name of this type of compiler.
4255 @refill
4256
4257 @item :variables
4258 Type: @code{list}
4259
4260 Variables needed in the Makefile for this compiler.
4261 An assoc list where each element is (VARNAME . VALUE) where VARNAME
4262 is a string, and VALUE is either a string, or a list of strings.
4263 For example, GCC would define CC=gcc, and emacs would define EMACS=emacs.
4264 @refill
4265
4266 @item :sourcetype
4267 Type: @code{list}
4268
4269 A list of @code{ede-sourcecode} @xref{ede-sourcecode}. objects this class will handle.
4270 This is used to match target objects with the compilers and linkers
4271 they can use, and which files this object is interested in.
4272 @refill
4273
4274 @item :commands
4275 Type: @code{list}
4276
4277 The commands used to execute this compiler.
4278 The object which uses this compiler will place these commands after
4279 it's rule definition.
4280 @refill
4281
4282 @item :objectextention
4283 Type: @code{string}
4284
4285 A string which is the extension used for object files.
4286 For example, C code uses .o on unix, and Emacs Lisp uses .elc.
4287 @refill
4288
4289 @item :makedepends
4290 Type: @code{boolean} @*
4291 Default Value: @code{nil}
4292
4293 Non-@code{nil} if this compiler can make dependencies.
4294 @refill
4295
4296 @item :uselinker
4297 Type: @code{boolean} @*
4298 Default Value: @code{nil}
4299
4300 Non-@code{nil} if this compiler creates code that can be linked.
4301 This requires that the containing target also define a list of available
4302 linkers that can be used.
4303 @refill
4304
4305 @end table
4306
4307 @end table
4308 @subsubsection Specialized Methods
4309
4310 @deffn Method ede-proj-makefile-insert-object-variables :AFTER this targetname sourcefiles
4311 Insert an OBJ variable to specify object code to be generated for @var{THIS}.
4312 The name of the target is @var{TARGETNAME} as a string. @var{SOURCEFILES} is the list of
4313 files to be objectified.
4314 Not all compilers do this.
4315 @end deffn
4316
4317 @deffn Method ede-compiler-intermediate-objects-p :AFTER this
4318 Return non-@code{nil} if @var{THIS} has intermediate object files.
4319 If this compiler creates code that can be linked together,
4320 then the object files created by the compiler are considered intermediate.
4321 @end deffn
4322
4323 @deffn Method ede-compiler-intermediate-object-variable :AFTER this targetname
4324 Return a string based on @var{THIS} representing a make object variable.
4325 @var{TARGETNAME} is the name of the target that these objects belong to.
4326 @end deffn
4327
4328
4329 @node ede-object-compiler, ede-linker, ede-compiler, Compilers
4330 @subsection ede-object-compiler
4331 @cmindex ede-object-compiler
4332
4333 @table @asis
4334 @item Inheritance Tree:
4335 @table @code
4336 @item eieio-instance-inheritor
4337 @table @code
4338 @item @w{@xref{ede-compilation-program}.}
4339 @table @code
4340 @item @w{@xref{ede-compiler}.}
4341 @table @code
4342 @item ede-object-compiler
4343 No children
4344 @end table
4345 @end table
4346 @end table
4347 @end table
4348 @end table
4349
4350 @table @asis
4351 @item Slots:
4352
4353 @table @code
4354 @item :uselinker
4355 Type: @code{boolean} @*
4356 Default Value: @code{t}
4357
4358 @xref{ede-compiler}.
4359 @item :dependencyvar
4360 Type: @code{list}
4361
4362 A variable dedicated to dependency generation.
4363 @refill
4364 @end table
4365 @end table
4366
4367 @subsubsection Specialized Methods
4368
4369 @deffn Method ede-proj-makefile-insert-variables :AFTER this
4370 Insert variables needed by the compiler @var{THIS}.
4371 @end deffn
4372
4373 @node ede-linker, , ede-object-compiler, Compilers
4374 @subsection ede-linker
4375 @cmindex ede-linker
4376
4377 @table @asis
4378 @item Inheritance Tree:
4379 @table @code
4380 @item eieio-instance-inheritor
4381 @table @code
4382 @item @w{@xref{ede-compilation-program}.}
4383 @table @code
4384 @item ede-linker
4385 No children
4386 @end table
4387
4388 @end table
4389
4390 @end table
4391 @end table
4392
4393 Create a new object with name NAME of class type ede-linker
4394
4395 @table @asis
4396 @item Slots:
4397
4398 @table @code
4399 @item :name
4400 Type: @code{string}
4401
4402 Name of this type of compiler.
4403 @refill
4404
4405 @item :variables
4406 Type: @code{list}
4407
4408 Variables needed in the Makefile for this compiler.
4409 An assoc list where each element is (VARNAME . VALUE) where VARNAME
4410 is a string, and VALUE is either a string, or a list of strings.
4411 For example, GCC would define CC=gcc, and emacs would define EMACS=emacs.
4412 @refill
4413
4414 @item :sourcetype
4415 Type: @code{list}
4416
4417 A list of @code{ede-sourcecode} @xref{ede-sourcecode}. objects this class will handle.
4418 This is used to match target objects with the compilers and linkers
4419 they can use, and which files this object is interested in.
4420 @refill
4421
4422 @item :commands
4423 Type: @code{list}
4424
4425 The commands used to execute this compiler.
4426 The object which uses this compiler will place these commands after
4427 it's rule definition.
4428 @refill
4429
4430 @item :objectextention
4431 Type: @code{string}
4432
4433 A string which is the extension used for object files.
4434 For example, C code uses .o on unix, and Emacs Lisp uses .elc.
4435 @refill
4436
4437 @end table
4438 @end table
4439
4440 @node GNU Free Documentation License, , Extending EDE, Top
4441 @appendix GNU Free Documentation License
4442 @include doclicense.texi
4443
4444 @bye