public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Ulrich Müller" <ulm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/proj/emacs:master commit in: app-emacs/erc-sasl/, app-emacs/erc-sasl/files/
Date: Wed, 28 Jul 2021 09:37:51 +0000 (UTC)	[thread overview]
Message-ID: <1627464980.7c9adf99a941f66592a7f927df2b6224e887963a.ulm@gentoo> (raw)

commit:     7c9adf99a941f66592a7f927df2b6224e887963a
Author:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 28 08:25:02 2021 +0000
Commit:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
CommitDate: Wed Jul 28 09:36:20 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/emacs.git/commit/?id=7c9adf99

app-emacs/erc-sasl: Initial import

Ebuild contributed by me.

Package-Manager: Portage-3.0.20, Repoman-3.0.3
Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org>

 app-emacs/erc-sasl/Manifest                        |  1 +
 app-emacs/erc-sasl/erc-sasl-20190215.ebuild        | 24 +++++++++++++++
 app-emacs/erc-sasl/files/50erc-sasl-gentoo.el      |  3 ++
 .../files/erc-sasl-20190215-byte-compile.patch     | 10 +++++++
 .../erc-sasl/files/erc-sasl-20190215-cl.patch      | 34 ++++++++++++++++++++++
 .../erc-sasl/files/erc-sasl-20190215-login.patch   | 32 ++++++++++++++++++++
 app-emacs/erc-sasl/metadata.xml                    |  8 +++++
 7 files changed, 112 insertions(+)

diff --git a/app-emacs/erc-sasl/Manifest b/app-emacs/erc-sasl/Manifest
new file mode 100644
index 0000000..ffe02fe
--- /dev/null
+++ b/app-emacs/erc-sasl/Manifest
@@ -0,0 +1 @@
+DIST erc-sasl-20190215.tar.gz 1716 BLAKE2B 755aca8647981cf39ebfe6441ca40733c565e656ecd708486e701554c9c7dc257744fc8ff131b91aed2a837e518d4908f953687ccaf45828d057664c1ed9a736 SHA512 287036acb9ec7402a63037851336ddca6f96988afd1dd970e3589285b2980900fe9a878164950e3d1ec1c48e0d3d5d31d97c2d9dd9a9bdf9db963444356db3ee

diff --git a/app-emacs/erc-sasl/erc-sasl-20190215.ebuild b/app-emacs/erc-sasl/erc-sasl-20190215.ebuild
new file mode 100644
index 0000000..c2fa1ed
--- /dev/null
+++ b/app-emacs/erc-sasl/erc-sasl-20190215.ebuild
@@ -0,0 +1,24 @@
+# Copyright 2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+NEED_EMACS=24.5
+
+inherit elisp
+
+COMMIT="0fa60fdf8c2c1cdbe048e5189e35e480fe931c20"
+DESCRIPTION="SASL authentication for ERC"
+HOMEPAGE="https://gitlab.com/psachin/erc-sasl"
+SRC_URI="https://gitlab.com/psachin/${PN}/-/archive/${COMMIT}/${PN}-${COMMIT}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${PN}-${COMMIT}"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+PATCHES=(
+	"${FILESDIR}"/${P}-cl.patch
+	"${FILESDIR}"/${P}-byte-compile.patch
+	"${FILESDIR}"/${P}-login.patch
+)
+SITEFILE="50${PN}-gentoo.el"

