all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Artyom V. Poptsov" <poptsov.artyom@gmail.com>
To: 57724@debbugs.gnu.org
Subject: [bug#57724] [PATCH] gnu: Add java-slf4j-nop.
Date: Sun, 11 Sep 2022 08:34:54 +0300	[thread overview]
Message-ID: <87o7vmjwxt.fsf@gmail.com> (raw)


[-- Attachment #1.1: Type: text/plain, Size: 46 bytes --]

Hello,

this patch adds "java-slf4j-nop". [1]

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: 0001-gnu-Add-java-slf4j-nop.patch --]
[-- Type: text/x-diff, Size: 2200 bytes --]

From 1368333635491a4bbe6f294f016a8cb63912ff35 Mon Sep 17 00:00:00 2001
From: "Artyom V. Poptsov" <poptsov.artyom@gmail.com>
Date: Fri, 9 Sep 2022 19:49:56 +0300
Subject: [PATCH] gnu: Add java-slf4j-nop.

* gnu/packages/java.scm (java-slf4j-nop): New variable.
---
 gnu/packages/java.scm | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 9fa9f61f12..45c3b423f0 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -8168,6 +8168,38 @@ (define-public java-slf4j-simple
 printed.")
     (license license:expat)))
 
+(define-public java-slf4j-nop
+  (package
+    (name "java-slf4j-nop")
+    (version "1.7.25")
+    (source (package-source java-slf4j-api))
+    (build-system ant-build-system)
+    (arguments
+     `(#:jar-name "slf4j-nop.jar"
+       #:source-dir "slf4j-nop/src/main"
+       #:test-dir "slf4j-nop/src/test"
+       #:phases (modify-phases %standard-phases
+                  ;; The tests need some test classes from slf4j-api
+                  (add-before 'check 'build-slf4j-api-test-helpers
+                    (lambda _
+                      ;; Add current dir to CLASSPATH ...
+                      (setenv "CLASSPATH"
+                              (string-append (getcwd) ":"
+                                             (getenv "CLASSPATH")))
+                      ;; ... and build test helper classes here:
+                      (apply invoke
+                             `("javac" "-d" "."
+                               ,@(find-files "slf4j-api/src/test" ".*\\.java")))))
+                  (replace 'install
+                    (install-from-pom "slf4j-nop/pom.xml")))))
+    (propagated-inputs (list java-slf4j-api))
+    (native-inputs (list java-junit java-hamcrest-core))
+    (home-page "https://www.slf4j.org/")
+    (synopsis "SLF4J binding that silently discards all logging messages")
+    (description "Binding/provider for NOP, an implementation that silently
+discards all logging messages.")
+    (license license:expat)))
+
 (define-public antlr2
   (package
     (name "antlr2")
-- 
2.34.1


[-- Attachment #1.3: Type: text/plain, Size: 394 bytes --]


- Artyom

References:
1. "Binding/provider for NOP, an implementation that silently discards
   all logging messages."
   <https://mvnrepository.com/artifact/org.slf4j/slf4j-nop>

-- 
Artyom "avp" Poptsov <poptsov.artyom@gmail.com>
Home page: https://memory-heap.org/~avp/
CADR Hackerspace co-founder: https://cadrspace.ru/
GPG: D0C2 EAC1 3310 822D 98DE  B57C E9C5 A2D9 0898 A02F

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 519 bytes --]

             reply	other threads:[~2022-09-11  5:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-11  5:34 Artyom V. Poptsov [this message]
2022-09-14  8:44 ` bug#57724: [PATCH] gnu: Add java-slf4j-nop Christopher Baines

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

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

  git send-email \
    --in-reply-to=87o7vmjwxt.fsf@gmail.com \
    --to=poptsov.artyom@gmail.com \
    --cc=57724@debbugs.gnu.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.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.