~ruther/guix-local

706c2fa0a954e0847654a03c8e48fb7386c80479 — Anderson Torres 4 months ago efa6687
gnu: tecoc: New package.

* gnu/packages/text-editors.scm(tecoc): New variable.

Change-Id: I6529022c5fa183aa91de51af45ea1bd3aeb24bfd
Signed-off-by: Cayetano Santos <csantosb@inventati.org>
1 files changed, 52 insertions(+), 0 deletions(-)

M gnu/packages/text-editors.scm
M gnu/packages/text-editors.scm => gnu/packages/text-editors.scm +52 -0
@@ 1407,6 1407,58 @@ more.")
     "Mogan is a scientific structural text editor, a fork of GNU TeXmacs.")
    (license license:gpl3+)))

(define-public tecoc
  ;; No tagged releases; this is the master tip.
  (let ((commit "b4a96395a18c7e64ccaef0e25fdde3b7ef33ac4b")
        (revision "0"))
    (package
      (name "tecoc")
      ;; Version taken from tecoc.h
      (version (git-version "147" revision commit))
      (source
       (origin
         (method git-fetch)
         (uri (git-reference
                (url "https://github.com/blakemcbride/TECOC")
                (commit commit)))
         (file-name (git-file-name name version))
         (sha256
          (base32 "0q6kcynvrhwl0pmyvdrkdzg0nxshrn05cdp5knn1s9ki7fqqccr9"))))
      (build-system gnu-build-system)
      (arguments
       (list
        #:tests? #f                     ; No tests
        #:make-flags
        #~(list "-C" "src"
                "-f" "makefile.linux"
                (string-append "CC=" #$(cc-for-target)))
        #:phases
        #~(modify-phases %standard-phases
            (delete 'configure)
            (replace 'install
              (lambda _
                (let ((bin-dir (string-append #$output "/bin"))
                      (doc-dir (string-append #$output:doc "/share/doc/"
                                              #$name "-" #$version)))
                  (install-file "src/tecoc" bin-dir)
                  (for-each (lambda (file)
                              (install-file file doc-dir))
                            (find-files "doc")))))
            (add-after 'install 'create-symlinks
              (lambda _
                (with-directory-excursion (string-append #$output "/bin")
                  (for-each (lambda (link)
                              (symlink "tecoc" link))
                            (list "Make" "inspect" "mung" "teco"))))))))
      (outputs (list "out" "doc"))
      (inputs (list ncurses))
      (synopsis "@acronym{TECO, Text Editor and Corrector} written in C")
      (description
       "Tecoc is a portable version of the venerable @acronym{TECO, Text Editor
and Corrector} written in C that strives to keep the original behavior.")
      (home-page "https://github.com/blakemcbride/TECOC")
      (license license:bsd-3))))

(define-public textpieces
  (package
    (name "textpieces")