public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Volkmar W. Pogatzki" <gentoo@pogatzki.net>
To: gentoo-dev@lists.gentoo.org
Subject: [gentoo-dev] [PATCH] java-pkg-simple.eclass: respect SLOT="0" in  JAVA_LAUNCHER_FILENAME
Date: Fri, 26 May 2023 10:16:46 +0200	[thread overview]
Message-ID: <20230526081646.7272-1-gentoo@pogatzki.net> (raw)

Avoids the need for setting JAVA_LAUNCHER_FILENAME="${PN}" if SLOT is 0.

Signed-off-by: Volkmar W. Pogatzki <gentoo@pogatzki.net>
---
 eclass/java-pkg-simple.eclass | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/eclass/java-pkg-simple.eclass b/eclass/java-pkg-simple.eclass
index 929ce68c6c07..f919945280b1 100644
--- a/eclass/java-pkg-simple.eclass
+++ b/eclass/java-pkg-simple.eclass
@@ -161,7 +161,11 @@ fi
 # If ${JAVA_MAIN_CLASS} is set, we will create a launcher to
 # execute the jar, and ${JAVA_LAUNCHER_FILENAME} will be the
 # name of the script.
-: "${JAVA_LAUNCHER_FILENAME:=${PN}-${SLOT}}"
+if [[ ${SLOT} = 0 ]]; then
+	JAVA_LAUNCHER_FILENAME="${PN}"
+else
+	JAVA_LAUNCHER_FILENAME="${PN}-${SLOT}"
+fi
 
 # @ECLASS_VARIABLE: JAVA_TESTING_FRAMEWORKS
 # @DEFAULT_UNSET
-- 
2.39.3



             reply	other threads:[~2023-05-26  8:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-26  8:16 Volkmar W. Pogatzki [this message]
2023-05-26  8:44 ` [gentoo-dev] [PATCH] java-pkg-simple.eclass: respect SLOT="0" in JAVA_LAUNCHER_FILENAME Ulrich Mueller
2023-05-29  7:13   ` Volkmar W. Pogatzki
2023-05-29  9:51     ` Ulrich Mueller

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=20230526081646.7272-1-gentoo@pogatzki.net \
    --to=gentoo@pogatzki.net \
    --cc=gentoo-dev@lists.gentoo.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