Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 206781 - bootstrap failure popt
Summary: bootstrap failure popt
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo non-Linux Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-01-20 15:01 UTC by Rabbe Fogelholm
Modified: 2008-02-02 17:35 UTC (History)
1 user (show)

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


Attachments
config.log (config.log,45.67 KB, text/plain)
2008-01-20 21:23 UTC, Rabbe Fogelholm
Details
make patch applyable unconditionally (popt-update-wchar.patch,919 bytes, patch)
2008-02-01 15:50 UTC, Markus Duft (RETIRED)
Details | Diff
popt cleanup (popt-update-2.patch,3.21 KB, patch)
2008-02-01 16:03 UTC, Markus Duft (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Rabbe Fogelholm 2008-01-20 15:01:25 UTC
Platform: SUSE 10 SP1
Webpage version: 9 January, 2008

During bootstrapping the emerge of dev-libs/popt-1.13 failed. This package is pulled in by the first `emerge -e system' command (package 9 of 67). The following was seen in the console output:

gcc -Wall -g -O2 -Wl,-rpath=/local/tmp/nightly/2008-01-20/usr/lib -Wl,-rpath=/local/tmp/nightly/2008-01-20/lib -o .libs/test1 test1.o  -liconv -L/local/tmp/nightly/2008-01-20/usr/lib -L/local/tmp/nightly/2008-01-20/lib ./.libs/libpopt.so  -Wl,--rpath -Wl,/local/tmp/nightly/2008-01-20/usr/lib
/usr/lib/gcc/i586-suse-linux/4.1.2/../../../../i586-suse-linux/bin/ld: cannot find -liconv
collect2: ld returned 1 exit status
make[2]: *** [test1] Error 1
make[2]: Leaving directory `/local/scratch/portage/dev-libs/popt-1.13/work/popt-1.13'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/local/scratch/portage/dev-libs/popt-1.13/work/popt-1.13'
make: *** [all] Error 2
 * 
 * ERROR: dev-libs/popt-1.13 failed.
 * Call stack:
 *               ebuild.sh, line   46:  Called src_compile
 *             environment, line 2371:  Called die
 * The specific snippet of code:
 *       emake || diefunc "$FUNCNAME" "$LINENO" "$?" "emake failed"
 *  The die message:
 *   emake failed
Comment 1 Fabian Groffen gentoo-dev 2008-01-20 15:29:33 UTC
can you please post your config.log for popt?
Comment 2 Rabbe Fogelholm 2008-01-20 21:23:10 UTC
Created attachment 141396 [details]
config.log
Comment 3 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2008-01-21 14:58:26 UTC
grobian,
Same issue here. The patch you submitted, fixed compilation on solaris but apparently broke it on linux. Both USE=nls and USE=-nls fail with the same issue as described.

"cannot find -liconv"
Comment 4 Fabian Groffen gentoo-dev 2008-01-21 16:27:38 UTC
Which is not so weird, as linux doesn't need a libiconv, it's included in glibc.  However for some reason configure appears to think -liconv is necessary on Linux, which means the AM_ICONV macro sucks.
Comment 5 Fabian Groffen gentoo-dev 2008-01-21 17:04:47 UTC
I committed a fix which allowed me to compile on linux.  Will test on Solaris again to see if it works fine there too.

Please test.

Won't close this bug until I uploaded a new bootstrap image.
Comment 6 Fabian Groffen gentoo-dev 2008-01-21 17:07:51 UTC
solaris with USE="-nls" still compiles for me still, so it looks like my fix is promising
Comment 7 Michael Haubenwallner (RETIRED) gentoo-dev 2008-01-23 10:34:19 UTC
Well, this fix broke Interix completely.

One thing is that eautoreconf requires gettext.m4 (provided by gettext),
which need not to be there for USE=-nls, as well as during bootstrap...

Another is that eautoreconf (during bootstrap) does not work without setting AT_M4DIR="m4" ...

For interix, we only needed to drop the AC_CHECK_FUNCS(... iconv) - which looks for iconv() without <iconv.h> - but avoid eautoreconf.
Comment 8 Markus Duft (RETIRED) gentoo-dev 2008-01-23 10:39:45 UTC
(In reply to comment #7)
> Well, this fix broke Interix completely.

the strange thing is, that when not doing eautoreconf, configure doesn't fail when not finding xgettext, but after eautoreconf, it does....
Comment 9 Michael Haubenwallner (RETIRED) gentoo-dev 2008-01-23 10:57:55 UTC
http://overlays.gentoo.org/proj/alt/changeset/15928
fixes this specifically for interix.
Eventually this same fix also works for solaris and linux during bootstrap ?
Comment 10 Fabian Groffen gentoo-dev 2008-01-23 11:28:36 UTC
I don't like your patch.

Let me explain why I did what I did.

1) Solaris (Darwin, AIX too I presume) don't have iconv in their libc, however, without USE=nls the make script thinks that you can use iconv without any libs
2) On linux, AM_ICONV thinks that to link to iconv, you need -liconv, which is really wrong

for 1) I just added LTICONV to the Makefile
for 2) I used AM_ICONV_LINK or something, because that one /does/ figure out that on Linux you don't need any lib for iconv stuff

a) I don't know/recall where in the process popt is pulled in, but I thought it was just a dep of rsync somewhere, so it should come after all autoconf and stuff are pulled inside the prefix.  Why can't we run eautoreconf for it?
b) my patching may be wrong, and we can include the m4 dir so we don't need gettext upfront
Comment 11 Fabian Groffen gentoo-dev 2008-01-31 09:07:18 UTC
I created a new snapshot with haubi's patch, so hopefully it works during bootstrap again now.
Comment 12 Rabbe Fogelholm 2008-02-01 08:34:48 UTC
I ran a bootstrapping attempt on SUSE 10 early this morning but it did not succeed. Maybe this is a new problem and we should open a new bug. The `emerge --oneshot bash' step fails because of the texinfo dependency (package 6 out of 15 pulled in by bash).

The final part of the console log goes

rm -rf $backupdir; exit $rc
/bin/sh /local/scratch/portage/sys-apps/texinfo-4.11-r1/work/texinfo-4.11/build-aux/missing --run help2man --name="convert Texinfo documents to DVI" ../util/texi2dvi >texi2dvi.1
help2man: can't get `--help' info from ../util/texi2dvi
make[2]: *** [texi2dvi.1] Error 1
make[2]: Leaving directory `/local/scratch/portage/sys-apps/texinfo-4.11-r1/work/texinfo-4.11/doc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/local/scratch/portage/sys-apps/texinfo-4.11-r1/work/texinfo-4.11'
make: *** [all] Error 2
 * ERROR: sys-apps/texinfo-4.11-r1 failed:
Comment 13 Fabian Groffen gentoo-dev 2008-02-01 08:57:57 UTC
bug recycling...

@markus, I take it you're not interested in this, if you are readd yourself.
Comment 14 Markus Duft (RETIRED) gentoo-dev 2008-02-01 09:11:46 UTC
(In reply to comment #13)
> bug recycling...
> @markus, I take it you're not interested in this, if you are readd yourself.

thanks, and yes, texinfo is working fine on interix ;)
Comment 15 Fabian Groffen gentoo-dev 2008-02-01 10:32:18 UTC
I added a dep on help2man to texinfo, as it bugs us too much.  I'm currently bootstrappign from scratch and had the same issue on OSX.  I noticed that the dependencies for bash (16 packages!) are quite different than before, so expect the bootstrap guide to change soon.
Comment 16 Fabian Groffen gentoo-dev 2008-02-01 14:46:40 UTC
% less /Library/Gentoo/var/tmp/portage/dev-libs/popt-1.13/temp/autoconf-26301.out
***** autoconf *****

configure.ac:97: error: possibly undefined macro: AM_GNU_GETTEXT
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
configure.ac:98: error: possibly undefined macro: AM_ICONV_LINK


Damn.
Comment 17 Fabian Groffen gentoo-dev 2008-02-01 15:08:20 UTC
texinfo problem is fixed, popt issue remains.

@markus: in the interix wchar patch, can it be made unconditional by using something like #ifdef __INTERIX?

I want to clean up this popt mess a lot now, I dislike the conditional patching a lot.
Comment 18 Fabian Groffen gentoo-dev 2008-02-01 15:11:53 UTC
(In reply to comment #8)
> (In reply to comment #7)
> > Well, this fix broke Interix completely.
> 
> the strange thing is, that when not doing eautoreconf, configure doesn't fail
> when not finding xgettext, but after eautoreconf, it does....
> 

this is becasue the scrub-lame-gettext patch simply only patches configure, and since it seems to be a very early bootstrap dependency, I guess we should keep it from autoreconfing as well.
Comment 19 Markus Duft (RETIRED) gentoo-dev 2008-02-01 15:50:13 UTC
(In reply to comment #17)
> texinfo problem is fixed, popt issue remains.
> @markus: in the interix wchar patch, can it be made unconditional by using
> something like #ifdef __INTERIX?
> I want to clean up this popt mess a lot now, I dislike the conditional patching
> a lot.

jap, sure.... one has to just wrap the line i removed with #ifndef __INTERIX instead. i attached a tree patch, since i dont know, when haubi will be online to apply it again.
Comment 20 Markus Duft (RETIRED) gentoo-dev 2008-02-01 15:50:49 UTC
Created attachment 142412 [details, diff]
make patch applyable unconditionally
Comment 21 Fabian Groffen gentoo-dev 2008-02-01 15:56:44 UTC
Markus, could you please sync and try the latest popt-1.13 if it works for Interix?  (USE=-nls should work as nothing changed for Interix.)

I cleaned it up a lot.  On Darwin during bootstrap (USE=-nls) it works.  Theoretically this should work everywhere, and also with nls set, but I'll keep my fingers crossed.

Thanks for your unconditional patch, I applied it!
Comment 22 Markus Duft (RETIRED) gentoo-dev 2008-02-01 16:03:12 UTC
arg, i love mid-air collisions ;)

what i wanted to write:

ok, i thought a while about this ;) i have it working now, even with
eautoreconf, if you want to leave it in. all patches are unconditional now.
again i'll attach my proposed tree patch here, because i still don't know when
haubi will be online to apply...


i will attach it anyway and try again after synching....
Comment 23 Markus Duft (RETIRED) gentoo-dev 2008-02-01 16:03:33 UTC
Created attachment 142414 [details, diff]
popt cleanup
Comment 24 Markus Duft (RETIRED) gentoo-dev 2008-02-01 16:06:42 UTC
(In reply to comment #21)
> Markus, could you please sync and try the latest popt-1.13 if it works for
> Interix?  (USE=-nls should work as nothing changed for Interix.)
[snip]

works fine from current svn now.

Comment 25 Fabian Groffen gentoo-dev 2008-02-01 16:07:19 UTC
ah, indeed.  That would have been the way to go if we didn't have this autoreconf restriction.  Because this package is really deep down in the bootstrap scene, we don't want to autoconf for it, so we have to stick with patching configure.

I eventually used the interix patch you made, as that works for others too (hopefully).
Comment 26 Fabian Groffen gentoo-dev 2008-02-01 16:07:40 UTC
(In reply to comment #24)
> (In reply to comment #21)
> > Markus, could you please sync and try the latest popt-1.13 if it works for
> > Interix?  (USE=-nls should work as nothing changed for Interix.)
> [snip]
> 
> works fine from current svn now.
> 

Thanks.  Let's hope this is it then...
Comment 27 Rabbe Fogelholm 2008-02-02 11:49:14 UTC
I am still getting the same failure as described in Comment#12 (the host is SUSE 10 SP1).

The console logs look very similar when I compare the ones from today (very early in the morning, 01:00 Stockholm wintertime) and yesterday. The date encoded in bootstrap_tree() is also the same (20080130). Hope I'm not doing the wrong thing here but since the failure persists I am reopening.
Comment 28 Fabian Groffen gentoo-dev 2008-02-02 11:52:17 UTC
I didn't release a new snapshot.  I do that after I finish bootstrapping Darwin 10.4
Comment 29 Fabian Groffen gentoo-dev 2008-02-02 17:35:39 UTC
new bootstrap image uploaded.  The bootstrap procedure needs to be changed, roughly like this after the bootstrap-prefix $EPREFIX/tmp stuff:


      -1 sed
   1.
      -1 --nodeps bash
   2.
                  wget
   3.
      -1 coreutils (17 pkgs)
   4.
         findutils
   5.
         tar
   6.
         grep
   7.
         gawk
   8.
         portage (12 pkgs)
   9.
         baselayout-prefix
  10.
       
  11.
      rm tmp
  12.
       
  13.
      -1 subversion
  14.
      --sync
  15.
      -u system (does the remaining pkgs + compiler)
  16.
       
  17.
      set up make.conf, unset LDFLAGS, CPPFLAGS
  18.
       
  19.
      emerge -e system
  20.
       
  21.
      startscript

I'm working on the guides