mirror of
https://github.com/correl/melpa.git
synced 2024-11-14 19:19:32 +00:00
Use "gtar" for "tar" if available.
BSD tar on OS X doesn't handle certain packages properly, e.g. "@". Homebrew on OS X installs gnu-tar as "gtar", so we use that command in preference to "tar" if available. See #1732
This commit is contained in:
parent
f6ab31b937
commit
3ba3477384
1 changed files with 9 additions and 1 deletions
|
@ -87,6 +87,14 @@ This must be a version which supports the \"-k\" option."
|
|||
:group 'package-build
|
||||
:type '(file :must-match t))
|
||||
|
||||
(defcustom package-build-tar-executable
|
||||
(or (executable-find "gtar")
|
||||
(executable-find "tar"))
|
||||
"Path to a (preferably GNU) tar command.
|
||||
Certain package names (e.g. \"@\") may not work properly with a BSD tar."
|
||||
:group 'package-build
|
||||
:type '(file :must-match t))
|
||||
|
||||
;;; Internal Variables
|
||||
|
||||
(defvar pb/recipe-alist nil
|
||||
|
@ -555,7 +563,7 @@ Optionally PRETTY-PRINT the data."
|
|||
(defun pb/create-tar (file dir &optional files)
|
||||
"Create a tar FILE containing the contents of DIR, or just FILES if non-nil."
|
||||
(apply 'process-file
|
||||
"tar" nil
|
||||
package-build-tar-executable nil
|
||||
(get-buffer-create "*package-build-checkout*")
|
||||
nil "-cvf"
|
||||
file
|
||||
|
|
Loading…
Reference in a new issue