View previous topic :: View next topic |
Author |
Message |
paulj Guru


Joined: 30 Sep 2004 Posts: 526 Location: Wales, UK
|
Posted: Sun May 26, 2024 10:50 am Post subject: Issues writing a -meta ebuild (Solved) |
|
|
I am playing around with making meta ebuilds to simplify setting up new systems according to my "usual" configuration (see https://forums.gentoo.org/viewtopic-t-1169109-highlight-.html for more details).
Unfortunately, I am stumbling at the first step!
I have created the following ebuild as a test (modelled on kdegames-meta.ebuild):
Code: | # Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="electronics-meta - merge this in to pull all the electronics"
HOMEPAGE="https://teulu.org"
LICENSE="metapackage"
SLOT="0"
KEYWORDS="amd64"
IUSE="doc"
RDEPEND="
sci-electronics/kicad-meta
doc? ( app-doc/kicad-doc)
" |
So, very simple indeed. It should merge kicad-meta, and if the doc flag is set, then also emerge the documentation.
I have put this in a directory called sys-config in a new local overlay (created with eselect repository create...). When I run "ebuild electronics-meta.ebuild manifest", I get an error: Code: | Appending /var/db/repos to PORTDIR_OVERLAY...
!!! Repository 'x-repos' is missing masters attribute in '/var/db/repos/metadata/layout.conf'
!!! Set 'masters = gentoo' in this file for future compatibility
ebuild: /var/db/repos/local-config/sys-config/electronics-meta.ebuild: local-config/electronics-meta: does not follow correct package syntax |
I don't think the first three lines are relevant, but the last line leaves me puzzled, as I cannot see what is incorrect in the file or the way it has been named. I can also not see how I can get ebuild to be more descriptive about the error.
Can any of you give me some hints?
Last edited by paulj on Sun May 26, 2024 5:35 pm; edited 1 time in total |
|
Back to top |
|
 |
grknight Retired Dev

Joined: 20 Feb 2015 Posts: 2141
|
Posted: Sun May 26, 2024 1:29 pm Post subject: |
|
|
Move /var/db/repos/local-config/sys-config/electronics-meta.ebuild to /var/db/repos/local-config/sys-config/electronics-meta/electronics-meta-0.ebuild
Also, since sys-config isn't a Gentoo category, you will need to create the file /var/db/repos/local-config/profiles/categories with sys-config as its contents. |
|
Back to top |
|
 |
Genone Retired Dev


Joined: 14 Mar 2003 Posts: 9632 Location: beyond the rim
|
Posted: Sun May 26, 2024 1:36 pm Post subject: |
|
|
To be clear:
- You must use a category name known to portage, you can't make it up on the fly (this has technical reasons)
- Every ebuild must specify a version, even if it doesn't install any content itself
Also in the ebuild itself, make sure you have a whitespace before the closing parentheses of the doc? conditional. |
|
Back to top |
|
 |
paulj Guru


Joined: 30 Sep 2004 Posts: 526 Location: Wales, UK
|
Posted: Sun May 26, 2024 5:35 pm Post subject: |
|
|
grknight wrote: | Move /var/db/repos/local-config/sys-config/electronics-meta.ebuild to /var/db/repos/local-config/sys-config/electronics-meta/electronics-meta-0.ebuild
|
Doh - of course!!!
grknight wrote: |
Also, since sys-config isn't a Gentoo category, you will need to create the file /var/db/repos/local-config/profiles/categories with sys-config as its contents. |
I did wonder if this was an issue, and tried with a known category instead without success (due to the issue above).
Thanks for pointing out my error, and also the detail behind the category naming (also thanks Genone). |
|
Back to top |
|
 |
|