From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on atuin.qyliss.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.6 Received: from atuin.qyliss.net (localhost [IPv6:::1]) by atuin.qyliss.net (Postfix) with ESMTP id 695A1616F4; Tue, 20 Sep 2022 12:17:52 +0000 (UTC) Received: by atuin.qyliss.net (Postfix, from userid 496) id 41757616E8; Tue, 20 Sep 2022 12:17:49 +0000 (UTC) Received: from mail-lj1-x233.google.com (mail-lj1-x233.google.com [IPv6:2a00:1450:4864:20::233]) by atuin.qyliss.net (Postfix) with ESMTPS id 872F9616E7 for ; Tue, 20 Sep 2022 12:17:45 +0000 (UTC) Received: by mail-lj1-x233.google.com with SMTP id l12so2731966ljg.9 for ; Tue, 20 Sep 2022 05:17:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=unikie.com; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date; bh=qAf3wbS54hWbB1IZuDrMtnYiUGWZeuAZYmf8IbRESrQ=; b=MxRQ9Ed0CU2pzvxgnTDnaR+KzkF7/PgRhAUQ5PIW3+oH4xw4v2No/uBU9fzTRn0ewV at6Jk3ztcdDEPOvrKdggcjX1Z4ajYM0GzbMfG5RDZ62omwrbvRDRFNgdsg/Mema+DMgD yf/sdGgpBPvvIW4M0KcV01bsv3etf2/f+PBkFQcFG3UF/nvR5p92JMVXqVFBqSF2KSKc e8auzJxCSFIz5zUzJBP2EvMDDc7z9sz5tXj+3t1AuclKuuIvg1G0zSv3J4/m8H3yFn1m 8iGPINzLOehOq5YtygKvMhC53S9RW0+ZulmyeHOI1LDM5cIx8/PC3fMg2WqQ9JXqcToL TavQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date; bh=qAf3wbS54hWbB1IZuDrMtnYiUGWZeuAZYmf8IbRESrQ=; b=myp7M+rIV2oFhE1XvmZ/bPta0/24H2zpkOap9x0vAUE57SwO3gU0vC//m7O1DKgfa0 +By/KXcErRS3yXY51hR1kcIJIulALORndYrSFECqf2/VlTmEEu79ngYAQfBwmm9IwgCR nOdqGC7NLn4dO0sR9UjHRTPqbthyc8U6LJkfP0b2VaMJPbnkChFuxRBD+DcfqLhmXoQQ VkJGv1gqZxH7v8XaRd5XcsjUlOC6c7RMBKyXbdZtPz+gmjOq/zMp7GMSLko/0C0fISoc 7EmhKBuPUzYUgGM9wbtCRmFiPBGwEycCFvCdqtrz9gD/DyUWND/DEhTWKaIJ1iiUPJ3b sg2g== X-Gm-Message-State: ACrzQf1vtCN8S5u6vZpX86AaVmTB9fD4x1l1YEuSh1CQyn+cLrCI+CjV oPAlyQwGzGi5Sgct7rhChrUSoQ== X-Google-Smtp-Source: AMsMyM411cuL+bMkUfNOBuQAljY4BI6yr2DXX6nxAD47HM3wTR4fk0NWdS///dfEFSDKkc02gjmJOg== X-Received: by 2002:a2e:9cf:0:b0:26c:3973:ec1f with SMTP id 198-20020a2e09cf000000b0026c3973ec1fmr6840237ljj.322.1663676264667; Tue, 20 Sep 2022 05:17:44 -0700 (PDT) Received: from [192.168.1.26] (mobile-access-567351-194.dhcp.inet.fi. [86.115.81.194]) by smtp.gmail.com with ESMTPSA id g20-20020a2ea4b4000000b00261eb899361sm245666ljm.23.2022.09.20.05.17.44 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 20 Sep 2022 05:17:44 -0700 (PDT) Message-ID: Date: Tue, 20 Sep 2022 15:17:43 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.0 Subject: Re: [PATCH] fix: config support with vms Content-Language: en-US To: Alyssa Ross References: <20220920110958.2548848-1-ville.ilvonen@unikie.com> <87fsgmmgdf.fsf@alyssa.is> <1263b0d5-14f7-9650-7823-70da02f42c5d@unikie.com> <87bkramfvn.fsf@alyssa.is> <509b7100-998a-a7e9-a8a4-61312af67767@unikie.com> <878rmemf28.fsf@alyssa.is> From: Ville Ilvonen In-Reply-To: <878rmemf28.fsf@alyssa.is> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Message-ID-Hash: JBVGEV66TCE3KBGMMVSWVC4YSGWOLBZK X-Message-ID-Hash: JBVGEV66TCE3KBGMMVSWVC4YSGWOLBZK X-MailFrom: ville.ilvonen@unikie.com X-Mailman-Rule-Hits: header-match-devel.spectrum-os.org-0 X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1 CC: devel@spectrum-os.org X-Mailman-Version: 3.3.5 Precedence: list List-Id: Patches and low-level development discussion Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On 9/20/22 14:59, Alyssa Ross wrote: > Ville Ilvonen writes: > >> On 9/20/22 14:42, Alyssa Ross wrote: >>> Ville Ilvonen writes: >>> >>>> On 9/20/22 14:31, Alyssa Ross wrote: >>>>> Ville Ilvonen writes: >>>>> >>>>>> with config.nix, the build of vms fails with >>>>>> error: undefined variable 'pkgs' >>>>>> .. >>>>>> 49| >>>>>> 50| kernel = pkgs.linux_latest.override { >>>>>> | ^ >>>>>> >>>>>> This fixes the issue for all default vms >>>>>> >>>>>> Signed-off-by: Ville Ilvonen >>>>>> --- >>>>> >>>>> Hi Ville, I was wondering how I'd have missed something like the default >>>>> VMs not evaluating, but indeed I'm not able to reproduce this. And when >>>>> I look at the default.nix files for the default VMs, I see: >>>>> >>>>> 50 kernel = buildPackages.linux.override { >>>>> >>>>> So unless I've missed something, I don't think this issue exists in the >>>>> current upstream. (I checked commit 3aa2f8a.) >>>> >>>> I'm not testing with default but with new config.nix support. >>>> Have you tested with any config.nix? >>> >>> I'm not sure I understand what you mean. config.nix support is already >>> present in the commit I tested. >>> >>> I created a simple config.nix file that just set "pkgs" to "import {}" >>> in case the presence of the config file made a difference, and ran: >>> >>> nix-instantiate vm/*/* img/live >> >> Interesting. I created a simple config.nix in the root of Spectrum >> source tree - https://spectrum-os.org/doc/build-configuration.html >> It only overrides the kernel - to imx8 - and sets crossSystem for >> aarch64. Build of vms fails without this patch. > > Are you testing with an upstream Spectrum commit, or with one from the Testing with an upstream Spectrum commit - using a branch rebased with spectrum/main and from which I dropped the cross-compilation configuration hacks and moved them to config.nix. It has got 3aa2f8a (which is a copyright update). > TII branch with cross compilation support? It's likely that making > cross compilation work would have required changing line 50 you posted > above, because as I explained I don't think it's correct. So if you're > using that branch, that could explain why you're seeing this and I'm > not.