unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#61745] [PATCH] gnu: Add 9base.
@ 2023-02-24  3:18 Antero Mejr via Guix-patches via
  2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
  2023-03-10 13:49 ` bug#61745: [PATCH] gnu: Add 9base Ludovic Courtès
  0 siblings, 2 replies; 7+ messages in thread
From: Antero Mejr via Guix-patches via @ 2023-02-24  3:18 UTC (permalink / raw)
  To: 61745; +Cc: Antero Mejr

* 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





^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence).
  2023-02-24  3:18 [bug#61745] [PATCH] gnu: Add 9base Antero Mejr via Guix-patches via
@ 2023-02-24  3:22 ` Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 2/5] import: Add EUPL 1.1 to the SPDX license name converter Antero Mejr via Guix-patches via
                     ` (3 more replies)
  2023-03-10 13:49 ` bug#61745: [PATCH] gnu: Add 9base Ludovic Courtès
  1 sibling, 4 replies; 7+ messages in thread
From: Antero Mejr via Guix-patches via @ 2023-02-24  3:22 UTC (permalink / raw)
  To: 61745; +Cc: Antero Mejr

* 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





^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [bug#61745] [PATCH 2/5] import: Add EUPL 1.1 to the SPDX license name converter.
  2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
@ 2023-02-24  3:22   ` Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 3/5] gnu: r-mapproj: Correct license field to lpl1.02 Antero Mejr via Guix-patches via
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 7+ messages in thread
From: Antero Mejr via Guix-patches via @ 2023-02-24  3:22 UTC (permalink / raw)
  To: 61745; +Cc: Antero Mejr

* 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





^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [bug#61745] [PATCH 3/5] gnu: r-mapproj: Correct license field to lpl1.02.
  2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 2/5] import: Add EUPL 1.1 to the SPDX license name converter Antero Mejr via Guix-patches via
@ 2023-02-24  3:22   ` Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 4/5] gnu: Add lib9 Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 5/5] gnu: Add 9yacc Antero Mejr via Guix-patches via
  3 siblings, 0 replies; 7+ messages in thread
From: Antero Mejr via Guix-patches via @ 2023-02-24  3:22 UTC (permalink / raw)
  To: 61745; +Cc: Antero Mejr

* 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





^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [bug#61745] [PATCH 4/5] gnu: Add lib9.
  2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 2/5] import: Add EUPL 1.1 to the SPDX license name converter Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 3/5] gnu: r-mapproj: Correct license field to lpl1.02 Antero Mejr via Guix-patches via
@ 2023-02-24  3:22   ` Antero Mejr via Guix-patches via
  2023-02-24  3:22   ` [bug#61745] [PATCH 5/5] gnu: Add 9yacc Antero Mejr via Guix-patches via
  3 siblings, 0 replies; 7+ messages in thread
From: Antero Mejr via Guix-patches via @ 2023-02-24  3:22 UTC (permalink / raw)
  To: 61745; +Cc: Antero Mejr

* 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





^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [bug#61745] [PATCH 5/5] gnu: Add 9yacc.
  2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
                     ` (2 preceding siblings ...)
  2023-02-24  3:22   ` [bug#61745] [PATCH 4/5] gnu: Add lib9 Antero Mejr via Guix-patches via
@ 2023-02-24  3:22   ` Antero Mejr via Guix-patches via
  3 siblings, 0 replies; 7+ messages in thread
From: Antero Mejr via Guix-patches via @ 2023-02-24  3:22 UTC (permalink / raw)
  To: 61745; +Cc: Antero Mejr

* 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





^ permalink raw reply related	[flat|nested] 7+ messages in thread

* bug#61745: [PATCH] gnu: Add 9base.
  2023-02-24  3:18 [bug#61745] [PATCH] gnu: Add 9base Antero Mejr via Guix-patches via
  2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
@ 2023-03-10 13:49 ` Ludovic Courtès
  1 sibling, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2023-03-10 13:49 UTC (permalink / raw)
  To: Antero Mejr; +Cc: 61745-done

Hi Antero,

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

Thanks!

Ludo’.




^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2023-03-10 13:50 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-24  3:18 [bug#61745] [PATCH] gnu: Add 9base Antero Mejr via Guix-patches via
2023-02-24  3:22 ` [bug#61745] [PATCH 1/5] licenses: Add LPL 1.02 (Lucent Public Licence) Antero Mejr via Guix-patches via
2023-02-24  3:22   ` [bug#61745] [PATCH 2/5] import: Add EUPL 1.1 to the SPDX license name converter Antero Mejr via Guix-patches via
2023-02-24  3:22   ` [bug#61745] [PATCH 3/5] gnu: r-mapproj: Correct license field to lpl1.02 Antero Mejr via Guix-patches via
2023-02-24  3:22   ` [bug#61745] [PATCH 4/5] gnu: Add lib9 Antero Mejr via Guix-patches via
2023-02-24  3:22   ` [bug#61745] [PATCH 5/5] gnu: Add 9yacc Antero Mejr via Guix-patches via
2023-03-10 13:49 ` bug#61745: [PATCH] gnu: Add 9base Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

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).