From patchwork Mon Jul 12 17:50:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Efraim Flashner X-Patchwork-Id: 31363 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id A8EB427BC83; Mon, 12 Jul 2021 18:53:53 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 3391B27BC81 for ; Mon, 12 Jul 2021 18:53:53 +0100 (BST) Received: from localhost ([::1]:43820 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m307s-0006ip-8U for patchwork@mira.cbaines.net; Mon, 12 Jul 2021 13:53:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56894) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m3074-0004iU-7G for guix-patches@gnu.org; Mon, 12 Jul 2021 13:53:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:55521) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m3073-0006EI-Sg for guix-patches@gnu.org; Mon, 12 Jul 2021 13:53:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m3073-0005qe-SL for guix-patches@gnu.org; Mon, 12 Jul 2021 13:53:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49538] [CORE-UPDATES][PATCH] gnu: openssl-1.0: Build with openssl sources. Resent-From: Efraim Flashner Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 12 Jul 2021 17:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 49538 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 49538@debbugs.gnu.org Cc: Efraim Flashner X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.162611234922438 (code B ref -1); Mon, 12 Jul 2021 17:53:01 +0000 Received: (at submit) by debbugs.gnu.org; 12 Jul 2021 17:52:29 +0000 Received: from localhost ([127.0.0.1]:38834 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m306X-0005pq-6g for submit@debbugs.gnu.org; Mon, 12 Jul 2021 13:52:29 -0400 Received: from lists.gnu.org ([209.51.188.17]:55388) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m306V-0005pi-RS for submit@debbugs.gnu.org; Mon, 12 Jul 2021 13:52:28 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56818) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m306V-000399-Hi for guix-patches@gnu.org; Mon, 12 Jul 2021 13:52:27 -0400 Received: from flashner.co.il ([178.62.234.194]:48210) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m306T-0005Vu-Gb for guix-patches@gnu.org; Mon, 12 Jul 2021 13:52:27 -0400 Received: from localhost (unknown [31.210.177.125]) by flashner.co.il (Postfix) with ESMTPSA id 68CF8400F4; Mon, 12 Jul 2021 17:51:52 +0000 (UTC) From: Efraim Flashner Date: Mon, 12 Jul 2021 20:50:22 +0300 Message-Id: <9d380d39f78149a6a6d78c484fab6ce6cb1059ba.1626112108.git.efraim@flashner.co.il> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Received-SPF: pass client-ip=178.62.234.194; envelope-from=efraim@flashner.co.il; helo=flashner.co.il X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/tls.scm (openssl-1.0): Replace package with openssl built with openssl-1.0 API. --- I was poking around with openssl on master and I realized that openssl-1.1 can be built targeting the API for 1.1, 1.0 or 0.9.8. I test built dillo with openssl-1.1 with the API for 1.0 and it was working for me. I figure this isn't a bad way to make things a bit better while we try to get rid of openssl-1.0. --- gnu/packages/tls.scm | 92 ++------------------------------------------ 1 file changed, 3 insertions(+), 89 deletions(-) base-commit: 12c2648f4e8e050d9374ca70efd1856dc8238979 diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm index 297e16dd70..ed22518e02 100644 --- a/gnu/packages/tls.scm +++ b/gnu/packages/tls.scm @@ -447,97 +447,11 @@ required structures.") (home-page "https://www.openssl.org/"))) (define-public openssl-1.0 - (package - (inherit openssl) + (package/inherit openssl (name "openssl") - (version "1.0.2u") - (source (origin - (method url-fetch) - (uri (list (string-append "https://www.openssl.org/source/openssl-" - version ".tar.gz") - (string-append "ftp://ftp.openssl.org/source/" - "openssl-" version ".tar.gz") - (string-append "ftp://ftp.openssl.org/source/old/" - (string-trim-right version char-set:letter) - "/openssl-" version ".tar.gz"))) - (sha256 - (base32 - "05lxcs4hzyfqd5jn0d9p0fvqna62v2s4pc9qgmq0dpcknkzwdl7c")) - (patches (search-patches "openssl-runpath.patch" - "openssl-c-rehash-in.patch")))) - (outputs '("out" - "doc" ;1.5MiB of man3 pages - "static")) ;6MiB of .a files (arguments - (substitute-keyword-arguments (package-arguments openssl) - ;; Parallel build is not supported in 1.0.x. - ((#:parallel-build? _ #f) #f) - ((#:phases phases) - `(modify-phases ,phases - (add-before 'patch-source-shebangs 'patch-tests - (lambda* (#:key inputs native-inputs #:allow-other-keys) - (let ((bash (assoc-ref (or native-inputs inputs) "bash"))) - (substitute* (find-files "test" ".*") - (("/bin/sh") - (string-append bash "/bin/sh")) - (("/bin/rm") - "rm")) - #t))) - (add-before 'configure 'patch-Makefile.org - (lambda* (#:key outputs #:allow-other-keys) - ;; The default MANDIR is some unusual place. Fix that. - (let ((out (assoc-ref outputs "out"))) - (patch-makefile-SHELL "Makefile.org") - (substitute* "Makefile.org" - (("^MANDIR[[:blank:]]*=.*$") - (string-append "MANDIR = " out "/share/man\n"))) - #t))) - (replace 'configure - ;; Override this phase because OpenSSL 1.0 does not understand -rpath. - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (invoke ,@(if (%current-target-system) - '("./Configure") - '("./config")) - "shared" ;build shared libraries - "--libdir=lib" - - ;; The default for this catch-all directory is - ;; PREFIX/ssl. Change that to something more - ;; conventional. - (string-append "--openssldir=" out - "/share/openssl-" ,version) - - (string-append "--prefix=" out) - ,@(if (%current-target-system) - '((getenv "CONFIGURE_TARGET_ARCH")) - '()))))) - (delete 'move-extra-documentation) - (add-after 'install 'move-man3-pages - (lambda* (#:key outputs #:allow-other-keys) - ;; Move section 3 man pages to "doc". - (let* ((out (assoc-ref outputs "out")) - (man3 (string-append out "/share/man/man3")) - (doc (assoc-ref outputs "doc")) - (target (string-append doc "/share/man/man3"))) - (mkdir-p target) - (for-each (lambda (file) - (rename-file file - (string-append target "/" - (basename file)))) - (find-files man3)) - (delete-file-recursively man3) - #t))) - ;; XXX: Duplicate this phase to make sure 'version' evaluates - ;; in the current scope and not the inherited one. - (replace 'remove-miscellany - (lambda* (#:key outputs #:allow-other-keys) - ;; The 'misc' directory contains random undocumented shell and Perl - ;; scripts. Remove them to avoid retaining a reference on Perl. - (let ((out (assoc-ref outputs "out"))) - (delete-file-recursively (string-append out "/share/openssl-" - ,version "/misc")) - #t))))))))) + `(#:configure-flags (list "--api=1.0.0") + ,@((package-arguments openssl)))))) (define-public libressl (package