View previous topic :: View next topic |
Author |
Message |
jpp_ Tux's lil' helper
Joined: 23 Oct 2009 Posts: 110 Location: Argentina
|
Posted: Fri Jan 14, 2022 5:08 pm Post subject: ebuild for ymuse |
|
|
Good day
Trying to make an ebuild for ymuse
https://github.com/yktoo/ymuse
With this it builds
Code: | # Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
EGIT_REPO_URI="https://github.com/yktoo/ymuse"
inherit go-module git-r3
DESCRIPTION="GTK client for Music Player Daemon (MPD) written in Go"
HOMEPAGE="https://github.com/yktoo/ymuse"
# Check go.sum and sync with this
# Use e.g.: cat go.sum | cut -d" " -f1,2 | awk '{print "\t\"" $0 "\""}'
# (Could maybe use dev-go/get-ego-vendor?)
EGO_SUM=(
"github.com/fhs/gompd/v2 v2.2.0"
"github.com/fhs/gompd/v2 v2.2.0/go.mod"
"github.com/gotk3/gotk3 v0.6.1"
"github.com/gotk3/gotk3 v0.6.1/go.mod"
"github.com/op/go-logging v0.0.0-20160315200505-970db520ece7"
"github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod"
"github.com/pkg/errors v0.9.1"
"github.com/pkg/errors v0.9.1/go.mod"
)
go-module_set_globals
SRC_URI="${EGO_SUM_SRC_URI}"
# TODO: use dev-go/go-licenses or dev-go/go-license-detector to populate this more
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
RDEPEND="x11-libs/gtk+:3"
src_unpack() {
git-r3_src_unpack
go-module_src_unpack
}
src_compile() {
go build || die
}
src_install() {
dobin ymuse
}
|
it works also, But i miss some icons, the desktop file and maybe more.
Also i think the ebuild is not ok, because i adapt it from other go ebuild, maybe it has unnecesary part and miss important ones.
in github it describe the install as follow
Clone the source and compile:
Code: |
git clone https://github.com/yktoo/ymuse.git
cd ymuse
go generate
go build |
Copy over the icons and localisations:
Code: | sudo cp -r resources/icons/* /usr/share/icons/
sudo cp -r resources/i18n/generated/* /usr/share/locale/
sudo update-icon-caches /usr/share/icons/hicolor/* |
How do i "translate" that to the ebuild?
i add to the src_install section this, with some other trys, but of course its wrong
Code: | doins -r resources/icons/
doins -r resources/i18n/generated/
doins update-icon-caches /usr/share/icons/hicolor/ |
Any help would be appreciated, thanks. |
|
Back to top |
|
|
fedeliallalinea Administrator
Joined: 08 Mar 2003 Posts: 30917 Location: here
|
Posted: Fri Jan 14, 2022 5:24 pm Post subject: |
|
|
For icons look on doicon function from desktop.eclass, use this eclass also for move desktop file with domenu functon.
For localization you should convert .po file in .mo file with msgfmt command on compilation phase (see for example media-gfx/dcraw-9.28.0-r2.ebuild). _________________ Questions are guaranteed in life; Answers aren't. |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1660
|
Posted: Fri Jan 14, 2022 5:49 pm Post subject: |
|
|
To update desktop/icon cache, inherit xdg and it adds functions to do it for you. |
|
Back to top |
|
|
|