View previous topic :: View next topic |
Author |
Message |
grooveman Veteran
Joined: 24 Feb 2003 Posts: 1217
|
Posted: Thu Jan 13, 2011 2:25 pm Post subject: Trying to use binary packages... [Solved] |
|
|
Hi,
I have done this before in the past, but now it doesn't seem to work.
I have two systems which are identical in hardware, and identical in configuration.
Last night I recompiled the world on system A, with buildpkg in my make.conf, so /usr/portage/packages is filled with a bunch of binaries -- as it should be.
I rsynced that directory from systemA:/usr/portage/packages to systemB:/usr/portage/packages.
I then on systemB I issue:
Code: |
export PKGDIR="/usr/portage/packages"
emerge -k y -uDN world |
And it refuses to use the binaries. It starts downloading and compiling everything as if the -k option was not used.
I have tried to use the --usepkg and the --usepkgonly flags along with the capital K -- nothing works. I have exported my PKGDIR both in my make.conf and in the shell and an "emerge --info" shows the PKGDIR as plain as day.
Why is portage ignoring the -k? I have used it before several times in the past, and don't recall running into this problem.
Thanks for the help.
G
cat /etc/make.conf
Code: | # These settings were set by the catalyst build script that automatically
# built this stage.
# Please consult /usr/share/portage/config/make.conf.example for a more
# detailed example.
CFLAGS="-march=amdfam10 -O2 -pipe"
CXXFLAGS="${CFLAGS}"
# WARNING: Changing your CHOST is not something that should be done lightly.
# Please consult http://www.gentoo.org/doc/en/change-chost.xml before changing.
CHOST="x86_64-pc-linux-gnu"
# These are the USE flags that were used in addition to what is provided by the
# profile used for building.
#USE="kde hal dbus fluxbox eterm sdl mmx sse sse2 nvidia xvmc dvd cdr alsa usb -gnome -qt -gtk -ipv6 -bluetooth -arts"
USE="X amr pulseaudio a52 irc oscar msn skype yahoo v4l v4l2 nspluginwrapper lcms raw gmplayer lib32 fuse id3 mtp jpeg zip bzip2 exif xvmc divx 3dnow realmedia mp3 xv flac dts hal dvdread ppds nsplugin nvidia vorbis usb wmv vidix gtk gtk2 gimp gimp-2.2 gimpprint svg libusb xsane gnome cddb apic alsa distcc java apm -arts fbcon avi cups mpeg crypt dvd flash gif gphoto2 gpm kde mmx motif ncurses oggvorbis opengl pam perl png qt4 quicktime samba spell ssl tcpd tetex tiff truetype xscreensaver oss dv dga v4l v4l2 ffmpeg ogg nptl nptlonly -bluetooth -gnome -ipv6 -bluetooth -arts"
MAKEOPTS="-j7"
FEATURES="distcc ccache buildpkg parallel-fetch"
#FEATURES="buildpkg parallel-fetch"
CCACHE_SIZE="2G"
CCACHE_DIR="/var/tmp/ccache"
VIDEO_CARDS="radeon vesa"
LINGUAS="en_US en"
LANGUAGE="en_US"
INPUT_DEVICES="evdev"
PORTDIR_OVERLAY="/usr/local/portage"
PKGDIR="/usr/portage/packages"
ACCEPT_LICENSE="* @EULA" |
_________________ To look without without looking within is like looking without without looking at all.
Last edited by grooveman on Sat Jan 15, 2011 2:58 am; edited 1 time in total |
|
Back to top |
|
|
mikegpitt Advocate
Joined: 22 May 2004 Posts: 3224
|
Posted: Thu Jan 13, 2011 2:41 pm Post subject: |
|
|
If your PKGDIR points to /usr/portage/packages, you need to put your binaries in /usr/portage/packages/All/.
Also, I don't think the -k option needs to be passed the 'y' argument. Try just emerging one package to start with the -K option, just to make sure the world argument isn't messing anything up (not that it should).
Code: | echo "PKGDIR=\"/usr/portage/packages\"" >> /etc/make.conf
cp mypackage.tbz2 /usr/portage/packages/All/.
emerge -K mypackage |
|
|
Back to top |
|
|
grooveman Veteran
Joined: 24 Feb 2003 Posts: 1217
|
Posted: Thu Jan 13, 2011 3:15 pm Post subject: |
|
|
Hm... Thanks Mike.
I don't remember having to set an "All" directory... perhaps I did and I forgot... In fact, that makes no sense to me, because portage dumps straight to /usr/portage/packages by virtue of putting buildpkg in my make.conf. If I had to use the All subdir, then my system A would never find its own binaries. I suppose I could resolve this with a symbolic link, but that seems silly. Why not just have it use /usr/portage/packages? _________________ To look without without looking within is like looking without without looking at all. |
|
Back to top |
|
|
dol-sen Retired Dev
Joined: 30 Jun 2002 Posts: 2805 Location: Richmond, BC, Canada
|
Posted: Thu Jan 13, 2011 3:39 pm Post subject: |
|
|
Your "Packages" index file was not transfered and/or updated after you rsynced. Code: | emaint --fix binhost |
That will update it. You should be good to go after that.
The "All" directory is part of the old system and is no longer used. _________________ Brian
Porthole, the Portage GUI frontend irc@freenode: #gentoo-guis, #porthole, Blog
layman, gentoolkit, CoreBuilder, esearch... |
|
Back to top |
|
|
rh1 Guru
Joined: 10 Apr 2010 Posts: 501
|
Posted: Thu Jan 13, 2011 3:41 pm Post subject: |
|
|
I thought it should work fine with PKGDIR set in make.conf but since it doesn't , what about setting PORTAGE_BINHOST in make.conf to point to your packages dir and using Code: | emerge --usepkg --getbinpkg <package> |
|
|
Back to top |
|
|
mikegpitt Advocate
Joined: 22 May 2004 Posts: 3224
|
Posted: Thu Jan 13, 2011 4:29 pm Post subject: |
|
|
grooveman wrote: | Hm... Thanks Mike.
I don't remember having to set an "All" directory... perhaps I did and I forgot... In fact, that makes no sense to me, because portage dumps straight to /usr/portage/packages by virtue of putting buildpkg in my make.conf. If I had to use the All subdir, then my system A would never find its own binaries. I suppose I could resolve this with a symbolic link, but that seems silly. Why not just have it use /usr/portage/packages? | Yeah, I don't know why it works this way with the /All directory, but I've been pushing out binaries in this manner to gentoo machines for years.
You should see if you have portage save binary copies of your packages that it will set up a directory structure to portage under /usr/portage/packages and under each of those directories it will symlink to the actual binary packages in /All. For the machines you are rolling the binaries out to, they just need to see the packages under /All. |
|
Back to top |
|
|
grooveman Veteran
Joined: 24 Feb 2003 Posts: 1217
|
Posted: Thu Jan 13, 2011 4:55 pm Post subject: |
|
|
Thanks everybody.
Yes, so this will work on a per package basis... but that only begs my next question:
How do I force portage to always try to use the binary package first? I'm concerned primarily with "revdep-rebuild"s here . Even having the binary where it can be found by doing a emerge --usepkg on a per-package basis, revdep-rebuild seems to disregard them. Which pretty much undermines what I'm trying to achieve here. I can't find anything in the manpages on this. It doesn't look like revdep-rebuild can take normal portage arguments, so I'm not sure what to do... _________________ To look without without looking within is like looking without without looking at all. |
|
Back to top |
|
|
dol-sen Retired Dev
Joined: 30 Jun 2002 Posts: 2805 Location: Richmond, BC, Canada
|
Posted: Fri Jan 14, 2011 1:01 am Post subject: |
|
|
to pass on extra arguments to portage, you need to add a dble dash "--" then the extra args.
Code: | revdep-rebuild -- --keep-going -k |
Also, if your use flags are not set exactly the same or you have some different packages on this machine. A binary from the other machine may not satisfy the dependencies and needs to be built differently than the available binary. _________________ Brian
Porthole, the Portage GUI frontend irc@freenode: #gentoo-guis, #porthole, Blog
layman, gentoolkit, CoreBuilder, esearch... |
|
Back to top |
|
|
grooveman Veteran
Joined: 24 Feb 2003 Posts: 1217
|
Posted: Sat Jan 15, 2011 2:58 am Post subject: |
|
|
Great. Thanks! I thought there must be a way... I just did not see that in the man page... _________________ To look without without looking within is like looking without without looking at all. |
|
Back to top |
|
|
|