GNU bug report logs -
#41578
[PATCH] gnu: Add opendoas.
Previous Next
Reported by: Morgan.J.Smith <at> outlook.com
Date: Thu, 28 May 2020 15:42:01 UTC
Severity: normal
Tags: patch
Done: Tobias Geerinckx-Rice <me <at> tobias.gr>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your message dated Sun, 31 May 2020 01:57:38 +0200
with message-id <87k10tyo0d.fsf <at> nckx>
and subject line Re: [bug#41578] [PATCH] gnu: Add opendoas.
has caused the debbugs.gnu.org bug report #41578,
regarding [PATCH] gnu: Add opendoas.
to be marked as done.
(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)
--
41578: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=41578
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Morgan Smith <Morgan.J.Smith <at> outlook.com>
* gnu/packages/admin.scm (opendoas): New variable.
---
gnu/packages/admin.scm | 51 ++++++++++++++++++++++++++++++++++++++++++
gnu/system.scm | 1 +
2 files changed, 52 insertions(+)
diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index b0a43d9644..594ec62c1d 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -1389,6 +1389,57 @@ commands and their arguments.")
;; See <http://www.sudo.ws/sudo/license.html>.
(license license:x11)))
+(define-public opendoas
+ (package
+ (name "opendoas")
+ (version "6.6.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/Duncaen/OpenDoas.git")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "07kkc5729p654jrgfsc8zyhiwicgmq38yacmwfvay2b3gmy728zn"))))
+ (build-system gnu-build-system)
+ (arguments (let* ((target (%current-target-system))
+ (compiler (if target
+ (string-append target "-gcc")
+ "gcc")))
+ `(#:phases
+ (modify-phases %standard-phases
+ ;; We replace the configure phase in order to remove all the
+ ;; default flags. The configure script doesn't accept most
+ ;; of the default flags
+ (replace 'configure
+ (lambda* (#:key configure-flags #:allow-other-keys)
+ ;; The configure script can only be told which
+ ;; compiler to use through environment variables
+ (setenv "CC" ,compiler)
+ (apply invoke "./configure" configure-flags)))
+ (add-before 'install 'fix-makefile
+ (lambda* (#:key outputs #:allow-other-keys)
+ ;; We can't chown to root as the chroot doesn't have
+ ;; this user. Also the store is owned by root so this
+ ;; isn't necessary.
+ (substitute* "bsd.prog.mk"
+ (("^\tchown.*$") "")))))
+ #:configure-flags (list (string-append "--prefix=" %output)
+ (string-append "--target=" (or ,target ""))
+ "--with-timestamp")
+ ;; Compiler choice is not carried over from the configure script
+ #:make-flags (list (string-append "CC=" ,compiler))
+ ;; There are no tests provided
+ #:tests? #f)))
+ (native-inputs `(("bison" ,bison)))
+ (home-page "https://github.com/Duncaen/OpenDoas")
+ (synopsis "Portable version of OpenBSD's doas command")
+ (description "Doas is a minimal replacement for the venerable sudo. It was
+initially written by Ted Unangst of the OpenBSD project to provide 95% of the
+features of sudo with a fraction of the codebase.")
+ (license license:isc)))
+
(define-public wpa-supplicant-minimal
(package
(name "wpa-supplicant-minimal")
diff --git a/gnu/system.scm b/gnu/system.scm
index d929187695..d5fd0979a1 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -896,6 +896,7 @@ use 'plain-file' instead~%")
(file-append inetutils "/bin/ping6")
(file-append sudo "/bin/sudo")
(file-append sudo "/bin/sudoedit")
+ (file-append opendoas "/bin/doas")
(file-append fuse "/bin/fusermount")
;; To allow mounts with the "user" option, "mount" and "umount" must
--
2.26.2
[Message part 3 (message/rfc822, inline)]
[Message part 4 (text/plain, inline)]
Morgan,
Morgan Smith 写道:
> I'm a little sad I didn't get torn apart more for technical
> reasons. I
> learned that phases must end in #t and a few style points. Maybe
> next
> time I'll throw in some terrible mistakes.
Don't give up!
> Also I realize that I totally forgot to put the copyright notice
> in!
> Could you throw
> ";;; Copyright © 2020 Morgan Smith <Morgan.J.Smith <at> outlook.com>"
> in there somewhere? I'm excited to get my name in this project!
Well, Marius stole my thunder with your other patch, but welcome
aboard!
Kind regards,
T G-R
[signature.asc (application/pgp-signature, inline)]
This bug report was last modified 5 years and 50 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.