From: zerodaysfordays@sdf.lonestar.org (Jakob L. Kreuze)
To: 36638@debbugs.gnu.org
Subject: [bug#36638] [PATCH v2 2/2] gnu: Add i2pd.
Date: Wed, 17 Jul 2019 14:12:23 -0400 [thread overview]
Message-ID: <87pnm8pm2g.fsf_-_@sdf.lonestar.org> (raw)
In-Reply-To: <87tvbkpm4b.fsf_-_@sdf.lonestar.org> (Jakob L. Kreuze's message of "Wed, 17 Jul 2019 14:11:16 -0400")
[-- Attachment #1: Type: text/plain, Size: 6137 bytes --]
* gnu/packages/i2p.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
---
gnu/local.mk | 1 +
gnu/packages/i2p.scm | 107 +++++++++++++++++++++++++++++++++++++++++++
2 files changed, 108 insertions(+)
create mode 100644 gnu/packages/i2p.scm
diff --git a/gnu/local.mk b/gnu/local.mk
index e6fca384a0..20f77c89f0 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -243,6 +243,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/hugs.scm \
%D%/packages/hurd.scm \
%D%/packages/hyperledger.scm \
+ %D%/packages/i2p.scm \
%D%/packages/ibus.scm \
%D%/packages/icu4c.scm \
%D%/packages/idris.scm \
diff --git a/gnu/packages/i2p.scm b/gnu/packages/i2p.scm
new file mode 100644
index 0000000000..0f6aa2133a
--- /dev/null
+++ b/gnu/packages/i2p.scm
@@ -0,0 +1,107 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2019 Jakob L. Kreuze <zerodaysfordays@sdf.lonestar.org>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages i2p)
+ #:use-module (gnu packages boost)
+ #:use-module (gnu packages compression)
+ #:use-module (gnu packages tls)
+ #:use-module (gnu packages upnp)
+ #:use-module (gnu packages web)
+ #:use-module (guix packages)
+ #:use-module (guix git-download)
+ #:use-module (guix build-system cmake)
+ #:use-module ((guix licenses) #:prefix license:))
+
+(define-public i2pd
+ (package
+ (name "i2pd")
+ (version "2.27.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/PurpleI2P/i2pd.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "00y0y57z84gakwa88zzm0g3ixgc6y7zm35rjiysiajzvmdq5w1wf"))))
+ (build-system cmake-build-system)
+ (inputs `(("boost" ,boost)
+ ("miniupnpc" ,miniupnpc)
+ ("openssl" ,openssl)
+ ("websocketpp" ,websocketpp)
+ ("zlib" ,zlib)))
+ (arguments '(#:configure-flags
+ (let ((source (assoc-ref %build-inputs "source")))
+ (list (string-append "-S" source "/build")
+ "-DWITH_PCH=OFF"
+ "-DWITH_STATIC=OFF"
+ "-DWITH_UPNP=ON"
+ "-DWITH_WEBSOCKETS=ON"
+ "-DWITH_LIBRARY=ON"
+ "-DBUILD_SHARED_LIBS=ON"
+ "-DWITH_BINARY=ON"))
+ #:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key
+ (make-flags '())
+ (parallel-tests? #t)
+ #:allow-other-keys)
+ (let ((oldpwd (getcwd))
+ (source (assoc-ref %build-inputs "source")))
+ (copy-recursively (string-append source "/tests")
+ "./tests")
+ (chdir "./tests")
+ (substitute* "Makefile"
+ (("../libi2pd/") (string-append source "/libi2pd/")))
+ (apply invoke "make" "all"
+ `(,@(if parallel-tests?
+ `("-j" ,(number->string
+ (parallel-job-count)))
+ '())
+ ,@make-flags))
+ (chdir oldpwd))))
+ (add-after 'install 'install-headers
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((install-dir (assoc-ref outputs "out"))
+ (src-dir (string-append install-dir "/src"))
+ (include-dir
+ (string-append install-dir "/include")))
+ (mkdir-p include-dir)
+ ;; This is the only header file that's relevant to the
+ ;; public interface.
+ ;; <https://github.com/PurpleI2P/i2pd/issues/1378>
+ (install-file (string-append src-dir "/api.h")
+ include-dir)
+ #t)))
+ (add-after 'install-headers 'remove-source
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((install-dir (assoc-ref outputs "out"))
+ (src-dir (string-append install-dir "/src")))
+ (delete-file-recursively src-dir)
+ (delete-file (string-append install-dir
+ "/LICENSE"))
+ #t))))))
+ (home-page "https://i2pd.website/")
+ (synopsis "Router for an end-to-end encrypted and anonymous internet")
+ (description "i2pd is a client for the anonymous I2P network, upon which
+applications for file sharing, web browsing, instant messaging, and more are
+built. i2pd allows people from all around the world to communicate and share
+information securely without restrictions.")
+ (license license:bsd-3)))
--
2.22.0
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
next prev parent reply other threads:[~2019-07-17 18:13 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-13 17:52 [bug#36638] [PATCH 0/2] gnu: Add i2pd Jakob L. Kreuze
2019-07-13 17:53 ` [bug#36638] [PATCH 1/2] gnu: Add websocketpp Jakob L. Kreuze
2019-07-13 17:54 ` [bug#36638] [PATCH 2/2] gnu: Add i2pd Jakob L. Kreuze
2019-07-15 16:29 ` Ludovic Courtès
2019-07-15 16:21 ` [bug#36638] [PATCH 1/2] gnu: Add websocketpp Ludovic Courtès
2019-07-15 16:31 ` Ludovic Courtès
2019-07-16 16:48 ` Jakob L. Kreuze
2019-07-17 18:10 ` [bug#36638] [PATCH v2 0/2] gnu: Add i2pd Jakob L. Kreuze
2019-07-17 18:11 ` [bug#36638] [PATCH v2 1/2] gnu: Add websocketpp Jakob L. Kreuze
2019-07-17 18:12 ` Jakob L. Kreuze [this message]
2019-07-18 9:27 ` [bug#36638] [PATCH v2 2/2] gnu: Add i2pd Ludovic Courtès
2019-07-18 9:18 ` [bug#36638] [PATCH v2 1/2] gnu: Add websocketpp Ludovic Courtès
2019-07-18 9:20 ` Ludovic Courtès
2019-07-18 9:29 ` [bug#36638] [PATCH v2 0/2] gnu: Add i2pd Ludovic Courtès
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
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87pnm8pm2g.fsf_-_@sdf.lonestar.org \
--to=zerodaysfordays@sdf.lonestar.org \
--cc=36638@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 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).