Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Risolto] revdep-rebuild ricompila sempre lo stesso binario
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian)
View previous topic :: View next topic  
Author Message
antonellocaroli
Guru
Guru


Joined: 11 Aug 2016
Posts: 379

PostPosted: Sun Feb 23, 2020 8:31 am    Post subject: [Risolto] revdep-rebuild ricompila sempre lo stesso binario Reply with quote

Non so perché ma revdep-rebuild mi ricopila sempre lo stesso binario...
ho provato a disinstalla > depclean > e reinstallare il tutto
ma niente

la ebuild del binario é questa

Quote:
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=6

inherit unpacker user systemd

MY_PN=${PN/-bin/}

DESCRIPTION="HQPlayer Embedded - upsampling multichannel audio player"
HOMEPAGE="http://www.signalyst.com/consumer.html"
SRC_URI="
amd64? ( https://www.signalyst.eu/bins/hqplayerd/buster/${MY_PN}_${PV}-44_amd64.deb )
arm64? ( https://www.signalyst.eu/bins/hqplayerd/buster/${MY_PN}_${PV}-44_arm64.deb )
"

LICENSE="Signalyst"
SLOT="0"
KEYWORDS="~amd64 ~arch64"
RESTRICT="mirror bindist"

IUSE="systemd"

RDEPEND=">=dev-libs/glib-2.37.3
>=media-libs/libgmpris-2.2.1
>=media-libs/alsa-lib-1.0.16
>=media-libs/flac-1.3.0
>=media-libs/libogg-1.3.3
>=net-misc/rygel-0.34.0
>=sys-libs/libomp-7.1.0
>=net-libs/gupnp-1.0.4
>=net-libs/gupnp-av-0.12.11"

DEPEND="${RDEPEND}"

S="${WORKDIR}"
QA_PREBUILT="usr/bin/hqplayerd"


#pkg_setup() {
# if use !systemd; then
# enewgroup hqplayerd
# enewuser hqplayerd -1 -1 "/dev/null" "hqplayerd,audio"
# fi
#}

src_unpack() {
unpack_deb ${A}
}

src_install() {
mv etc lib usr var "${D}" || die
rm "${D}usr/share/doc/hqplayerd/changelog.Debian.gz"
dosym "${ED%/}"/usr/lib64/libomp.so /usr/lib64/libomp.so.5
if use systemd; then
systemd_dounit "${FILESDIR}/${MY_PN}.service"
else
newinitd "${FILESDIR}/${MY_PN}.init.d" "${MY_PN}"
fi
}

pkg_postinst() {
# Provide some post-installation tips.
elog ""
elog ""
elog ""
elog "HQPlayer Embedded can be started with the following command (OpenRC):"
elog "\t/etc/init.d/hqplayerd start"
elog "or (systemd):"
elog "\tsystemctl start hqplayerd"
elog ""
elog "HQPlayer Embedded can be automatically started on each boot"
elog "with the following command (OpenRC):"
elog "\trc-update add hqplayerd default"
elog "or (systemd):"
elog "\tsystemctl enable hqplayerd"
elog ""
elog ""
elog ""
elog "Please change the password as soon as possible, either through the web interface,"
elog "or from command line using command:"
elog "\thqplayerd -s root gentooplayer"
elog ""
elog ""
elog "web interface:"
elog "\tip:8088"
elog ""
}
Code:


Last edited by antonellocaroli on Mon Feb 24, 2020 6:01 pm; edited 1 time in total
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 24690
Location: here

PostPosted: Sun Feb 23, 2020 2:47 pm    Post subject: Reply with quote

Cosa riturna il comando revdep-rebuild -pv?
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
antonellocaroli
Guru
Guru


Joined: 11 Aug 2016
Posts: 379

PostPosted: Sun Feb 23, 2020 6:10 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Cosa riturna il comando revdep-rebuild -pv?


Code:
revdep-rebuild -pv
 * This is the new python coded version
 * Please report any bugs found using it.
 * The original revdep-rebuild script is installed as revdep-rebuild.sh
 * Please file bugs at: https://bugs.gentoo.org/
 * Collecting system binaries and libraries
 * Collecting dynamic linking informations
 * Scanning files
 * Checking dynamic linking consistency
 * Broken files that require: libomp.so.5 (64 bits)
   * /usr/bin/hqplayerd
 * Assign files to packages
   * /usr/bin/hqplayerd -> media-sound/hqplayerd-bin-4.14.0

emerge --pretend --verbose --oneshot --complete-graph=y media-sound/hqplayerd-bin:0

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   ~] media-sound/hqplayerd-bin-4.14.0::antonellocaroli  USE="-systemd" 0 KiB

Total: 1 package (1 reinstall), Size of downloads: 0 KiB

 * IMPORTANT: 10 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.



puó dipendere dal fatto che la ebuild crea un link simbolico?

Code:
dosym "${ED%/}"/usr/lib64/libomp.so /usr/lib64/libomp.so.5
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 24690
Location: here

PostPosted: Sun Feb 23, 2020 7:35 pm    Post subject: Reply with quote

Secondo me si', e se togli quel comando dall'ebuild funziona ancora il programma?
Altrimenti si potrebbe usare patchelf per cambiare per modificare il link dinamico all'eseguibile o libreria di hqplayerd
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
antonellocaroli
Guru
Guru


Joined: 11 Aug 2016
Posts: 379

PostPosted: Sun Feb 23, 2020 7:42 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Secondo me si', e se togli quel comando dall'ebuild funziona ancora il programma?


no, se non creo quel link non funziona perché non trova libomp.so.5

Quote:
Altrimenti si potrebbe usare patchelf per cambiare per modificare il link dinamico all'eseguibile o libreria di hqplayerd


in che modo?
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 24690
Location: here

PostPosted: Sun Feb 23, 2020 7:51 pm    Post subject: Reply with quote

antonellocaroli wrote:
in che modo?

In primo luogo devi mettere nel tuo ebuild anche la dipendenza dev-util/patchelf in BDEPEND.
Fatto questo devi capire che eseguibile o libreria abbia bisogno di libomp.so.5, quindi in src_prepare aggiungi la linea
Code:
patchelf --replace-needed libomp.so.5 libomp.so <nome_eseguibile_o_libreria> || die

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
antonellocaroli
Guru
Guru


Joined: 11 Aug 2016
Posts: 379

PostPosted: Sun Feb 23, 2020 7:58 pm    Post subject: Reply with quote

fedeliallalinea wrote:

Fatto questo devi capire che eseguibile o libreria abbia bisogno di libomp.so.5, quindi in src_prepare aggiungi la linea
[code]patchelf --replace-needed libomp.so.5 libomp.so <nome_eseguibile_o_libreria> || die


come faccio a capirlo?

scusa l' ignoranza....
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 24690
Location: here

PostPosted: Sun Feb 23, 2020 8:14 pm    Post subject: Reply with quote

antonellocaroli wrote:
come faccio a capirlo?

scusa l' ignoranza....

Puoi usare ldd <nome> | grep libomp su le varie librerie e eseguibili
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
antonellocaroli
Guru
Guru


Joined: 11 Aug 2016
Posts: 379

PostPosted: Mon Feb 24, 2020 6:04 am    Post subject: Reply with quote

fedeliallalinea wrote:
antonellocaroli wrote:
come faccio a capirlo?

scusa l' ignoranza....

Puoi usare ldd <nome> | grep libomp su le varie librerie e eseguibili


ok, ho provato patchelf deirettamente sul binario installato e funziona.

ma nella ebuild non riesco a replicarlo....ho cambiato cosi:

Code:
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=6

inherit unpacker user systemd

MY_PN=${PN/-bin/}

DESCRIPTION="HQPlayer Embedded - upsampling multichannel audio player"
HOMEPAGE="http://www.signalyst.com/consumer.html"
SRC_URI="
amd64? ( https://www.signalyst.eu/bins/hqplayerd/buster/${MY_PN}_${PV}-44_amd64.deb )
arm64? ( https://www.signalyst.eu/bins/hqplayerd/buster/${MY_PN}_${PV}-44_arm64.deb )
"

LICENSE="Signalyst"
SLOT="0"
KEYWORDS="~amd64 ~arch64"
RESTRICT="mirror bindist"

IUSE="systemd"

RDEPEND=">=dev-libs/glib-2.37.3
   >=media-libs/libgmpris-2.2.1
   >=media-libs/alsa-lib-1.0.16
   >=media-libs/flac-1.3.0
   >=media-libs/libogg-1.3.3
   >=net-misc/rygel-0.34.0
   >=sys-libs/libomp-7.1.0
  >=net-libs/gupnp-1.0.4
  >=net-libs/gupnp-av-0.12.11"

DEPEND="${RDEPEND}"

S="${WORKDIR}"
QA_PREBUILT="usr/bin/hqplayerd"


#pkg_setup() {
#   if use !systemd; then
#      enewgroup hqplayerd
#      enewuser hqplayerd -1 -1 "/dev/null" "hqplayerd,audio"
#   fi
#}

src_unpack() {
   unpack_deb ${A}
}

src_prepare() {
     patchelf --replace-needed libomp.so.5 libomp.so hqplayerd || die
}

src_install() {
   mv etc lib usr var "${D}" || die
   rm "${D}usr/share/doc/hqplayerd/changelog.Debian.gz"
   if use systemd; then
      systemd_dounit "${FILESDIR}/${MY_PN}.service"
   else
      newinitd "${FILESDIR}/${MY_PN}.init.d" "${MY_PN}"
   fi
}

pkg_postinst() {
   # Provide some post-installation tips.
   elog ""
   elog ""
   elog ""
  elog "HQPlayer Embedded can be started with the following command (OpenRC):"
  elog "\t/etc/init.d/hqplayerd start"
  elog "or (systemd):"
  elog "\tsystemctl start hqplayerd"
  elog ""
  elog "HQPlayer Embedded can be automatically started on each boot"
  elog "with the following command (OpenRC):"
  elog "\trc-update add hqplayerd default"
  elog "or (systemd):"
  elog "\tsystemctl enable hqplayerd"
  elog ""
  elog ""
   elog ""
   elog "Please change the password as soon as possible, either through the web interface,"
   elog "or from command line using command:"
   elog "\thqplayerd -s root gentooplayer"
   elog ""
   elog ""
   elog "web interface:"
   elog "\tip:8088"
   elog ""
   }


ma mi da errore

Code:
>>> Preparing source in /var/tmp/portage/media-sound/hqplayerd-bin-4.14.0/work ...
 * ERROR: media-sound/hqplayerd-bin-4.14.0::antonellocaroli failed (prepare phase):
 *   eapply_user (or default) must be called in src_prepare()!
 *
 * Call stack:
 *            ebuild.sh, line  773:  Called __ebuild_main 'prepare'
 *   phase-functions.sh, line 1071:  Called __dyn_prepare
 *   phase-functions.sh, line  395:  Called die
 * The specific snippet of code:
 *         die "eapply_user (or default) must be called in src_prepare()!"
 *
 * If you need support, post the output of `emerge --info '=media-sound/hqplayerd-bin-4.14.0::antonellocaroli'`,
 * the complete build log and the output of `emerge -pqv '=media-sound/hqplayerd-bin-4.14.0::antonellocaroli'`.
 * The complete build log is located at '/var/tmp/portage/media-sound/hqplayerd-bin-4.14.0/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/media-sound/hqplayerd-bin-4.14.0/temp/environment'.
 * Working directory: '/var/tmp/portage/media-sound/hqplayerd-bin-4.14.0/work'
 * S: '/var/tmp/portage/media-sound/hqplayerd-bin-4.14.0/work'
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 24690
Location: here

PostPosted: Mon Feb 24, 2020 6:36 am    Post subject: Reply with quote

Questo capita perche' dalle EAPI 6 sei obbligato ad avere la funzione eapply_user o default in src_prepare per potere far si che la gente possa usare le proprie patch con /etc/portage/patches, quindi la cambiare con
Code:
src_prepare() {
     default
     patchelf --replace-needed libomp.so.5 libomp.so hqplayerd || die
}

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
antonellocaroli
Guru
Guru


Joined: 11 Aug 2016
Posts: 379

PostPosted: Mon Feb 24, 2020 6:01 pm    Post subject: Reply with quote

fedeliallalinea wrote:
Questo capita perche' dalle EAPI 6 sei obbligato ad avere la funzione eapply_user o default in src_prepare per potere far si che la gente possa usare le proprie patch con /etc/portage/patches, quindi la cambiare con
Code:
src_prepare() {
     default
     patchelf --replace-needed libomp.so.5 libomp.so hqplayerd || die
}



Grazie fedeliallalinea!! come sempre!!!

adesso funziona perfettamente.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum