emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] feature/integrated-elpa 48e846d 12/23: Build system now in


From: Phillip Lord
Subject: [Emacs-diffs] feature/integrated-elpa 48e846d 12/23: Build system now in generated makefile
Date: Fri, 16 Sep 2016 20:34:16 +0000 (UTC)

branch: feature/integrated-elpa
commit 48e846d1d28e9ab9904abeabcc769867d0b4744b
Author: Phillip Lord <address@hidden>
Commit: Phillip Lord <address@hidden>

    Build system now in generated makefile
---
 .gitignore                         |    2 +-
 lisp/emacs-lisp/package.el         |    2 +-
 packages/admin/package-build.el    |    2 +-
 packages/admin/package-makefile.el |   33 +++++++++++++--------------------
 packages/core/example/example.el   |   14 ++++++++++++++
 packages/core/example2/example2.el |   14 ++++++++++++++
 packages/temp.el                   |    4 +---
 7 files changed, 45 insertions(+), 26 deletions(-)

diff --git a/.gitignore b/.gitignore
index a81a515..b644934 100644
--- a/.gitignore
+++ b/.gitignore
@@ -142,7 +142,7 @@ src/stamp-h1
 *.res
 *.so
 [0-9]*.core
-core
+
 core.*[0-9]
 gmon.out
 oo/
diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
index baaa5e2..cf0417b 100644
--- a/lisp/emacs-lisp/package.el
+++ b/lisp/emacs-lisp/package.el
@@ -294,7 +294,7 @@ packages in `package-directory-list'."
            (push (expand-file-name "elpa" f) result)))
     (cons
      ;; And the inbuild ELPA directory
-     (concat (expand-file-name "../packages" data-directory))
+     (concat (expand-file-name "../packages/core" data-directory))
      (nreverse result)))
   "List of additional directories containing Emacs Lisp packages.
 Each directory name should be absolute.
diff --git a/packages/admin/package-build.el b/packages/admin/package-build.el
index 05b246c..71897a2 100644
--- a/packages/admin/package-build.el
+++ b/packages/admin/package-build.el
@@ -8,7 +8,7 @@
   (let ((descr
            (package-desc-create :name (make-symbol dir)))
           (location (package-build-dir dir)))
-      (archive--refresh-pkg-file location)
+      (archive-refresh-pkg-file location)
       (setq descr (package-load-descriptor location))
       (package-generate-autoloads (package-desc-name descr) location)
       (package-activate descr)
diff --git a/packages/admin/package-makefile.el 
b/packages/admin/package-makefile.el
index 34f32d6..ea8cece 100644
--- a/packages/admin/package-makefile.el
+++ b/packages/admin/package-makefile.el
@@ -1,18 +1,6 @@
-(defvar package-makefile-archives
-  '("core")
-  "List of directories with packages in them.
-
-Directories can be either relative to the \"packages\" directory
-or absolute. The order is important because we want to only build
-packages which occur earlier in the list.")
-
-(defvar package-makefile--packages-seen nil
-  "List of packages we have already seen.")
-
 (defun package-makefile--package-dirs (directory)
   (directory-files directory nil "[^.].*"))
 
-
 (defun package-makefile--target-pkg-el (top-dir base-dir)
   (format
    "%s-pkg: %s/%s/%s-pkg.el
@@ -27,24 +15,30 @@ packages which occur earlier in the list.")
    top-dir base-dir base-dir
    top-dir base-dir))
 
-(defun package-makefile--makefile-pkg-targets (top-dir)
+(defun package-makefile--makefile-pkg-targets (top-dir all-dirs)
   (concat
    "pkg-all: "
    (mapconcat
     'identity
-    (package-makefile--package-dirs top-dir) "" "-pkg ")
+    all-dirs
+    "-pkg ")
+   "-pkg"
    "\n\n"
    (mapconcat
     (lambda (base-dir)
       (package-makefile--target-pkg-el top-dir base-dir))
-    (package-makefile--package-dirs top-dir)
+    all-dirs
     "\n")))
 
+
+(defun package-makefile--core-packages ()
+  (package-makefile--package-dirs "core"))
+
 (defun package-makefile--makefile ()
-  (mapconcat
-   (lambda (top-dir)
-     (package-makefile--makefile-pkg-targets top-dir))
-   package-makefile-archives
+  (concat
+   (package-makefile--makefile-pkg-targets
+    "core"
+    (package-makefile--core-packages))
    "\n"))
 
 
@@ -52,7 +46,6 @@ packages which occur earlier in the list.")
   (with-temp-buffer
     (insert
      (package-makefile--makefile))
-    
     (write-file "gnumakefile-inc.mk")))
 
 ;; example: core/example/example-pkg.el
diff --git a/packages/core/example/example.el b/packages/core/example/example.el
new file mode 100644
index 0000000..9044b09
--- /dev/null
+++ b/packages/core/example/example.el
@@ -0,0 +1,14 @@
+;;; example.el --- An Example
+
+;;; Header:
+
+;; This file is not part of Emacs
+
+;; Author: Phillip Lord <address@hidden>
+;; Maintainer: Phillip Lord <address@hidden>
+;; Version: 0.1
+
+;;;###autoload
+(defun example ()
+  (interactive)
+  (message "Hello from Example"))
diff --git a/packages/core/example2/example2.el 
b/packages/core/example2/example2.el
new file mode 100644
index 0000000..352078d
--- /dev/null
+++ b/packages/core/example2/example2.el
@@ -0,0 +1,14 @@
+;;; example2.el --- An Example
+
+;;; Header:
+
+;; This file is not part of Emacs
+
+;; Author: Phillip Lord <address@hidden>
+;; Maintainer: Phillip Lord <address@hidden>
+;; Version: 0.1
+
+;;;###autoload
+(defun example2 ()
+  (interactive)
+  (message "Hello from Example2"))
diff --git a/packages/temp.el b/packages/temp.el
index fb2399a..23e7e80 100644
--- a/packages/temp.el
+++ b/packages/temp.el
@@ -8,6 +8,4 @@
 
 (package-build-prepare "core/example")
 
-(defun temp ()
-  (interactive)
-  (package-makefile))
+(package-makefile)



reply via email to

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