Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 381293 - sys-auth/pambase-20101024 w/ sys-libs/pam-1.1.3-r1 - hangs
Summary: sys-auth/pambase-20101024 w/ sys-libs/pam-1.1.3-r1 - hangs
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal minor (vote)
Assignee: PAM Gentoo Team (OBSOLETE)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-31 13:14 UTC by Federico Moretti
Modified: 2012-04-01 04:46 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Federico Moretti 2011-08-31 13:14:09 UTC
sys-auth/pambase-20101024 stops at the compile phase with sys-libs/pam-1.1.3-r1: it doesn't matter which USE flags are selected, nor the CPPFLAGS attributes, etc.; I found that the problem is in the regular expression for getting sys-libs/pam version: it expect to get 0x010100 or higher (in the particular case, it should be 0x010103) to choose between pam_tally.so and pam_tally2.so, but nothing happens. Forcing linux_pam_version to 0x010103 in the ebuild solved the issue.

Reproducible: Always

Steps to Reproduce:
1. emerge sys-libs/pam-1.1.3-r1
2. emerge sys-auth/pambase-20101024
Actual Results:  
sys-auth/pambase-20101024 ebuild stops at "Compiling source..." without any output of the failure.

Expected Results:  
sys-auth/pambase-20101024 completes the installation process.

It seems to be just a regex syntax error, apparently caused by the "-r1" appendix for the sys-libs/pam latest version. Here's the affected string:

