From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id SBCCLy55eWHZRQAAgWs5BA (envelope-from ) for ; Wed, 27 Oct 2021 18:07:10 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id UOlFKy55eWFMLwAA1q6Kng (envelope-from ) for ; Wed, 27 Oct 2021 16:07:10 +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 A3BB181E6 for ; Wed, 27 Oct 2021 18:07:09 +0200 (CEST) Received: from localhost ([::1]:47432 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mflSG-0003g7-Ny for larch@yhetil.org; Wed, 27 Oct 2021 12:07:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60044) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mfkjp-0004o9-0M for help-guix@gnu.org; Wed, 27 Oct 2021 11:21:13 -0400 Received: from knopi.disroot.org ([178.21.23.139]:45798) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mfkjd-0000H4-WB for help-guix@gnu.org; Wed, 27 Oct 2021 11:21:12 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 700EF6DE5E; Wed, 27 Oct 2021 17:20:58 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ABUSQB5X4dQc; Wed, 27 Oct 2021 17:20:56 +0200 (CEST) References: <87bl3hdn7n.fsf@disroot.org> <7C2393FD-7456-4314-B033-038EC51D126E@lepiller.eu> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1635348053; bh=H2JYaHgByIIXcSgDbXrisQSz7+28Ca2QYoAWxU7HA6Q=; h=References:Date:From:To:Cc:Subject:In-reply-to; b=F8a++EYW31oNwMZZtxdsRQ2KOv7XptUB2sq9wewDjrah6OIMdkBCYF+MkGsE6UdcI G79Xda9Q+wGZAjiDUaVCPfwSe7/stKCLPnywuNekZgZGugYMwbvc69XbacSF3mEh6f QFgT+U+Pj45KG+u9C243bJx26OGHylz2jqQoWVisCn3OxNHROC4osygfsdHlwUSwaR 0ZYRI4FOJb7N4qiJJo/D2ucxERbaL2hDssbeueum8fhiMBvTphwLhKp3fBVsggMzxX 76U7XJTJ81O55QYK3IdDZucNMp0KVGxEPq7thbgkGiBkIKyVykhi5eNxSW6jFzRj0B 0bf+xtn5wtMaQ== Date: Wed, 27 Oct 2021 10:19:27 -0400 From: Gary Johnson To: Julien Lepiller Cc: Ekaitz Zarraga , help-guix@gnu.org Subject: Re: Help with a GraalVM package? In-reply-to: <7C2393FD-7456-4314-B033-038EC51D126E@lepiller.eu> Message-ID: <87o87acx4w.fsf@disroot.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=178.21.23.139; envelope-from=lambdatronic@disroot.org; helo=knopi.disroot.org X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: "Help-Guix" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1635350829; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=4CJRKfo32ArzgwhFWjOS18/VW0IUyc96lioaZNGESt4=; b=S9GCiXAU2NTIcwVrjGy1iqxSB2n84XCv8T3atOlBitIcCEye4YPVYvHqCOuPTJLoNjLRtM DxxVgQaPwhKaz1JcluAs8Ikr78QjnQWGFtJzQN8PnjRaAhWQN9DVrXyLPALQ94UKaZypQX ArlPi5XyQei3taXM9SLq/2Y1rta22kTVdmxXlYHp3nESI5FcRLosgO01GCKoK6L9YQ3kCi XGEKJHZsUDYAd8ITTd4s3hbuWICvfz1naLQK5bxNLw5gGaRsMCd6fkWEqBitecISq/7f+8 7lPvHsVwcSAV5Q2mcu59kOImaU/Ul2W77FRNhzuA08laY/vxVITWH4Dtq8zJCg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1635350829; a=rsa-sha256; cv=none; b=QghV1wHOKPXVgedTtkmEFZVSDPAesGr+OV4F2C5XOLutXDZC7EsELikAwppBgJDYBe056i mfQyTLVTAp6xDXTxTsaZeJZtlHAjz59Va+5G8FpNV8Pon+fgbwdCr2TD1YjuI2fXz0xpZh sDXJ698qrfE0aJc0gNasvZ8d+Bt0/F8wQvHWTiqov6GyRXSeHlVTA+Yz9+JutNQly3TBvn d5vT9XSCY1/Yqaf0lckqdvvMKhONwvwClWiVIiHmJ2M8H3t4xoRpiW+V/CYIObaO7JThVF YkmRLpwUw1shK+mXEEPJWE3rLWpDh25kvDbe041QMcEyaKm5wgsf1RF+FiWQxg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=disroot.org header.s=mail header.b=F8a++EYW; spf=pass (aspmx1.migadu.com: domain of help-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=help-guix-bounces@gnu.org X-Migadu-Spam-Score: -0.13 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=disroot.org header.s=mail header.b=F8a++EYW; dmarc=pass (policy=quarantine) header.from=disroot.org; spf=pass (aspmx1.migadu.com: domain of help-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=help-guix-bounces@gnu.org X-Migadu-Queue-Id: A3BB181E6 X-Spam-Score: -0.13 X-Migadu-Scanner: scn0.migadu.com X-TUID: 2pUZ0Ko02Dnw Ekaitz said: >>I searched a little bit and I didn't find any guide on how to build >>GraalVM itself, if you can find me one I can try to guide you in >>making the package or at least we could evaluate how hard is it. Julien said: > This is what I found: > https://github.com/oracle/graal/blob/master/vm/README.md > > That info is not easy to find. Why hide it in a subdirectory?=E2=80=A6 Al= so, I > have no idea what this mx thing is. Thanks, Ekaitz and Julien. I did some further digging (why do they make this so hard?), and I finally found the `mx` command: https://github.com/graalvm/mx It looks like it's their custom build tool written in Python, so we would need a package for `mx` first to bootstrap the process. Once again for reference, here are the build instructions that Julien found: https://github.com/oracle/graal/blob/master/vm/README.md In this file, the author says the following: > In our CI, we build it using: >=20 > the latest JVMCI-enabled JDK8 (pre-built archives; build instructions). T= he JAVA_HOME environment variable must point to it. > gcc: 4.9.2 > make: 3.83 > binutils: 2.23.2 > cmake: 3.15.2 I think the closest input packages in the latest guix are probably: - gcc-toolchain@4.9.4 (which includes binutils@2.34 as a dependency) - binutils@2.34 (do we need to include this as an input if we already have = gcc-toolchain?) - make@4.2.1 - cmake@3.21.1 The build docs reference a JVMCI-enabled JDK8. Of course the repository pointed to by the "build instructions" link does not actually contain any build instructions. https://github.com/graalvm/openjdk8-jvmci-builder I dug a bit further into the issues list on that repository and found a rather involved exchange with various programmers voicing their frustrations with not being able to easily build a JVMCI-enabled JDK8 based on this repository's sources due to some proprietary components that the GraalVM developers seemed to have added without any warning. Eventually, it looked like at least one person on the issue thread managed to get it to build, but the latest shared instructions were from Dec 4th, 2020. https://github.com/graalvm/openjdk8-jvmci-builder/issues/11 However...I then backed up for a second to wonder what even is this JVMCI thing and why do we need to add it to JDK8? A quick web search turned up "JEP 243: Java-Level JVM Compiler Interface", which is a feature that looks like it was shipped in JDK9. https://openjdk.java.net/jeps/243 Okay, so why not just use a newer JDK, right? Heading back to that issues thread from earlier, I saw that one of the GraalVM developers did eventually share a link to building a version of JDK11 that should work as a base for building GraalVM. https://github.com/graalvm/labs-openjdk-11/blob/master/README.md So this got me wondering whether they have done something similar for newer versions of OpenJDK. Running a quick repository filtering search under the graalvm Github organization led me here: https://github.com/orgs/graalvm/repositories?q=3Dlabs It looks like they have worked on extending four OpenJDK versions to be usable as the base for building GraalVM: - labs-openjdk-11 - labs-openjdk-15 - labs-openjdk-16 - labs-openjdk-17 The Github commit graphs indicate that labs-openjdk-11 and labs-openjdk-17 have seen the most activity in the past few months. However, labs-openjdk-16 looked like it was getting some attention up through July 2021. Which one to try then? I remembered a warning about JDK17-based GraalVM distributions being "experimental with several known limitations", so maybe not that version. https://www.graalvm.org/docs/introduction/#available-distributions How about the OpenJDK16-based version then? Perhaps that's a reasonable path forward, and not too far off base since we already have an openjdk@16.0.1 package in Guix. Perhaps we could modify it for this purpose? Continuing with this line of thinking, perhaps we could also try using the newer versions of gcc-toolchain, binutils, make, and cmake as well? ... Whew! So that was a lot of information in one email. I think the path forward is first to make a package for the `mx` build tool, then to make a package for `labs-openjdk-16`, and finally(?) to make a package for `graalvm` that uses the previous two as inputs. 1. mx https://github.com/graalvm/mx 2. labs-openjdk-16 https://github.com/graalvm/labs-openjdk-16 3. graalvm https://github.com/oracle/graal/blob/master/vm/README.md I have built a number of rather simple Guix package definitions for my machine, but the scope of this one is a bit beyond my current capabilities IMHO. Any and all help from you packaging wizards would be much appreciated! Cheers, Gary --=20 GPG Key ID: 7BC158ED Use `gpg --search-keys lambdatronic' to find me Protect yourself from surveillance: https://emailselfdefense.fsf.org =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D () ascii ribbon campaign - against html e-mail /\ www.asciiribbon.org - against proprietary attachments Why is HTML email a security nightmare? See https://useplaintext.email/ Please avoid sending me MS-Office attachments. See http://www.gnu.org/philosophy/no-word-attachments.html