From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 9431D1382C5 for ; Sun, 7 Jun 2020 18:22:58 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6AA2BE09A5; Sun, 7 Jun 2020 18:22:52 +0000 (UTC) Received: from mail-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 2B01BE0982 for ; Sun, 7 Jun 2020 18:22:51 +0000 (UTC) Received: by mail-ed1-f49.google.com with SMTP id g9so11538535edw.10 for ; Sun, 07 Jun 2020 11:22:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=oHdSLmVZl5Z/BbV/95NK4bkLmN0HBv/SJN8YdRon3wA=; b=taqV9Zt+JaMC0ZkPtaVDmulvcru8W3NJ1kQeaPL9gLDCaqBX8V5Mby2pwKiZCoHt2C ZIwQDTA4+olxG98NXgn8+DwfVG1uNYkWSrHoHrVhz90iV0pHP7BOJYU2xIOdXc9ypwrF R4S1A2/wtkhnm+x91Sr/jIdvf2MXg8HJo+D0dcFLDBay3axNubPtS9jV0aBvm14qyCm4 KhVNw2gUtOZ5b64JuuTL/HQaGCTCqzip6MJBuwsL6/rj25J+VRt7mjIJ9WlA6PWnH/oU KhBV493C6yBzfazdN5+mrcSinmEKuZpqEtbR95k5/AGjJdoCK3UjeoJcezuOGhek0Qam wesA== X-Gm-Message-State: AOAM533iD1axAigRmCntBWGijlkPkP7nBZG6iX3zLUS69MMnQDohTHHL 4qpJvO5UrrC1lk3+Y4/G7+E2vE093eJ9g+XAu4qbYbys X-Google-Smtp-Source: ABdhPJxmJSiiIosDKg8+wkXCDMftQJnHi2eXps5QAEGkArTYxUhN4yN8f3eGqczTDkYchgEXtiZNmoj86dwfp18hipE= X-Received: by 2002:a05:6402:a4d:: with SMTP id bt13mr13907565edb.338.1591554170422; Sun, 07 Jun 2020 11:22:50 -0700 (PDT) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 References: In-Reply-To: From: Rich Freeman Date: Sun, 7 Jun 2020 14:22:38 -0400 Message-ID: Subject: Re: [gentoo-user] where are the version numbers of a profile stored? To: gentoo-user@lists.gentoo.org Content-Type: text/plain; charset="UTF-8" X-Archives-Salt: 0e497af2-958a-4f18-a45c-878c0d7dcebb X-Archives-Hash: a7dee2101b16cce4afd4a7f9d41e2334 On Sun, Jun 7, 2020 at 1:31 PM n952162 wrote: > > When I do an emerge --sync, various ebuilds are loaded onto my system, > co-existing with other ebuilds, possibly from the same package. What > determines which package version is to be used? > > I assumed this was specified by the profile (e.g. 17.1), but I can't > find any version numbers in /etc/portage/make.profile/ > The process is exclusionary, not inclusionary, for the most part, which is why the profiles tend to be simple and not list a lot of packages or versions. Portage installs the highest version of a package which is not blocked for some reason, unless you explicitly tell it to install a particular version of a package (which still will only install if not blocked for some reason). So, if you type: emerge '=app-shells/bash-5.0_p11' Then portage will install that version of bash if it is not blocked for some reason. If you type: emerge app-shells/bash Then portage will install the latest version of bash that is not blocked for some reason. The same applies to dependencies pulled in by packages - if a particular version is pulled in then that version will be installed if possible. If a dependency is mentioned then the latest allowable version will be installed. The dependency can also include version restrictions in which case the latest version allowed with the additional restrictions will be installed. I'll leave out USE dependencies, which impose more rules. So, at that point the only thing that matters is the various mechanisms that block package versions from installing: masks and keywords. Keywords: A package version can only be installed if it contains an accepted keyword. Keywords can be accepted by your profile or by your make.conf. Eg, ~amd64 or amd64. If the package does not declare any keyword that you are accepting, then it will not be used. This is the main mechanism used to determine what version you will get. Packages are keyworded based on whether they work (~arch) or are considered stable (arch) on a particular architecture. Masks: A package version cannot be installed if it is masked. This can be set in /etc/portage/package.mask, or by a profile. Masks are used for a lot of reasons - sometimes to stage package versions for broader testing before being released, and sometimes because they don't work well in a particular profile, and often for security concerns or as a prelude to removal. If you post a specific example I can explain what version will be installed, assuming you don't have any dependencies with version restrictions, and you will need to tell me what your ACCEPT_KEYWORDS and profile are set to. -- Rich