48 	linux_pam_version=$(printf "0x%02x%02x%02x" ${ver_str//\./ })
Comment 1 Diego Elio Pettenò (RETIRED) gentoo-dev 2011-09-01 14:15:25 UTC
Please.

emerge --info and a build log.

Because I have rebuilt it at least five times in the past two days and it never stopped.
Comment 2 Federico Moretti 2011-09-01 23:09:06 UTC
(In reply to comment #1)
> Please.
> 
> emerge --info and a build log.
> 
> Because I have rebuilt it at least five times in the past two days and it never
> stopped.

This happens with GCC 4.4, 4.5 and 4.6 on x86 and amd64 with different hardware: I couldn't post all the emerge --info output of these machines, because e.g. I don't own anymore the first one which stopped with. I changed CPPFLAGS and configurations several times and I got the same results, even with different profiles (default, desktop, kde, gnome and hardened too). I didn't want to submit a bug, just because I'm not sure it is. Here's the emerge --info for my current machine:

Portage 2.1.10.11 (default/linux/amd64/10.0/desktop/kde, gcc-4.6.1, glibc-2.13-r4, 2.6.39-gentoo-r4 x86_64)
=================================================================
System uname: Linux-2.6.39-gentoo-r4-x86_64-Intel-R-_Core-TM-_i3_CPU_550_@_3.20GHz-with-gentoo-2.0.3
Timestamp of tree: Thu, 01 Sep 2011 22:15:01 +0000
app-shells/bash:          4.2_p10
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.7.2-r2, 3.2-r2
dev-util/cmake:           2.8.5-r2
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.0.3
sys-apps/openrc:          0.9.0
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.68
sys-devel/automake:       1.9.6-r3, 1.10.3, 1.11.1-r1
sys-devel/binutils:       2.21.1-r1
sys-devel/gcc:            4.5.3-r1, 4.6.1-r1
sys-devel/gcc-config:     1.4.1-r1
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r1
sys-kernel/linux-headers: 2.6.39 (virtual/os-headers)
sys-libs/glibc:           2.13-r4
Repositories: gentoo kde x-Gentoo
ACCEPT_KEYWORDS="amd64 ~amd64 ~amd64-linux"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-Os -march=core2 -mpopcnt -msse4.2 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=4096 -mtune=generic -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CPPFLAGS="-Os -march=core2 -mpopcnt -msse4.2 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=4096 -mtune=generic -pipe"
CXXFLAGS="-Os -march=core2 -mpopcnt -msse4.2 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=4096 -mtune=generic -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer news nodoc noinfo noman parallel-fetch sandbox unmerge-logs unmerge-orphans userfetch userpriv usersandbox"
FFLAGS="-Os -march=core2 -mpopcnt -msse4.2 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=4096 -mtune=generic -pipe"
GENTOO_MIRRORS="http://mirror.switch.ch/ftp/mirror/gentoo/ ftp://mirror.switch.ch/mirror/gentoo/"
LANG="it_IT.UTF-8"
LC_ALL="it_IT.UTF-8"
LDFLAGS="-Wl,--as-needed"
LINGUAS="it"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_COMPRESS="xz"
PORTAGE_COMPRESS_FLAGS="-9e"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/kde"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="64bit X Xaw3d a52 aac accessibility acl acpi additions addressbook alsa amd64 ao apng archive asf audio avcodec avformat bash-completion berkdb bidi blksha1 bookmarks bzip2 cairo calendar caps cdda cddb cdr classic cli clucene common-lisp consolekit cracklib crashreporter cron crypt css curl cxx dbi dbus declarative device-mapper dga dirac djvu dts dvd dvdr embedded encode exceptions exif extensions faac ffmpeg fftw flac fontconfig fortran fts3 gcrypt gdbm geoip gif git glib glut gmp gnutls gphoto2 graphite gstreamer gtk gudev guile gzip hddtemp history hpn hunspell hwdb iconv icu id3tag idn imap inotify ipc ipv6 java jingle jit jpeg kde kdepim kexiv2 kipi kontact lame lapack lastfm latin1 lcms less libcanberra libedit libffi libnotify libsamplerate libssh2 libv4l2 lm_sensors lto lzma lzo mad marble matroska mdev media-library melt methodjit mime mjpeg mmap mms mmx mng modules mp3 mp4 mpeg msn mudflap multilib multimedia musepack mysql natspec ncurses net networking networkmanager nls nowlistening nptl nsplugin nss ntfsprogs ntp ogg okular openal openexr opengl openmp openrc optimisememory optimized-qmake orc pae pam pam_ssh pango pch pcre pdf perl phonon pic plasma player pm-utils png policykit posix postproc privacy profile profiling ps pulseaudio python python2 qt3support qt4 quicktime raptor raster readline realtime recursion-limit redeyes redland regex rtmp rtsp ruby sasl schroedinger sdl sdl-image sdlgfx secure-delete semantic-desktop sensord session sha512 sharedmem smp sndfile sound soundex speex spell sql sqlite sqlite3 sse sse2 sse3 sse4a ssh ssl ssse3 startup-notification stream subversion svg swscale symlink syslog system-sqlite sysvipc taglib tcpd theora threads threadsafe thumbnail thumbnails tiff track-src-odirect truetype twolame udev udisks unicode unlock-notify upower urandom usb uuid v4l2 vaapi vcd vcdx vdpau video virtuoso vorbis vpx wallpapers watchdog wav wavpack webdav webdav-neon webkit webm wma-fixed wmf x264 xattr xcb xinerama xml xmlpatterns xmp xmpp xorg xpm xv xvid xvmc zlib" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="ioplug plug rate" CALLIGRA_FEATURES="words" CAMERAS="ptp2" ELIBC="glibc" GRUB_PLATFORMS="pc" INPUT_DEVICES="evdev keyboard mouse" KERNEL="linux" LINGUAS="it" USERLAND="GNU" VIDEO_CARDS="nvidia"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_RSYNC_EXTRA_OPTS

Note that removing "-mpopcnt -msse4.2" and "--param" (some other packages had issues with it in the past) and/or using "-march=native" didn't change anything. Forcing linux_pam_version always works on all of my computers.
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2011-09-05 11:49:49 UTC
$ ver_str=$(qatom sys-libs/pam-1.1.3-r1 | cut -d ' ' -f 3)
$ echo ${ver_str//\./ }
1 1 3
$ printf "0x%02x%02x%02x" ${ver_str//\./ }
0x010103$

I don't see a problem here. But then, I can't find a sys-libs/pam-1.1.3-r1 ebuild anywhere either. Where did that come from?

In any case, this version finding scheme could be made a lot more robust, I guess.
Comment 4 Diego Elio Pettenò (RETIRED) gentoo-dev 2011-09-05 12:15:37 UTC
About version 1.1.3-r1: it was 1.1.3 plus NIS patch; since upstream released 1.1.4 that includes my NIS patch it was recently removed.

As Jeroen points out, it had to work fine with -r1 as well (since the revision is split from the version in qatom's output). While I _could_ work on it to make it more solid, any extra time I have to work on PAM I would rather employ to work on the new code based on m4 rather than cpp.

But... your system seems very much hosed: why are you accepting ~amd64-linux (which is the prefix keyword)? Why are you messing with CPPFLAGS _at all_? Optimisations are useless there.

I'd suggest you to reinstall your system without trying to messing around with vars you don't really seem to know how to use.
Comment 5 Federico Moretti 2011-09-06 09:50:14 UTC
(In reply to comment #4)
> About version 1.1.3-r1: it was 1.1.3 plus NIS patch; since upstream released
> 1.1.4 that includes my NIS patch it was recently removed.
> 
> As Jeroen points out, it had to work fine with -r1 as well (since the revision
> is split from the version in qatom's output). While I _could_ work on it to
> make it more solid, any extra time I have to work on PAM I would rather employ
> to work on the new code based on m4 rather than cpp.
> 
> But... your system seems very much hosed: why are you accepting ~amd64-linux
> (which is the prefix keyword)? Why are you messing with CPPFLAGS _at all_?
> Optimisations are useless there.
> 
> I'd suggest you to reinstall your system without trying to messing around with
> vars you don't really seem to know how to use.

I've removed the CPPFLAGS variable, that's a good start point, but sys-auth/pambase-20101024 blocked again... 'till I manually modify the ebuild to reflect the right PAM system and version: I see it has been updated to 1.1.4 and it didn't change anything. That emerge --info was taken by a testing system (I was trying GNOME 3.2 which is scheduled to be released in a few weeks), so as I said it wasn't really accurate to show my problem. I tried with a netbook without that keyword and/or strange variables such as CPPFLAGS, etc. but I got the same results. Removed that piece of code, sys-auth/pambase-20101024 compiles correctly. I preferred to ask a dumb question on the forums, before to submit a dumb bug request, because I wasn't sure (neither I am) that's really a bug. And I was able to found a workaround by myself. BTW, nothing has changed yet. Don't know why!



PS - I've included ~amd64-linux 'cause I thought it was necessary to distinguish Linux between FreeBSD, I'm back on Gentoo after some years and I'm not so used anymore.
Comment 6 Federico Moretti 2011-09-06 09:53:00 UTC
(In reply to comment #3)
> $ ver_str=$(qatom sys-libs/pam-1.1.3-r1 | cut -d ' ' -f 3)
> $ echo ${ver_str//\./ }
> 1 1 3
> $ printf "0x%02x%02x%02x" ${ver_str//\./ }
> 0x010103$
> 
> I don't see a problem here. But then, I can't find a sys-libs/pam-1.1.3-r1
> ebuild anywhere either. Where did that come from?
> 
> In any case, this version finding scheme could be made a lot more robust, I
> guess.

Maybe, the problem is on my systems' configuration: I really can't understand why, but forcing those variables I get the ebuild compiled everywhere and fine!
Comment 7 Diego Elio Pettenò (RETIRED) gentoo-dev 2011-09-06 10:07:26 UTC
What happens when you run the commands on the commandline one by one as Jeroen did?

There is really no way this should not work, afaict.
Comment 8 v2k 2012-03-30 22:49:36 UTC
This still occurs. I'm getting this too on a fresh linode server.  I've tried 32 bit and 64 bit.

emerge --sync & emerge --update --deep --with-bdeps=y --newuse world

(or any similar update method)

hangs here: 

http://paste.pocoo.org/show/573740/

info:
http://slexy.org/view/s2NJp0PZDt
Comment 9 dignan 2012-04-01 04:46:53 UTC
This is happening for me when I do emerge -uDN world on a new Gentoo installation. 

I tried to run the following command, but it hangs:

ver_str=$(qatom sys-libs/pam-1.1.3-r1 | cut -d ' ' -f 3)