diff --git a/app-emacs/erc-sasl/files/50erc-sasl-gentoo.el b/app-emacs/erc-sasl/files/50erc-sasl-gentoo.el
new file mode 100644
index 0000000..b334ea1
--- /dev/null
+++ b/app-emacs/erc-sasl/files/50erc-sasl-gentoo.el
@@ -0,0 +1,3 @@
+(add-to-list 'load-path "@SITELISP@")
+(eval-after-load 'erc
+  (load "erc-sasl-login" nil t))

diff --git a/app-emacs/erc-sasl/files/erc-sasl-20190215-byte-compile.patch b/app-emacs/erc-sasl/files/erc-sasl-20190215-byte-compile.patch
new file mode 100644
index 0000000..d94be0b
--- /dev/null
+++ b/app-emacs/erc-sasl/files/erc-sasl-20190215-byte-compile.patch
@@ -0,0 +1,10 @@
+--- a/erc-sasl.el
++++ b/erc-sasl.el
+@@ -38,6 +38,7 @@
+ ;;; Code:
+ 
+ (eval-when-compile (require 'cl-lib))
++(require 'erc)
+ 
+ (defvar erc-sasl-use-sasl t
+   "Set to nil to disable SASL auth")

diff --git a/app-emacs/erc-sasl/files/erc-sasl-20190215-cl.patch b/app-emacs/erc-sasl/files/erc-sasl-20190215-cl.patch
new file mode 100644
index 0000000..1ba9bb8
--- /dev/null
+++ b/app-emacs/erc-sasl/files/erc-sasl-20190215-cl.patch
@@ -0,0 +1,34 @@
+Some updates from https://github.com/syl20bnr/spacemacs
+
+commit 2a983671af6652964b04382760ca530475debfc5
+Author: Yen-Chin Lee <coldnew.tw@gmail.com>
+Date:   Mon Oct 5 15:22:35 2015 +0800
+
+    Fix some cl-lib function with prefix
+
+commit da8063437052943f749bc0f14c5ef5a7536aeaac
+Author: kimr <kimr@synopsys.com>
+Date:   Sat Dec 14 09:14:56 2019 -0800
+
+    converted cl to cl-lib
+
+--- a/erc-sasl.el
++++ b/erc-sasl.el
+@@ -37,7 +37,7 @@
+ 
+ ;;; Code:
+ 
+-(eval-when-compile (require 'cl))
++(eval-when-compile (require 'cl-lib))
+ 
+ (defvar erc-sasl-use-sasl t
+   "Set to nil to disable SASL auth")
+@@ -51,7 +51,7 @@
+ current session"
+   (and erc-sasl-use-sasl
+        (boundp 'erc-session-server)
+-       (loop for re in erc-sasl-server-regexp-list
++       (cl-loop for re in erc-sasl-server-regexp-list
+              thereis (integerp (string-match re erc-session-server)))))
+ 
+ (define-erc-response-handler (CAP)

diff --git a/app-emacs/erc-sasl/files/erc-sasl-20190215-login.patch b/app-emacs/erc-sasl/files/erc-sasl-20190215-login.patch
new file mode 100644
index 0000000..7678994
--- /dev/null
+++ b/app-emacs/erc-sasl/files/erc-sasl-20190215-login.patch
@@ -0,0 +1,32 @@
+Modified erc-login (with two lines added)
+https://gitlab.com/psachin/emacs.d/blob/dev/packages.org
+
+--- /dev/null
++++ b/erc-sasl-login.el
+@@ -0,0 +1,26 @@
++(require 'erc)
++(require 'erc-sasl)
++
++(defun erc-login ()
++  "Perform user authentication at the IRC server."
++  (erc-log (format "login: nick: %s, user: %s %s %s :%s"
++                   (erc-current-nick)
++                   (user-login-name)
++                   (or erc-system-name (system-name))
++                   erc-session-server
++                   erc-session-user-full-name))
++  (if erc-session-password
++      (erc-server-send (format "PASS %s" erc-session-password))
++    (message "Logging in without password"))
++  ;; begin erc-sasl
++  (when (and (featurep 'erc-sasl) (erc-sasl-use-sasl-p))
++    (erc-server-send "CAP REQ :sasl"))
++  ;; end erc-sasl
++  (erc-server-send (format "NICK %s" (erc-current-nick)))
++  (erc-server-send
++   (format "USER %s %s %s :%s"
++           ;; hacked - S.B.
++           (if erc-anonymous-login erc-email-userid (user-login-name))
++           "0" "*"
++           erc-session-user-full-name))
++  (erc-update-mode-line))

diff --git a/app-emacs/erc-sasl/metadata.xml b/app-emacs/erc-sasl/metadata.xml
new file mode 100644
index 0000000..c438baf
--- /dev/null
+++ b/app-emacs/erc-sasl/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer type="project">
+  <email>gnu-emacs@gentoo.org</email>
+  <name>Gentoo GNU Emacs project</name>
+</maintainer>
+</pkgmetadata>


                 reply	other threads:[~2021-07-28  9:37 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1627464980.7c9adf99a941f66592a7f927df2b6224e887963a.ulm@gentoo \
    --to=ulm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --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