[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
03/03: gnu: clang-from-llvm: Clean up share/clang folder.
From: |
guix-commits |
Subject: |
03/03: gnu: clang-from-llvm: Clean up share/clang folder. |
Date: |
Mon, 26 Nov 2018 08:53:51 -0500 (EST) |
ambrevar pushed a commit to branch master
in repository guix.
commit 1c7372a5aadea84165376a4b8e2664b67a663c56
Author: Pierre Neidhardt <address@hidden>
Date: Mon Nov 26 14:51:40 2018 +0100
gnu: clang-from-llvm: Clean up share/clang folder.
* gnu/packages/llvm.scm (clang-from-llvm): Remove useless files, install
completion.
---
gnu/packages/llvm.scm | 21 ++++++++++++++++++++-
1 file changed, 20 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 276a89c..0b12f73 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -235,7 +235,26 @@ compiler. In LLVM this library is called
\"compiler-rt\".")
(substitute* "lib/Driver/ToolChains.cpp"
(("@GLIBC_LIBDIR@")
(string-append libc "/lib")))))
- #t))))))
+ #t)))
+ (add-after 'install 'install-clean-up-/share/clang
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (compl-dir (string-append
+ out "/etc/bash_completion.d")))
+ (with-directory-excursion (string-append out
+
"/share/clang")
+ ;; Delete extensions for proprietary text editors.
+ (delete-file "clang-format-bbedit.applescript")
+ (delete-file "clang-format-sublime.py")
+ ;; Delete Emacs extensions: see their respective
Emacs
+ ;; Guix package instead.
+ (delete-file "clang-rename.el")
+ (delete-file "clang-format.el")
+ ;; Install bash completion.
+ (mkdir-p compl-dir)
+ (rename-file "bash-autocomplete.sh"
+ (string-append compl-dir "/clang"))))
+ #t)))))
;; Clang supports the same environment variables as GCC.
(native-search-paths