From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id iHgJFGH8iV+BbwAA0tVLHw (envelope-from ) for ; Fri, 16 Oct 2020 20:02:41 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id AObND2H8iV9IDwAAbx9fmQ (envelope-from ) for ; Fri, 16 Oct 2020 20:02:41 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 3552D9406A2 for ; Fri, 16 Oct 2020 20:02:40 +0000 (UTC) Received: from localhost ([::1]:50940 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kTVvz-0007EM-6O for larch@yhetil.org; Fri, 16 Oct 2020 16:02:39 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45580) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kTVvQ-0007Dg-DZ for guix-patches@gnu.org; Fri, 16 Oct 2020 16:02:09 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:49421) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kTVvO-0004sX-2B for guix-patches@gnu.org; Fri, 16 Oct 2020 16:02:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kTVvN-0005QP-VA for guix-patches@gnu.org; Fri, 16 Oct 2020 16:02:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#44040] [PATCH 1/2] gnu: Add ocaml-hivex. Resent-From: Morgan.J.Smith@outlook.com Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 16 Oct 2020 20:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44040 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: 44040@debbugs.gnu.org Cc: Morgan Smith Received: via spool by 44040-submit@debbugs.gnu.org id=B44040.160287849720800 (code B ref 44040); Fri, 16 Oct 2020 20:02:01 +0000 Received: (at 44040) by debbugs.gnu.org; 16 Oct 2020 20:01:37 +0000 Received: from localhost ([127.0.0.1]:60963 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kTVuv-0005PJ-0e for submit@debbugs.gnu.org; Fri, 16 Oct 2020 16:01:37 -0400 Received: from mail-dm6nam11olkn2074.outbound.protection.outlook.com ([40.92.19.74]:15296 helo=NAM11-DM6-obe.outbound.protection.outlook.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kTVuq-0005P0-LY for 44040@debbugs.gnu.org; Fri, 16 Oct 2020 16:01:32 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=aUNaMI/AbbuBjT9an4bHg3+XCHC/VUPu5acGMQoxkVHdmDBD0aPZ1s4Lk93gtALO9COuMGT6DRrKizplbfVfHCqXrOwSFJiuzEqBiAKjpIHeAaJWiuzG7hrKw6LI0uW7gdcr1kL3QjxWUmLRryynvKy+98b+fOL+S81cF5u4ujevN1AsIKLNPH2oCIabUO+WqlvvRRCwVgIbbCcKRq34BIRhVYsnXV5yvTaO2p19QrnpbwPGQ/KG/IR7B+ut0tY3wMlVtjlUg08kjT6SLRK6U/t0Is0M8RXjitwPqNjGorxOy5FbmKyM+ZFbZ5xKXYk5SMdJxaL2JtLiiZrDkoF8lA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=W6c93nD+Oo4BjVSkYXwTNGtLsqvqtEEM8029jbHQzbI=; b=LDE9bE9Z2/bqR/9OPfh48cifrd67ZafmkKxpR5Jx54Ov/pXtaNyDjYiXK9xRlkssVFpCEQ8gqN1C2AOhdVeMLLC5uRYqgbhxm2dhSnvi7RkD5qMEkt5BZpGmk9S+bWl1ZmvoIJUmDBxaL0lO8C0njO2D8lFob7qNjpuvuNd05K5atUI4Lh9bNIiGOieEZ4nu8hbD1JhqTx0rRVCrQWwydm+tU1xNuaecUakhd3jxhjgrh54d+YdYNkDFvd/C7Uvzq4YSDYCTWMV3AoN/RVAV6n/cyh/7AVDnOedgQzkRCXIOMUafhuu6ZfTaimUE4i8VkKm8DBDrmlKT7kNLs+I0Yw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=W6c93nD+Oo4BjVSkYXwTNGtLsqvqtEEM8029jbHQzbI=; b=tcECHTjMzUT5TXmnEaMSxpgCs+sSHcyrlR53O5cZ72XUkcxhnDHKNqQjhCfq60mM0uRAJDeqsNIXRpayULQ4cDyDmhUFFDlXz+MWmgAVMsvpqMA7OeyvPcsyM5Sm54+sl92OWZf8v/hZc15z4JBwMtZd6CAy3X0co1h+iVeV8Fmxb8+JdiEVt5xSHiksWUQlTuNJFm7M4bruaiRBYSRMJim5LfeqLnsY3awsduR1Hvti76fwshyvYj9orOOvyBMOHF29pUmLYfqowR7SdnOtagGWQbK0EBPyt5aY2HlKqLnGem6L/hvDZyMDp71Jw8CQmgkWmgyjIsn/Xp/xZ2On/w== Received: from BN8NAM11FT055.eop-nam11.prod.protection.outlook.com (2a01:111:e400:fc4b::43) by BN8NAM11HT044.eop-nam11.prod.protection.outlook.com (2a01:111:e400:fc4b::127) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21; Fri, 16 Oct 2020 20:01:22 +0000 Received: from DM5PR1001MB2105.namprd10.prod.outlook.com (2a01:111:e400:fc4b::41) by BN8NAM11FT055.mail.protection.outlook.com (2a01:111:e400:fc4b::318) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 20:01:22 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:B2C2D82331AF5474907E5B61C4B27EDD2E6EC77CB84D2DD943AAFECFFD0CB99D; UpperCasedChecksum:15AC4DE169ADB880116ACC79506C890B158CB4C55B80927665F45A0AB56046D9; SizeAsReceived:8611; Count:47 Received: from DM5PR1001MB2105.namprd10.prod.outlook.com ([fe80::2405:9d83:9d59:c5cf]) by DM5PR1001MB2105.namprd10.prod.outlook.com ([fe80::2405:9d83:9d59:c5cf%5]) with mapi id 15.20.3477.025; Fri, 16 Oct 2020 20:01:22 +0000 From: Morgan.J.Smith@outlook.com Date: Fri, 16 Oct 2020 16:00:51 -0400 Message-ID: X-Mailer: git-send-email 2.28.0 In-Reply-To: References: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-TMN: [Um+hMREhIrvrjnCyv8WQd2x2VKSZJGm1] X-ClientProxiedBy: YT1PR01CA0113.CANPRD01.PROD.OUTLOOK.COM (2603:10b6:b01:2c::22) To DM5PR1001MB2105.namprd10.prod.outlook.com (2603:10b6:4:2b::24) X-Microsoft-Original-Message-ID: <20201016200051.6985-1-Morgan.J.Smith@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from pancake.lan (184.164.21.96) by YT1PR01CA0113.CANPRD01.PROD.OUTLOOK.COM (2603:10b6:b01:2c::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.20 via Frontend Transport; Fri, 16 Oct 2020 20:01:21 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: 1352c1d1-3224-4868-8eca-08d8720e40f3 X-MS-Exchange-SLBlob-MailProps: 0RSV28T7LqT9n3kMDvFKhsxiQvoTt9GHNNqNxwX7KGOUw0nggx4mrZ7xBWKERiW3tJQ1sVm0kuw2cnUrnWNZJIR0a7NTbwwKkJXuDp6F66hqsGmMp4n0P/iGEQCTitwXDeyYgiFSkWG3jlpvlLE4nfLlxaitkQSb6J9/OutEEltw7jdo/9UeX+ITSotB8/UoTy1cmlSWVC0Oh1c4R3Tx52+brUiyIKmvaeq1GAOHps+f8JvRmBBuhgIAb8PW/y67YHLpwkrdzp6BjwijsPqNjEXHeeMxnnSOyf9KLvY4zZ1sx1FrwWUx6dboIF8YM5W+/leCdEMNRof2nKrlji/NaBqCD5oXAfZjujzZ2dnCoUTs7vEOWghohscGrPEOV5XbyM1uWAktDqVmkBLz1qWS36t8DXNrTuxPHacIVi1HNqc5UHTv2zrhrwTJ2yEsGrvWdw1a+YjS6WHQ1olN+DJXnHgFy9ZGn4kyG0TJKLdQXhFuB1lqOV1CGfiYoffYSrmwYKPtzSjqCApGUEe7l8pi/Fp03MVKd/i1ZNwiD88Hq7ZEDlAMeo3p7X2y05p4UpJwVwjiUPEpx8TbUK2XDOWkhSjvbGGqroHxN7DjgZhgRr52FpX6bND6N29L4yRvGd2UhtnX58hC5nQoF4kb3IIILbXEXCsdhqjb7GbX98LPem56KQY36KnRhNUeslPx8vt7 X-MS-TrafficTypeDiagnostic: BN8NAM11HT044: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: iFkjCcNLui7MeYfeI/Ye0MeHZD86f7hfaIr/KD2hRPcZiQqWw7RWggEZ6ILtsR0IMBur6F+RIJpk2oljLtANIg4Ta0qdBcZYJtQ/70N+Ttr4PiN4B6VVB/ol5WfOLps7Ng79lAdxKARZg5vD3BKeAtQPtWJy/V2dsmDhVTtJbGa6B3Uk3/5NYzQG6O50bnYYo/S8QwG/CkWRkGZiQWt1TMtrG5KK9IUNJG7CRwvz98DJO6xTmQH5hhqpLnAlqaa5 X-MS-Exchange-AntiSpam-MessageData: ZvXxnd0vEHLDEqB6BBnLRSg152L74DQleda6TLr/VQ0YHvp31Jpdx82ntpuwPl5O8oi6tpRvssgu5L1SbFjAiCOZ3TJAWL+UbY9Nk0tVDCyk3WfzPpd0tvqWYKl0Jwwfi/bC1A5Y1KvOYefPxcCIuQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1352c1d1-3224-4868-8eca-08d8720e40f3 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 20:01:22.1325 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT055.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN8NAM11HT044 X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=outlook.com header.s=selector1 header.b=tcECHTjM; dmarc=fail reason="SPF not aligned (relaxed)" header.from=outlook.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: 2.09 X-TUID: eL/Cg4y7e8md From: Morgan Smith * gnu/packages/ocaml.scm (ocaml-hivex): New variable. --- gnu/packages/ocaml.scm | 104 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 104 insertions(+) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 4cc530509a..88c7f3c1d3 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -15,6 +15,7 @@ ;;; Copyright © 2019 Ricardo Wurmus ;;; Copyright © 2020 Brett Gilio ;;; Copyright © 2020 Marius Bakke +;;; Copyright © 2020 Morgan Smith ;;; ;;; This file is part of GNU Guix. ;;; @@ -47,6 +48,8 @@ #:use-module (gnu packages ghostscript) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) + #:use-module (gnu packages gperf) + #:use-module (gnu packages gettext) #:use-module (gnu packages gtk) #:use-module (gnu packages libevent) #:use-module (gnu packages libffi) @@ -68,6 +71,7 @@ #:use-module (gnu packages texinfo) #:use-module (gnu packages time) #:use-module (gnu packages tls) + #:use-module (gnu packages version-control) #:use-module (gnu packages virtualization) #:use-module (gnu packages web-browsers) #:use-module (gnu packages xml) @@ -2831,6 +2835,106 @@ writing to these structures, and they are accessed via the Bigarray module.") (description "Hex is a minimal library providing hexadecimal converters.") (license license:isc))) +(define-public ocaml-hivex + (package + (name "ocaml-hivex") + ;; Make sure to update the gnulib input to the commit upstream uses when + ;; updating this package + (version "1.3.19") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/libguestfs/hivex") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1gw59ac6z4fbg0flajnsh6d25h75pnk4605d5rw9rv0bvhfvway5")))) + (build-system ocaml-build-system) + (arguments + `(;; XXX: I'm not sure why runpath validation doesn't work + #:validate-runpath? #f + #:configure-flags + (list (string-append "CONFIG_SHELL=" + (assoc-ref %build-inputs "bash") "/bin/bash") + (string-append "SHELL=" + (assoc-ref %build-inputs "bash") "/bin/bash")) + #:test-target "check" + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'unpack-gnulib + (lambda* (#:key inputs #:allow-other-keys) + (let ((gnulib (assoc-ref inputs "gnulib"))) + ;; Upstream gnulib is cloned into this directory as a submodule + (copy-recursively gnulib ".gnulib") + #t))) + ;; Autogen calls bootstrap and then generates a configure script + (add-before 'configure 'autogen + (lambda _ + (chmod "configure.ac" #o644) + (invoke "./autogen.sh") + #t)) + (add-before 'autogen 'fix-bootstrap + (lambda _ + ;; Stop bootstrap from cloning gnulib + (substitute* "bootstrap" + (("^git.*$") "")) + #t)) + (add-before 'autogen 'fix-autogen.sh + (lambda _ + (substitute* "autogen.sh" + ;; Forces bootstrap to run + (("git submodule status") "echo false") + ;; Don't run configure yet + (("^.*configure.*$") "echo\n")) + #t)) + (add-after 'autogen 'patch-configure-and-build-aux + (lambda* (#:key native-inputs inputs outputs #:allow-other-keys) + (patch-shebang "configure") + ;; Hard code paths to ld and file in the configure script + (substitute* "configure" + (("/usr/bin/ld") + (string-append (assoc-ref inputs "ld-wrapper") "/bin/ld")) + (("/usr/bin/file") + (string-append (assoc-ref inputs "file") "/bin/file"))) + #t)) + (add-before 'install 'patch-ocaml-installdir + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + ;; Force ocaml installdir to be correct + (substitute* "ocaml/Makefile" + (("\\$\\(DESTDIR\\)\\$\\(OCAMLLIB\\)") + (string-append + out "/lib/ocaml/site-lib")))) + #t))))) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake) + ("gperg" ,gperf) + ("libtool" ,libtool) + ("pkg-config" ,pkg-config) + ("gnulib" + ;; This is the commit upstream uses + ,(let ((commit "5e50baa16ef90204d9048a9e2f23c5a538955121")) + (origin + (method git-fetch) + (uri (git-reference + (url "git://git.savannah.gnu.org/gnulib.git") + (commit commit))) + (sha256 + (base32 "0clx0gq6mmm4dkzp5pqh02cbzggnc3ba491qb79brpxcrjri1pnd")) + (file-name (git-file-name "gnulib" commit))))))) + (inputs + `(("perl" ,perl) + ("sed" ,sed) + ("gettext" ,gettext-minimal))) + (home-page "https://github.com/libguestfs/hivex") + (synopsis "Library for reading and writing Windows Registry \"hive\" +binary files") + (description "This library reads Windows NT registry files (ie. not +Windows 3.1 or Windows 95/98/ME).") + (license license:lgpl2.1))) + (define-public ocaml4.07-ezjsonm (package (name "ocaml4.07-ezjsonm") -- 2.28.0