LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (https://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   build error (https://www.linuxquestions.org/questions/linux-from-scratch-13/build-error-457172/)

Youri 06-22-2006 04:05 AM

build error
 
hi all, first of all this is my 3rd lfs build im going to make. i made it 2 time on a slack (9.1 and 10.0) host. worked like a charm. but...

now im trying to compile it on an amd64 with ubuntu64 dapper on it gcc version is 4.0.3 (ubuntu's own version)
when i set up my distro to function as a host for another lfs build (its an laptop btw) i get the following error
Code:

/usr/bin/ld: skipping incompatible /usr/lib/../lib/libc.so when searching for -lc
/usr/bin/ld: skipping incompatible /usr/lib/../lib/libc.a when searching for -lc
/usr/bin/ld: skipping incompatible /usr/bin/../lib/libc.so when searching for -lc
/usr/bin/ld: skipping incompatible /usr/bin/../lib/libc.a when searching for -lc
/usr/bin/ld: skipping incompatible /usr/lib/libc.so when searching for -lc
/usr/bin/ld: skipping incompatible /usr/lib/libc.a when searching for -lc
/usr/bin/ld: cannot find -lc
collect2: ld returned 1 exit status
make[3]: *** [32/libgcc_s_32.so] Error 1
make[3]: Leaving directory `/mnt/lfs/sources/gcc-3.4.3/gcc'
make[2]: *** [stmp-multilib] Error 2
make[2]: Leaving directory `/mnt/lfs/sources/gcc-3.4.3/gcc'
make[1]: *** [stage1_build] Error 2
make[1]: Leaving directory `/mnt/lfs/sources/gcc-3.4.3/gcc'
make: *** [bootstrap] Error 2
 when compiling gcc-3.4.3

now i know i didnt give ANY parameters with the configure script with this output but i get the exact same error message when doing it as the book says. now wat is the problem here??

/proc/version = Linux version 2.6.15-25-amd64-generic (buildd@king) (gcc version 4.0.3 (Ubuntu 4.0.3-1ubuntu5)) #1 SMP PREEMPT Wed Jun 14 11:28:03 UTC 2006
for who's interested

Daws 06-23-2006 06:29 PM

Incompatible libc...

I am guessing that the amd64 arch itself is your problem. Correct me if I'm wrong but at the moment LFS shouldn't work for amd64. I think the CLFS project is the one you need to be reading instead.

Youri 06-24-2006 03:45 PM

ok ill try that one out.

thanks

Youri 06-25-2006 09:42 AM

oke now im following clfs for x86_64 but when i try to build glibc i get the following error

Code:

make -r PARALLELMFLAGS="" CVSOPTS="" -C ../glibc-2.4 objdir=`pwd` all
make[1]: Entering directory `/mnt/lfs/sources/glibc-2.4'
mawk -f scripts/gen-sorted.awk \
              -v subdirs='csu assert ctype locale intl catgets math setjmp signal stdlib stdio-common libio malloc string wcsmbs time dirent grp pwd posix io termios resource misc socket sysvipc gmon gnulib iconv iconvdata wctype manual shadow po argp crypt nss localedata timezone rt conform debug  dlfcn elf' \
              -v srcpfx='' \
              nptl/sysdeps/pthread/Subdirs sysdeps/unix/inet/Subdirs sysdeps/unix/Subdirs assert/Depend intl/Depend catgets/Depend stdlib/Depend stdio-common/Depend libio/Depend malloc/Depend string/Depend wcsmbs/Depend time/Depend posix/Depend iconvdata/Depend nss/Depend localedata/Depend rt/Depend debug/Depend > /mnt/lfs/sources/glibc-build/sysd-sorted-tmp
mawk: scripts/gen-sorted.awk: line 19: regular expression compile failed (bad class -- [], [^] or [)
/[^
mawk: scripts/gen-sorted.awk: line 19: syntax error at or near ]
mawk: scripts/gen-sorted.awk: line 19: runaway regular expression /, "", subd ...
make[1]: *** No rule to make target `/mnt/lfs/sources/glibc-build/Versions.all', needed by `/mnt/lfs/sources/glibc-build/abi-versions.h'.  Stop.
make[1]: Leaving directory `/mnt/lfs/sources/glibc-2.4'
make: *** [all] Error 2


rojoblandino 11-23-2007 10:35 PM

The same for me
 
Quote:

Originally Posted by Youri (Post 2307128)
oke now im following clfs for x86_64 but when i try to build glibc i get the following error

Code:

make -r PARALLELMFLAGS="" CVSOPTS="" -C ../glibc-2.4 objdir=`pwd` all
make[1]: Entering directory `/mnt/lfs/sources/glibc-2.4'
mawk -f scripts/gen-sorted.awk \
              -v subdirs='csu assert ctype locale intl catgets math setjmp signal stdlib stdio-common libio malloc string wcsmbs time dirent grp pwd posix io termios resource misc socket sysvipc gmon gnulib iconv iconvdata wctype manual shadow po argp crypt nss localedata timezone rt conform debug  dlfcn elf' \
              -v srcpfx='' \
              nptl/sysdeps/pthread/Subdirs sysdeps/unix/inet/Subdirs sysdeps/unix/Subdirs assert/Depend intl/Depend catgets/Depend stdlib/Depend stdio-common/Depend libio/Depend malloc/Depend string/Depend wcsmbs/Depend time/Depend posix/Depend iconvdata/Depend nss/Depend localedata/Depend rt/Depend debug/Depend > /mnt/lfs/sources/glibc-build/sysd-sorted-tmp
mawk: scripts/gen-sorted.awk: line 19: regular expression compile failed (bad class -- [], [^] or [)
/[^
mawk: scripts/gen-sorted.awk: line 19: syntax error at or near ]
mawk: scripts/gen-sorted.awk: line 19: runaway regular expression /, "", subd ...
make[1]: *** No rule to make target `/mnt/lfs/sources/glibc-build/Versions.all', needed by `/mnt/lfs/sources/glibc-build/abi-versions.h'.  Stop.
make[1]: Leaving directory `/mnt/lfs/sources/glibc-2.4'
make: *** [all] Error 2


I am a Nicaraguan student, i speak spanish, for that reason excuse me if I write in wrong ways, or if I offend somebody because our difference between cultural writing.

Hello there, I am doing the same thing and I had the same error, I am working on Debian, but that should not be the problem!

There is somebody, who knows how to fix it?

I tried to fix it being root but it did not work at all, I tried to make it all again and it still is not working!

After all, is not so easy as the LFS book says!

Ok, see you and I hope an answer like Yuri!

gerald_M2B 11-23-2007 11:23 PM

rojoblandino:
I also wish you would see an answer like Youri. Please consider this while you await such a post.

In the LFS book, there were awk scripts. It was my experience that mawk does not work, but gawk does.
In accord with my experience I suggest that you try gawk anyway, in place of mawk when the script does
not produce a favorable result.
gawk is available from http://ftp.gnu.org/pub/gnu/gawk/ and its mirrors.

Gerald

cigital 11-24-2007 06:50 PM

i think you should use the gcc which lfslivecd provided。
may be new version gcc cause this problem。

dwhitney67 11-24-2007 07:07 PM

Quote:

Originally Posted by gerald_M2B (Post 2969014)
rojoblandino:
I also wish you would see an answer like Youri. Please consider this while you await such a post.

In the LFS book, there were awk scripts. It was my experience that mawk does not work, but gawk does.
In accord with my experience I suggest that you try gawk anyway, in place of mawk when the script does
not produce a favorable result.
gawk is available from http://ftp.gnu.org/pub/gnu/gawk/ and its mirrors.

Gerald

I agree. The same with bash, in lieu of Ubuntu's dash.

emdog4 06-12-2008 01:50 PM

Hi!

I had this same problem using the x86 version of Ubuntu (7.04). I solved this problem by installing GAWK, as mawk was installed and it wasn't working right. On Ubuntu you can install gawk by simply doing
Code:

sudo apt-get install gawk
. hope that helps, thanks for the suggestions!

Emery

noone_important 08-11-2008 07:25 PM

I was using a vanilla installation of DSL, and installing gawk instead of mawk did the trick for me as well, with one gotcha: the mydsl package for awk installs to /opt/awk/bin. Setting up the PATH was not enough (even removing /usr/bin from path didn't help), and I found /usr/bin/{g,}awk hard coded into some spots for some dumb reason. So, to keep others from getting headaches, do this as well once you install gawk on DSL

(note: on DSL, /usr/bin/{g,}awk are just symlinks to mawk)

# rm /usr/bin/{g,}awk
# ln -s /opt/awk/bin/awk /usr/bin
# ln -s /opt/awk/bin/gawk /usr/bin

Why that was necessary is completely beyond me (and a little disappointing, as you can't get more unix than gnu's c compiler, and that being in the sources just makes me want to kick something), but it worked, so I'm not going to lose any more sleep over it

sdemsc 05-24-2011 07:37 AM

thanks
 
Thanks installing gawk worked for me

EnemyNL 09-24-2011 08:27 AM

Thanks, installing gawk also fixed this error for me, i did have to redo ../glibc-2.13/configure again before it worked.

devilboy09 11-07-2011 01:42 AM

i've already installed gawk but i still can't make it

devilboy09 11-07-2011 01:46 AM

should i remove mawk?
i installed both(mawk and gawk)

druuna 11-07-2011 03:32 AM

Hi,
Quote:

Originally Posted by devilboy09
I've already installed gawk but i still can't make it

Quote:

Originally Posted by devilboy09
should i remove mawk?
i installed both(mawk and gawk)

awk should point to gawk (ls -l $(which awk) to check) and not to mawk.

You don't mention which distro you are using, so the easiest way is probably to remove mawk (and check afterwards if awk now points to gawk).

Hope this helps.

devilboy09 11-07-2011 06:27 AM

i removed mawk and installed gawk and it worked
thank you for your help


All times are GMT -5. The time now is 07:44 PM.