unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: calcium via <help-guix@gnu.org>
To: help-guix@gnu.org
Subject: Create package to add new files
Date: Mon, 27 Jun 2022 22:22:59 +0200	[thread overview]
Message-ID: <03f9e00e-3eb8-d6f3-ea71-7ff49a2126c3@disroot.org> (raw)

I tried using the procedures text-file* and plain-file but I can't manage to make it works.

Im trying to define a package that will be used to add files to cups, in the same ways taht the package brlaser add files. But no luck, every time I try to create a `plain-file` the build fails.

Help appreciated

(define-public
  add-my-filters-and-ppd
  (package/inherit
   brlaser
   (name "add-my-filters-and-ppd")
   (arguments
    `(#:phases
      (modify-phases
       %standard-phases
       ;; (delete 'configure) ;no 'configure' script
       (replace
        'install
        (lambda* (#:key outputs #:allow-other-keys)
                 ;; The package's Makefile doesn't provide an "install"
                 ;; rule so do it by ourselves.
                 (let ((filter-dir
                        (string-append (assoc-ref outputs "out")
                                       "/lib/cups/filter"))
                       (ppd-dir
                        (string-append (assoc-ref outputs "out")
                                       "/share/ppd/cupsfilters")))
                   ;; (install-file
                   ;;  (plain-file "brother_lpdwrapper_printer-model"
                   ;;              "ldwrapper string/content of file"))
                   ;; (install-file
                   ;;  (plain-file "brother-printer-model-cups-en.ppd"
                   ;;              ".ppd string/content of file")
                   ;;  ppd-dir)
                   )
                 #t)))))))


             reply	other threads:[~2022-06-27 20:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-27 20:22 calcium via [this message]
2022-08-18 14:19 ` Create package to add new files zimoun

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=03f9e00e-3eb8-d6f3-ea71-7ff49a2126c3@disroot.org \
    --to=help-guix@gnu.org \
    --cc=calcium@disroot.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).