From nobody Wed Mar 08 04:07:02 2023 X-Original-To: questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4PWf0L29y7z3x4t8 for ; Wed, 8 Mar 2023 04:07:14 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PWf0L1lsMz3DZf for ; Wed, 8 Mar 2023 04:07:14 +0000 (UTC) (envelope-from kevans@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1678248434; h=from:from: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; bh=J3ActvJBx2mn2VnSdUyI86Sudsbs4VJjhTfA5EsLf7c=; b=O8rk64jaetCBgZbHITGSvqcULdYx04m8Cbk9mUyPYqiRNVHefAJO+p0rmSzwptj6DDkTeC XvOP9w4ZKkjfUOpgzasHrt5gsZ4+lUazR95OO2/xh/UCb1DbiKe4MkmlhkKencdp7bJJvK 5jUR7rLEUxAMhtq2OIzgnaR/KyUdfE71CuLjPX/soCiR54y47gJQfe5mEu7b+IpCXbeGHj 8en9Wl4b3584hIkb5lHzIM02yZvKz0SpjViHfjImJlLYGFQgMUvLd3+SKtMeAEvdHneajn AsoJ2r36NAiUGovDEV+2VCyBY7GYCQIsPhWN+cIMRcTnXA3FLD7amqolMUHpDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1678248434; h=from:from: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; bh=J3ActvJBx2mn2VnSdUyI86Sudsbs4VJjhTfA5EsLf7c=; b=Fr5VaiyQrGs/1fnmMfiTl2Eav6Gp7oqDoxove3cDsF98VM8kCPu5CclSzzF8/AzEiPDIRh GRXrUSN07O1TodjEsk5bwzHsc7yGSxrI1Hl08ichruoFfMd5s403TetnmA3Xhg1TlzwXCg 2pRXqCjCTF01SSlygudQwz+EZhifGemJ16xqWA5ooKBid7u5kLs5czYFBGqEIYUm5F58hY wc9MtPocXnz++LdQcBHWjxBBSWXoLsljX4Iv3zUCZ11KUwD5HTJ2Lb6JmuNButsbukQ5ok bDXczS0XES5S3HHdf91lIrAufPXbfmPlkkx9hnQjFi/Ucnefa0b3TUq3Ak5GTg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1678248434; a=rsa-sha256; cv=none; b=jU7Sj2m96joeTGZ4At089sGkRrlAH2bqDfAXVvEVeY2xEcX6jfcPVM/1MmRxAe8vwNRzz2 S+LC/H3V/0X0k9EMrprRvkf/ojBVeSWRgl4VYALJJm+u3sxOQTrk6/RHIyqG+Zb39lImU6 /DuEVNbP/M7YgL0sQ//G+x6/AmCOpnRHKa9JSO6DZmgGl4X1mmCg4uDuhGhDi8PaQwo0Pw uUGM9Sj5hQxGozWcbc+nHrFXE/kBimMhAfkcaqhO74Hs3YNcDp9l5gsXMljRhnjqvxVrOg AUTum7V9Zbpis1zFrkNvDx+Q/4fhLLJBFAfwp3iyMAVnNJqKGJj+WP5rCLTPbA== Received: from mail-qt1-f175.google.com (mail-qt1-f175.google.com [209.85.160.175]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) (Authenticated sender: kevans) by smtp.freebsd.org (Postfix) with ESMTPSA id 4PWf0L0ZJGzsqY for ; Wed, 8 Mar 2023 04:07:14 +0000 (UTC) (envelope-from kevans@freebsd.org) Received: by mail-qt1-f175.google.com with SMTP id c3so16960687qtc.8 for ; Tue, 07 Mar 2023 20:07:14 -0800 (PST) X-Gm-Message-State: AO0yUKUBWLwr9edID2enIbb1+i6ozLFJYNHViOZe9WeWvozHU+07AwRO z9v8v+3cfkZv0dCTpzcXpd9nbd2RCpKZeDc2N0A= X-Google-Smtp-Source: AK7set8GiqBOF/1cVuWlhT51eoR+xf09AZRMKA1crNXey/GrJBrr/d8Xq64xfRss/V+kiMSMIhGIORQYRv9rKmwdPTU= X-Received: by 2002:aed:2785:0:b0:3bd:1a0b:8ac4 with SMTP id a5-20020aed2785000000b003bd1a0b8ac4mr4856732qtd.1.1678248433463; Tue, 07 Mar 2023 20:07:13 -0800 (PST) List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org MIME-Version: 1.0 References: <32d2e376-3f89-0588-316d-801d4cbf0b44@bluerosetech.com> <4DF870F0-89D5-45AA-B66C-93D2D1C0DD5E@nimnet.asn.au> In-Reply-To: From: Kyle Evans Date: Tue, 7 Mar 2023 22:07:02 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: How do I determine the ABI string used by pkg? To: Mel Pilgrim Cc: Ian Smith , Dan Langille , questions@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-ThisMailContainsUnwantedMimeParts: N On Tue, Mar 7, 2023 at 6:35=E2=80=AFPM Mel Pilgrim wrote: > > On 2023-03-05 9:36, Ian Smith wrote: > > On 6 March 2023 3:03:23 am AEDT, Dan Langille wrote: > > > Ian Smith wrote on 3/5/23 12:09 AM: > > > > On 2 March 2023 6:50:13 pm AEDT, Mel Pilgrim > > > wrote: > > > > > > > I need to determine the ABI string pkg uses on a given system= , > > > and > > > > > need to do so when there are no pkgs installed. > > > > > > > > # pkg -N -vv | grep ABI > > > > > Will that install pkg "when there are no pkgs installed", the key > > > requirement of the question? > > > > No; using 'pkg -N' when no packages are installed, /usr/sbin/pkg won't = attempt to bootstrap (i.e. install pkg*.pkg as /usr/local/sbin/pkg) but -vv= still prints, here: > > > > ABI =3D "FreeBSD:12:amd64"; > > ALTABI =3D "FreeBSD:12:x86:64"; > > > > cheers, Ian (ports@ removed from ccs) > > On a fresh jail with just base installed: > > # which pkg > /usr/sbin/pkg > # pkg config ABI > The package management tool is not yet installed on your system. > Do you want to fetch and install it now? [y/N]: > # pkg -N > pkg: pkg is not installed > # pkg -N -vv > pkg: pkg is not installed > > The functionality you, Dan, et al are quoting is only available after > bootstraping pkg. Yes, once it's bootstrapped getting the ABI string is > easy. > > Maybe "when there are no pkgs installed" wasn't clear? > Pluralizing it is what got me; I tend to think of 'pkgs' as short-hand for 'packages', a.k.a what you're installing with pkg, rather than pkg itself.