1 ;;; ede-proj-nusc.el --- EDE Generic Project Emacs Lisp support
3 ;;; Copyright (C) 1998, 1999, 2000, 2001 Eric M. Ludlam
5 ;; Author: Eric M. Ludlam <zappo@gnu.org>
6 ;; Keywords: project, make
7 ;; RCS: $Id: ede-proj-misc.el,v 1.1 2007-11-26 15:22:09 michaels Exp $
9 ;; This software is free software; you can redistribute it and/or modify
10 ;; it under the terms of the GNU General Public License as published by
11 ;; the Free Software Foundation; either version 2, or (at your option)
14 ;; This software is distributed in the hope that it will be useful,
15 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 ;; GNU General Public License for more details.
19 ;; You should have received a copy of the GNU General Public License
20 ;; along with GNU Emacs; see the file COPYING. If not, write to the
21 ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
22 ;; Boston, MA 02110-1301, USA.
26 ;; Handle miscelaneous compilable projects in and EDE Project file.
27 ;; This misc target lets the user link in custom makefiles to an EDE
31 (require 'ede-proj-comp)
34 (defclass ede-proj-target-makefile-miscelaneous (ede-proj-target-makefile)
35 ((sourcetype :initform (ede-misc-source))
36 (availablecompilers :initform (ede-misc-compile))
37 (submakefile :initarg :submakefile
42 "Miscelaneous sources which have a specialized makefile.
43 The sub-makefile is used to build this target.")
45 "Miscelaneous target type.
46 A user-written makefile is used to build this target.
47 All listed sources are included in the distribution.")
49 (defvar ede-misc-source
50 (ede-sourcecode "ede-misc-source"
53 "Miscelaneous fiels definition.")
55 (defvar ede-misc-compile
56 (ede-compiler "ede-misc-compile"
62 :sourcetype '(ede-misc-source)
64 "Compile code via a sub-makefile.")
66 (defmethod ede-proj-makefile-sourcevar ((this ede-proj-target-makefile-miscelaneous))
67 "Return the variable name for THIS's sources."
68 (concat (ede-pmake-varname this) "_MISC"))
70 (defmethod ede-proj-makefile-dependency-files
71 ((this ede-proj-target-makefile-miscelaneous))
72 "Return a list of files which THIS target depends on."
73 (with-slots (submakefile) this
74 (cond ((string= submakefile "")
78 (t (list submakefile)))))
80 (defmethod ede-proj-makefile-insert-rules ((this ede-proj-target-makefile-miscelaneous))
81 "Create the make rule needed to create an archive for THIS."
82 ;; DO NOT call the next method. We will never have any compilers,
83 ;; or any dependencies, or stuff like this. This rull will lets us
84 ;; deal with it in a nice way.
85 (insert (ede-name this) ": ")
86 (with-slots (submakefile) this
87 (if (string= submakefile "")
89 (insert submakefile "\n" "\t$(MAKE) -f " submakefile "\n\n"))))
91 (provide 'ede-proj-misc)
93 ;;; ede-proj-misc.el ends here