From nobody Wed Oct 08 05:55:29 2025 X-Original-To: freebsd-current@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 4chMhD5R0tz6BMP2 for ; Wed, 08 Oct 2025 05:56:28 +0000 (UTC) (envelope-from yasu@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 "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4chMhD4c6dz49rs; Wed, 08 Oct 2025 05:56:28 +0000 (UTC) (envelope-from yasu@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1759902988; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WQpR9OgEYZH8gplq+FCgBQAAMmMHigPe2zrrX0AFfZY=; b=ncmWqpkB1KGM9OFOuReGbgBOw0JO28f3sCK+rqejukDZk6zDH7JRRaKqN+uSpsFr1dmqSI IuyuyA/i20DT6BbPbjPGixDSeYydwmafh4X56PeZqSw1cvEXQnTdeGAfSgF4S9W2+iSmtL lFYAMVMSPgTKcqCM+pfjxoaGE1ysxJ7cCAklP7FMH32qCygBK6LYRdkzHbq385xuiGIAcd SbHkl4HhYH3FO3il6MgSC7gJOAzWfujKV5fjyreL4RNzv4R0mvk5ZkYUFEerJL9uHO3ZZr TlY7Nt+dQO2fB9VAUVWhfu+QLc36psITW4oW6Z2TAKiaP4irCVek60wHJomb7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1759902988; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WQpR9OgEYZH8gplq+FCgBQAAMmMHigPe2zrrX0AFfZY=; b=KOTC0ivDKNQfv7xA6ued/jz4Yyakj2NNvM6vZBqxli/Ew3kQMQbsVucewy9aNO+3SVx+tu +kOuOje060qb8Dyonu6JdmsKj9Hi2euHW3Mou3UUZImembjz/8PFNtwxKX1RraRVdIcpou vitVSjgUj99C2eW57PV0p8/KuO4yHlFYjBXKlqXycTvXDXUDsLkmkT6FlOir1P8OALAuJy fpVp1/znwe2H9DpZczwTlIbbE2cZUyhZ7mlxEvELtDsU6pcF1/8rsqWoTk5e6VmMWdq1hi zbhY+rPHGvyZNlg++Sq3ehzt9kmkisoBRo7jKfsZpSGuo9hlLqTktRz6rn2Opw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1759902988; a=rsa-sha256; cv=none; b=JmHDEZ31FZmEg8vHWxX5qq8oAqPcFAm6DE3K86SYVty2uooaMNhWVJEok3NhyZSrRzHPjb Hv3mgDNu/XFr2wU5U8H2vSyaOx+5yDy6oi4YHqaliy7pFnvyddmhIO0HySDvygl3vCT7UF BEQfgMTcEOCN98DBCd/L+6Oexm1ArAebcBIUE3D5m6u+zUUtu8sWz/ibTV89dhHXcqpcbf aZJUTt6TdMiK4fXGuA7IM4lTEC0ezjJtbpyCGx3cHLaxRq/sYrm6+o901/OYmWF34tKZya J6A/2qyG3HH99TpeNVSaXNt6/QjIAASd4IYOrkLTGY/pmB5l6Rhojj+B4WrtJg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from localhost (unknown [IPv6:240b:11:220:fe00::174:11]) (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 did not present a certificate) (Authenticated sender: yasu/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4chMhC6rX1zlV5; Wed, 08 Oct 2025 05:56:27 +0000 (UTC) (envelope-from yasu@FreeBSD.org) Date: Wed, 08 Oct 2025 14:55:29 +0900 (JST) Message-Id: <20251008.145529.172147507683569904.yasu@FreeBSD.org> To: freebsd-current@freebsd.org Subject: Re: How to make `pkg version` work fine with private pkgbase repository From: Yasuhiro Kimura In-Reply-To: References: <20251008.135359.1026187049848325621.yasu@FreeBSD.org> X-Mailer: Mew version 6.10 on Emacs 31.0.50 List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit From: Lexi Winter Subject: Re: How to make `pkg version` work fine with private pkgbase repository Date: Wed, 8 Oct 2025 06:04:35 +0100 >> As is explained in pkg-version(8) man page, `pkg version` summarizies >> installed versions of packages. >>[...] >> But it doesn't seem to work well if repostory is build with >> `make (update-)packages` >>[...] >> root@rolling-vm-freebsd5[159]# pkg version -v -n FreeBSD-kernel-generic >> FreeBSD-kernel-generic-16.snap20251008030957 ? orphaned: base/FreeBSD-kernel-generic > > using 'pkg version -vR' makes this work. Thanke for letting me know. By specifying '-R' option the command works fine as below. root@rolling-vm-freebsd5[167]# cat /usr/local/etc/pkg/repos/FreeBSD-base.conf FreeBSD-base: { url: "file:///usr0/freebsd/src/repo/${ABI}/latest", enabled: yes priority: 0 } root@rolling-vm-freebsd5[168]# pkg version -R -v -n FreeBSD-kernel-generic Updating FreeBSD-base repository catalogue... FreeBSD-base repository is up to date. Updating Poudriere repository catalogue... Poudriere repository is up to date. All repositories are up to date. FreeBSD-kernel-generic-16.snap20251008030957 = up-to-date with remote root@rolling-vm-freebsd5[169]# > i am not entirely sure why, > but based on the description of the -R flag in the manpage, it seems > like pkg will default to consulting /usr/ports if it's available, > rather than using the repository. this obviously doesn't work for > base packages since they don't exist in ports. I guess such behavior of pkg is influenced by ancient pkg_* commands that was initially developed when common way to install ports package was `cd /usr/ports/category/name ; make install`. >> BTW, are there any common(?) or normative(?) or official(?) terms that >> mean "package built from ports tree" and "package built from src tree" >> respectively? > > i would call these "ports packages" and "base packages". this matches > the default repository names, "FreeBSD-ports" and "FreeBSD-base". Looks nice. Let me adopt them. --- Yasuhiro Kimura