View previous topic :: View next topic |
Author |
Message |
caseyf n00b
Joined: 25 Sep 2002 Posts: 8 Location: La Vergne, TN
|
Posted: Wed Sep 25, 2002 9:41 pm Post subject: gentoo 1.4-rc1 trouble with scripts/bootstrap.sh |
|
|
Specifically running the bootstrap script when sysvinit is compiled. I've chrooted to the 1.4 environment on a spare drive from my 1.2 install using the following:
mkreiserfs /dev/hdd1
mkreiserfs /dev/hdd2
mount /dev/hdd2 /mnt/lfs #old mount point
mkdir /mnt/lfs/boot
mount /dev/hdd1 /mnt/lfs/boot -o notail
cd /mnt/lfs
tar -xvjpf /root/stage1-x86-1.4_rc1.tar.bz
mount -o bind /proc /mnt/lfs/proc
cp /etc/resolv.conf /mnt/lfs/etc/resolv.conf
chroot /mnt/lfs /bin/bash
env-update
source /etc/profile
emerge sync
nano -w /etc/make.conf # CFLAGS="-march=i686 -O3 -pipe"
cd /usr/portage
scripts/bootstrap.sh
Results in a couple of hours worth of compilation followed by:
>>> emerge sys-apps/baselayout-1.8.3 to /
>>> md5 sysvinit-2.84.tar.gz
>>> Unpacking source...
>>> Unpacking sysvinit-2.84.tar.gz
>>> Unpacking rc-scripts-1.4.0.tar.bz2
>>> Source unpacked.
cc -c -Wall -march=i686 -O3 -pipe -D_GNU_SOURCE init.c
cc -c -Wall -march=i686 -O3 -pipe -D_GNU_SOURCE -DINIT_MAIN utmp.c -o init_utmp.o
utmp.c: In function `write_wtmp':
utmp.c:56: `_PATH_WTMP' undeclared (first use in this function)
utmp.c:56: (Each undeclared identifier is reported only once
utmp.c:56: for each function it appears in.)
utmp.c: In function `write_utmp':
utmp.c:120: `_PATH_UTMP' undeclared (first use in this function)
make: *** [init_utmp.o] Error 1
make: *** Waiting for unfinished jobs....
init.c: In function `init_main':
init.c:2368: `_PATH_UTMP' undeclared (first use in this function)
init.c:2368: (Each undeclared identifier is reported only once
init.c:2368: for each function it appears in.)
init.c:2439: warning: no return statement in function returning non-void
make: *** [init.o] Error 1
!!! ERROR: The ebuild did not complete successfully.
!!! Function src_compile, Line 14, Exitcode 2
!!! problem compiling sysvinit
Any clues where I screwed up here? Still fairly new to linux, go easy.
Thanks. |
|
Back to top |
|
|
caseyf n00b
Joined: 25 Sep 2002 Posts: 8 Location: La Vergne, TN
|
Posted: Wed Sep 25, 2002 9:50 pm Post subject: |
|
|
A clue: There is a paths.h in sysvinit's source dir, but _PATH_UTMP is defined in /usr/include/paths.h
How do I make /usr/include searched before ./ ? |
|
Back to top |
|
|
rac Bodhisattva
Joined: 30 May 2002 Posts: 6553 Location: Japanifornia
|
Posted: Wed Sep 25, 2002 9:54 pm Post subject: |
|
|
caseyf wrote: | How do I make /usr/include searched before ./ ? |
Strange that you should have to do it, but adding "-I-" to the gcc command line might do what you want. See http://gcc.gnu.org/onlinedocs/gcc/Directory-Options.html for more. _________________ For every higher wall, there is a taller ladder |
|
Back to top |
|
|
caseyf n00b
Joined: 25 Sep 2002 Posts: 8 Location: La Vergne, TN
|
Posted: Wed Sep 25, 2002 10:01 pm Post subject: |
|
|
rac wrote: | Strange that you should have to do it, but adding "-I-" to the gcc command line... |
Very strange if someone want to rebuild sysvinit and post the output that would be interesting. I compiled init.c with
cc -c -Wall -march=i686 -O3 -pipe -D_GNU_SOURCE init.c -save-temps
and looked at the .i file. Sure enough utmp.h includes the local paths.h
# 1 "/usr/include/bits/utmp.h" 1 3
# 24 "/usr/include/bits/utmp.h" 3
# 1 "paths.h" 1 3
BTW -I- doesn't help
cc -c -Wall -march=i686 -O3 -pipe -D_GNU_SOURCE init.c -I-
gives
init.c: In function `init_main':
init.c:2368: `_PATH_UTMP' undeclared (first use in this function)
init.c:2368: (Each undeclared identifier is reported only once
init.c:2368: for each function it appears in.)
init.c:2439: warning: no return statement in function returning non-void |
|
Back to top |
|
|
caseyf n00b
Joined: 25 Sep 2002 Posts: 8 Location: La Vergne, TN
|
Posted: Wed Sep 25, 2002 10:21 pm Post subject: |
|
|
Got it. I think. I had CPATH set to something other than "" in my .bashrc file. Even though ./ isn't mentioned, it's still finds paths.h there before /usr/include. Go figure. |
|
Back to top |
|
|
|