emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] scratch/last-cedet-merge 6d6b045 27/50: EDE: Improve Emacs


From: David Engster
Subject: [Emacs-diffs] scratch/last-cedet-merge 6d6b045 27/50: EDE: Improve Emacs project type
Date: Wed, 25 Jan 2017 22:15:22 +0000 (UTC)

branch: scratch/last-cedet-merge
commit 6d6b045ab6a64480fd8266f7a727174cfec397e7
Author: Eric Ludlam <address@hidden>
Commit: David Engster <address@hidden>

    EDE: Improve Emacs project type
    
    * lisp/cedet/ede/emacs.el (ede-emacs-target-texi): New.
     (ede-find-target): Add texi support.
     (project-compile-project) (ede-compile-target)
     (ede-compile-target) (ede-compile-target): New
---
 lisp/cedet/ede/emacs.el |   41 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 41 insertions(+)

diff --git a/lisp/cedet/ede/emacs.el b/lisp/cedet/ede/emacs.el
index cac66fa..2797533 100644
--- a/lisp/cedet/ede/emacs.el
+++ b/lisp/cedet/ede/emacs.el
@@ -136,6 +136,11 @@ All directories need at least one target.")
   "EDE Emacs Project target for Emacs Lisp code.
 All directories need at least one target.")
 
+(defclass ede-emacs-target-texi (ede-target)
+  ()
+  "EDE Emacs Project target for Emacs Lisp code.
+All directories need at least one target.")
+
 (defclass ede-emacs-target-misc (ede-target)
   ()
   "EDE Emacs Project target for Misc files.
@@ -186,6 +191,8 @@ If one doesn't exist, create a new one for this directory."
                     'ede-emacs-target-c)
                    ((string-match "elc?" ext)
                     'ede-emacs-target-el)
+                   ((string-match "texi" ext)
+                    'ede-emacs-target-texi)
                    (t 'ede-emacs-target-misc)))
         (targets (oref proj targets))
         (dir default-directory)
@@ -282,6 +289,40 @@ Knows about how the Emacs source tree is organized."
     (oset this version (cdr ver))
     ))
 
+;;; Compile Support
+;;
+(defmethod project-compile-project ((proj ede-emacs-project) &optional command)
+  "Compile the Emacs project.
+Argument COMMAND is the command to use when compiling."
+  (let ((default-directory (ede-project-root-directory proj)))
+    (require 'compile)
+    (compile "make all")))
+
+(defmethod project-compile-target ((proj ede-emacs-target-texi) &optional 
command)
+  "Compile the doc target for Emacs.
+Argument COMMAND is the command to use for compiling the target."
+  (let* ((default-directory (ede-project-root-directory (ede-current-project)))
+        (command "make docs"))
+    (require 'compile)
+    (compile command)))
+
+(defmethod project-compile-target ((proj ede-emacs-target-el) &optional 
command)
+  "Compile the doc target for Emacs.
+Argument COMMAND is the command to use for compiling the target."
+  (let* ((default-directory (ede-project-root-directory (ede-current-project)))
+        (command "make lisp"))
+    (require 'compile)
+    (compile command)))
+
+(defmethod project-compile-target ((proj ede-emacs-target-c) &optional command)
+  "Compile the doc target for Emacs.
+Argument COMMAND is the command to use for compiling the target."
+  (let* ((default-directory (ede-project-root-directory (ede-current-project)))
+        (command "make src"))
+    (require 'compile)
+    (compile command)))
+
+
 (provide 'ede/emacs)
 
 ;; Local variables:



reply via email to

[Prev in Thread] Current Thread [Next in Thread]