GNU bug report logs - #61745
[PATCH] gnu: Add 9base.

Previous Next

Package: guix-patches;

Reported by: Antero Mejr <antero <at> mailbox.org>

Date: Fri, 24 Feb 2023 03:19:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 61745 in the body.
You can then email your comments to 61745 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#61745; Package guix-patches. (Fri, 24 Feb 2023 03:19:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Antero Mejr <antero <at> mailbox.org>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Fri, 24 Feb 2023 03:19:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Antero Mejr <antero <at> mailbox.org>
To: guix-patches <at> gnu.org
Cc: Antero Mejr <antero <at> mailbox.org>
Subject: [PATCH] gnu: Add 9base.
Date: Fri, 24 Feb 2023 03:18:03 +0000
* gnu/packages/suckless.scm (9base): New variable.
---
 gnu/packages/suckless.scm | 37 +++++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/suckless.scm b/gnu/packages/suckless.scm
index cfd70df027..400832045f 100644
--- a/gnu/packages/suckless.scm
+++ b/gnu/packages/suckless.scm
@@ -48,6 +48,7 @@ (define-module (gnu packages suckless)
   #:use-module (gnu packages mpd)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages shells)
   #:use-module (gnu packages webkit)
   #:use-module (gnu packages xorg)
   #:use-module (guix build-system cargo)
@@ -1355,3 +1356,39 @@ (define-public 9yacc
     (description
      "This package provides a ported version of the Plan 9 yacc parser
 generator.")))
+
+(define-public 9base
+  (package
+    (inherit 9yacc)
+    (name "9base")
+    (arguments
+     (substitute-keyword-arguments (package-arguments 9yacc)
+       ((#:phases phases)
+        #~(modify-phases #$phases
+            (add-after 'patch-for-9yacc 'patch-for-9base
+              (lambda _
+                (substitute* "Makefile"
+                  (("SUBDIRS  = lib9\\\\")
+                   "SUBDIRS = \\")
+                  (("@chmod 755 yacc/9yacc")
+                   ""))
+                (for-each (lambda (x)
+                            (substitute* "Makefile"
+                              (((string-append x "\\\\")) "\\")))
+                          '("yacc" "diff" "hoc" "rc"))
+                (substitute* "sam/Makefile"
+                  (("\\$\\{CFLAGS\\}")
+                   "${CFLAGS} -I."))
+                (substitute* "config.mk"
+                  (("^YACC.*=.*$")
+                   (string-append "YACC=" #$(this-package-native-input "9yacc")
+                                  "/bin/yacc\n")))))
+            (delete 'chdir)
+            (delete 'install-yaccpar)))))
+    (native-inputs (list 9yacc))
+    (inputs (list lib9))
+    (propagated-inputs (list rc))
+    (synopsis "Port of various Plan 9 tools for Unix")
+    (description
+     "This package provides ported versions of various Plan 9 userland tools
+for Unix.")))
-- 
2.38.1





Information forwarded to guix-patches <at> gnu.org:
bug#61745; Package guix-patches. (Fri, 24 Feb 2023 03:23:02 GMT) Full text and rfc822 format available.

Message #8 received at 61745 <at> debbugs.gnu.org (full text, mbox):

From: Antero Mejr <antero <at> mailbox.org>
To: 61745 <at> debbugs.gnu.org
Cc: Antero Mejr <antero <at> mailbox.org>
Subject: [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence).
Date: Fri, 24 Feb 2023 03:22:16 +0000
* guix/licenses.scm (lpl1.02): New variable.
* guix/import/utils.scm (spdx-string->license): Add LPL-1.02 identifier.
---
Sorry about the ordering, please apply the 9base patch last.

 guix/import/utils.scm | 1 +
 guix/licenses.scm     | 6 ++++++
 2 files changed, 7 insertions(+)

diff --git a/guix/import/utils.scm b/guix/import/utils.scm
index 72795d2c61..ee64faa886 100644
--- a/guix/import/utils.scm
+++ b/guix/import/utils.scm
@@ -244,6 +244,7 @@ (define %spdx-license-identifiers
     ("LGPL-3.0-only"              . license:lgpl3)
     ("LGPL-3.0+"                  . license:lgpl3+)
     ("LGPL-3.0-or-later"          . license:lgpl3+)
+    ("LPL-1.02"                   . license:lpl1.02)
     ("LPPL-1.0"                   . license:lppl)
     ("LPPL-1.1"                   . license:lppl)
     ("LPPL-1.2"                   . license:lppl1.2)
diff --git a/guix/licenses.scm b/guix/licenses.scm
index f7df5826bf..e7e6ef3545 100644
--- a/guix/licenses.scm
+++ b/guix/licenses.scm
@@ -75,6 +75,7 @@ (define-module (guix licenses)
             knuth
             lal1.3
             lgpl2.0 lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3 lgpl3+ llgpl
+            lpl1.02
             lppl lppl1.0+ lppl1.1+ lppl1.2 lppl1.2+
             lppl1.3 lppl1.3+
             lppl1.3a lppl1.3a+
@@ -516,6 +517,11 @@ (define llgpl
            "https://opensource.franz.com/preamble.html"
            "Lisp Lesser General Public License"))
 
+(define lpl1.02 ;Lucent
+  (license "LPL 1.02"
+           "https://directory.fsf.org/wiki/License:LPL-1.02"
+           "https://www.gnu.org/licenses/license-list.html#lucent102"))
+
 (define lppl
   (license "LPPL (any version)"
            "https://www.latex-project.org/lppl/lppl-1-0/"
-- 
2.38.1





Information forwarded to guix-patches <at> gnu.org:
bug#61745; Package guix-patches. (Fri, 24 Feb 2023 03:23:02 GMT) Full text and rfc822 format available.

Message #11 received at 61745 <at> debbugs.gnu.org (full text, mbox):

From: Antero Mejr <antero <at> mailbox.org>
To: 61745 <at> debbugs.gnu.org
Cc: Antero Mejr <antero <at> mailbox.org>
Subject: [PATCH 2/5] import: Add EUPL 1.1 to the SPDX license name converter.
Date: Fri, 24 Feb 2023 03:22:17 +0000
* guix/import/utils.scm (spdx-string->license): Add EUPL-1.1 identifier.
---
 guix/import/utils.scm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/guix/import/utils.scm b/guix/import/utils.scm
index ee64faa886..2da5d93a67 100644
--- a/guix/import/utils.scm
+++ b/guix/import/utils.scm
@@ -198,6 +198,7 @@ (define %spdx-license-identifiers
     ("CPL-1.0"                    . license:cpl1.0)
     ("EPL-1.0"                    . license:epl1.0)
     ("EPL-2.0"                    . license:epl2.0)
+    ("EUPL-1.1"                   . license:eupl1.1)
     ("EUPL-1.2"                   . license:eupl1.2)
     ("MIT"                        . license:expat)
     ("MIT-0"                      . license:expat-0)
-- 
2.38.1





Information forwarded to guix-patches <at> gnu.org:
bug#61745; Package guix-patches. (Fri, 24 Feb 2023 03:23:02 GMT) Full text and rfc822 format available.

Message #14 received at 61745 <at> debbugs.gnu.org (full text, mbox):

From: Antero Mejr <antero <at> mailbox.org>
To: 61745 <at> debbugs.gnu.org
Cc: Antero Mejr <antero <at> mailbox.org>
Subject: [PATCH 3/5] gnu: r-mapproj: Correct license field to lpl1.02.
Date: Fri, 24 Feb 2023 03:22:18 +0000
* gnu/packages/cran.scm (r-mapproj): Correct license.
[license]: Change to lpl1.02.
---
 gnu/packages/cran.scm | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index c7a81b96eb..4fac45a91d 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -4360,9 +4360,7 @@ (define-public r-mapproj
     (description "This package converts latitude/longitude into projected
 coordinates.")
     (license (list license:gpl2          ; The R interface
-                   (license:non-copyleft ; The C code
-                    "https://www.gnu.org/licenses/license-list.en.html#lucent102"
-                    "Lucent Public License Version 1.02")))))
+                   license:lpl1.02))))   ; The C code
 
 (define-public r-rgooglemaps
   (package
-- 
2.38.1





Information forwarded to guix-patches <at> gnu.org:
bug#61745; Package guix-patches. (Fri, 24 Feb 2023 03:24:02 GMT) Full text and rfc822 format available.

Message #17 received at 61745 <at> debbugs.gnu.org (full text, mbox):

From: Antero Mejr <antero <at> mailbox.org>
To: 61745 <at> debbugs.gnu.org
Cc: Antero Mejr <antero <at> mailbox.org>
Subject: [PATCH 4/5] gnu: Add lib9.
Date: Fri, 24 Feb 2023 03:22:19 +0000
* gnu/packages/suckless.scm (lib9): New variable.
---
 gnu/packages/suckless.scm | 72 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 72 insertions(+)

diff --git a/gnu/packages/suckless.scm b/gnu/packages/suckless.scm
index 8844482cc9..7f79e9d7e9 100644
--- a/gnu/packages/suckless.scm
+++ b/gnu/packages/suckless.scm
@@ -1252,3 +1252,75 @@ (define-public svkbd
     (description "svkbd is a simple virtual keyboard, intended to be used in
 environments, where no keyboard is available.")
     (license license:expat)))
+
+(define-public lib9
+  ;; no release since 2010
+  (let ((commit "63916da7bd6d73d9a405ce83fc4ca34845667cce")
+        (revision "0"))
+    (package
+      (name "lib9")
+      (version (git-version "7" revision commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://git.suckless.org/9base/")
+                      (commit commit)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "04j8js4s3jmlzi3m46q81bq76rn41an58ffhkbj9p5wwr5hvplh8"))))
+      (build-system gnu-build-system)
+      (arguments
+       (list #:tests? #f ;no tests
+             #:phases #~(modify-phases %standard-phases
+                          (add-after 'unpack 'patch
+                            (lambda _
+                              (substitute* "config.mk"
+                                (("^PREFIX.*=.*$")
+                                 (string-append "PREFIX=\"" #$output "\"\n"))
+                                (("^OBJTYPE.*=.*$")
+                                 #$@(cond
+                                     ((target-x86-64?)
+                                      #~(string-append "OBJTYPE=x86_64\n"))
+                                     ((target-x86?)
+                                      #~(string-append "OBJTYPE=386\n"))
+                                     ((target-powerpc?)
+                                      #~(string-append "OBJTYPE=power\n"))
+                                     ((target-arm32?)
+                                      #~(string-append "OBJTYPE=arm\n"))))
+                                (("^CFLAGS.*+=.*$")
+                                 (string-append
+                                  "CFLAGS+=-O2 -g -I. -fPIC -c -DPLAN9PORT "
+                                  "-DPREFIX=\\\"" #$output "\\\"\n"))
+                                (("^LDFLAGS.*+=.*$")
+                                 "LDFLAGS+=\n")
+                                (("^CC.*=.*$")
+                                 (string-append "CC=" #$(cc-for-target) "\n")))
+                              (substitute* "lib9/libc.h"
+                                (("#define main.*p9main")
+                                 ""))
+                              (substitute* "lib9/main.c"
+                                (("p9main\\(argc, argv\\);")
+                                 "")
+                                (("extern void p9main\\(int, char\\*\\*\\);")
+                                 ""))
+                              (substitute* "lib9/Makefile"
+                                (("lib9.a")
+                                 "lib9.so")
+                                (("LIB9OFILES=\\\\")
+                                 "LIB9OFILES=convM2D.o \\")
+                                (("@\\$\\{AR\\} \\$\\{LIB\\} \\$\\{OFILES\\}")
+                                 "gcc -shared  ${OFILES} -o lib9.so"))))
+                          (add-after 'patch 'chdir
+                            (lambda _
+                              (chdir "lib9")))
+                          (delete 'configure)))) ;no configure script
+      (home-page "https://tools.suckless.org/9base/")
+      (supported-systems '("x86_64-linux" "i686-linux" "armhf-linux"
+                           "powerpc-linux"))
+      (synopsis "Unix port of Plan 9's formatted I/O C library")
+      (description
+       "This package provides a ported version of the Plan 9 lib9 C library.
+It also contains the Plan 9 libbio, libregexp, libfmt and libutf libraries.")
+      (license (list license:expat ;modifications
+                     license:lpl1.02))))) ;original plan9 code
-- 
2.38.1





Information forwarded to guix-patches <at> gnu.org:
bug#61745; Package guix-patches. (Fri, 24 Feb 2023 03:24:02 GMT) Full text and rfc822 format available.

Message #20 received at 61745 <at> debbugs.gnu.org (full text, mbox):

From: Antero Mejr <antero <at> mailbox.org>
To: 61745 <at> debbugs.gnu.org
Cc: Antero Mejr <antero <at> mailbox.org>
Subject: [PATCH 5/5] gnu: Add 9yacc.
Date: Fri, 24 Feb 2023 03:22:20 +0000
* gnu/packages/suckless.scm (9yacc): New variable.
---
 gnu/packages/suckless.scm | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/gnu/packages/suckless.scm b/gnu/packages/suckless.scm
index 7f79e9d7e9..cfd70df027 100644
--- a/gnu/packages/suckless.scm
+++ b/gnu/packages/suckless.scm
@@ -1324,3 +1324,34 @@ (define-public lib9
 It also contains the Plan 9 libbio, libregexp, libfmt and libutf libraries.")
       (license (list license:expat ;modifications
                      license:lpl1.02))))) ;original plan9 code
+
+(define-public 9yacc
+  (package
+    (inherit lib9)
+    (name "9yacc")
+    (arguments
+     (substitute-keyword-arguments (package-arguments lib9)
+       ((#:phases phases)
+        #~(modify-phases #$phases
+            (add-after 'patch 'patch-for-9yacc
+              (lambda _
+                (substitute* "yacc/yacc.c"
+                  (("#9/yacc")
+                   (string-append #$output "/lib")))
+                (substitute* "config.mk"
+                  (("^CFLAGS.*+=.*$")
+                   (string-append "CFLAGS+=-O2 -g -c -DPLAN9PORT "
+                                  "-DPREFIX=\\\"" #$output "\\\"\n")))))
+            (replace 'chdir
+              (lambda _
+                (chdir "yacc")))
+            (delete 'install-include)
+            (add-after 'install 'install-yaccpar
+              (lambda _
+                (install-file "yaccpar" (string-append #$output "/lib"))
+                (install-file "yaccpars" (string-append #$output "/lib"))))))))
+    (inputs (list lib9))
+    (synopsis "Port of Plan 9's yacc parser generator for Unix")
+    (description
+     "This package provides a ported version of the Plan 9 yacc parser
+generator.")))
-- 
2.38.1





Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Fri, 10 Mar 2023 13:50:01 GMT) Full text and rfc822 format available.

Notification sent to Antero Mejr <antero <at> mailbox.org>:
bug acknowledged by developer. (Fri, 10 Mar 2023 13:50:01 GMT) Full text and rfc822 format available.

Message #25 received at 61745-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Antero Mejr <antero <at> mailbox.org>
Cc: 61745-done <at> debbugs.gnu.org
Subject: Re: bug#61745: [PATCH] gnu: Add 9base.
Date: Fri, 10 Mar 2023 14:49:32 +0100
Hi Antero,

Applied all six patches (the sixth one being ‘9base’, the first in this
series).

Thanks!

Ludo’.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 08 Apr 2023 11:24:08 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 19 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.