Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
04-07-2011, 06:19 AM
|
#1
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Rep:
|
strucking gcc-4.5.1-pass2(lfs-6.7)
hi all
i am using lfslivecd
5.10. GCC-4.5.1 - Pass 2(lfs-6.7-pageno-46)
-------------------------------
for file in \
$(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
do
cp -uv $file{,.orig}
sed -e 's@/lib\(64\)\?\(32\)\?/ld@/tools&@g' \
-e 's@/usr@/tools@g' $file.orig > $file
echo '
#undef STANDARD_INCLUDE_DIR
#define STANDARD_INCLUDE_DIR 0
#define STANDARD_STARTFILE_PREFIX_1 ""
#define STANDARD_STARTFILE_PREFIX_2 ""' >> $file
touch $file.orig
done
--------------------------------------------
lfs:/mnt/lfs/sources$ tar -jxf gcc-4.5.1.tar.bz2
lfs:/mnt/lfs/sources$ cd gcc-4.5.1
lfs:/mnt/lfs/sources/gcc-4.5.1$ patch -Np1 -i ../gcc-4.5.1-startfiles_fix-1.patch
patching file gcc/gcc.c
Hunk #1 succeeded at 7083 with fuzz 1 (offset 713 lines).
lfs:/mnt/lfs/sources/gcc-4.5.1$ cp -v gcc/Makefile.in{,.orig}
`gcc/Makefile.in' -> `gcc/Makefile.in.orig'
lfs:/mnt/lfs/sources/gcc-4.5.1$ sed 's@\./fixinc\.sh@-c true@' gcc/Makefile.in.orig > gcc/Makefile.in
lfs:/mnt/lfs/sources/gcc-4.5.1$ cp -v gcc/Makefile.in{,.tmp}
`gcc/Makefile.in' -> `gcc/Makefile.in.tmp'
lfs:/mnt/lfs/sources/gcc-4.5.1$ sed 's/^T_CFLAGS =$/& -fomit-frame-pointer/' gcc/Makefile.in.tmp \
> > gcc/Makefile.in
lfs:/mnt/lfs/sources/gcc-4.5.1$ $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
bash: gcc/config/cris/linux.h: Permission denied
this is 3 rd time i am facing problem
plz help
|
|
|
04-07-2011, 06:31 AM
|
#2
|
Senior Member
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,314
|
It would help a little bit if you said what you were trying to do.
It looks like you are trying to build gcc in /mnt/lfs/sources
Is this writeable media?
What do you get when you do this?
Code:
ls -l /mnt/lfs/sources/gcc/config/cris/linux.h
|
|
|
04-07-2011, 09:37 AM
|
#3
|
LQ Veteran
Registered: Sep 2003
Posts: 10,532
|
Hi,
I noticed you had previous "permission denied" messages (not only for gcc, but also for binutils).
A few things that come to mind:
- Are you sure you used the lfs user for _all_ the previous steps in chapter 5?
- Did you remove the source tree after doing gcc pass 1?
Hope this helps.
|
|
|
04-08-2011, 12:14 AM
|
#4
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
thanks for reply druuna
A few things that come to mind:
- Are you sure you used the lfs user for _all_ the previous steps in chapter 5?
ans:yes i am in lfs usr all previous steps in chapter 5(means lfs:/mnt/lfs)
- Did you remove the source tree after doing gcc pass 1?
yes i removed sources dir,build dir after first gcc pass 1
in second pass i untared gcc pkg,i entered the gcc source dir
lfs:/mnt/lfs$ $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
its coming here permission denied
if want any info i will
|
|
|
04-08-2011, 01:38 AM
|
#5
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
hi smallpond
What do you get when you do this?
ls -l /mnt/lfs/sources/gcc/config/cris/linux.h[/CODE][/QUOTE]
reslut following
ls:cannot access /mnt/lfs/sources/gccc/cris/linux.h:no such file or directory
|
|
|
04-08-2011, 01:47 AM
|
#6
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
hi druuna
this time i got diff
have a look
see post 1
lfs:/mnt/lfs/sources/gcc-4.5.1$ $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
bash: gcc/config/cris/linux.h: Permission denied
-------------------------------------------------------------------
i did fresh from starting
see new result
lfs:/mnt/lfs/sources/gcc-4.5.1$ $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
bash: gcc/config/i386/sysv4.h: Permission denied
i hope this will,u can give soltution now
why i am getting diff (when i start fresh)
thanks
|
|
|
04-08-2011, 02:15 AM
|
#7
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
hi druuna
this may be helpful
lfs:/mnt/lfs/sources$ls -la
drwxr-xr-x 27 lfs lfs 4096 Jul 31 2010 gcc-4.5.1
-rw-rw-r-- 1 lfs 1000 1446 Sep 18 2010 gcc-4.5.1-startfiles_fix-1.patch
-rw-rw-r-- 1 lfs 1000 66121821 Sep 18 2010 gcc-4.5.1.tar.bz2
something i am missing
one bit doubt does find command wont work without parenthisis()
|
|
|
04-08-2011, 03:19 AM
|
#8
|
LQ Veteran
Registered: Sep 2003
Posts: 10,532
|
Hi,
What are you actually doing?
The following is one command:
Code:
for file in \
$(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
do
.
.
done
The above code can also be written as:
Code:
for file in $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
do
.
.
done
Only executing the $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h) part will _not_ work (you'll get a Permission Denied message in this specific case).
This find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h would work, but that is not what is in the book and not what was intended.
Like I stated many times before: You should follow the book. Copy and paste these commands to make sure you do not make any mistakes.
Hope this helps.
|
|
|
04-08-2011, 03:56 AM
|
#9
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
hi druuna
1)sorry for that i miss undurstood
really i didnt get this step now
The following is one command k,
but ,where i have to run this step(commands)
i should not skip this step right?
------------------------------------------------------------
for file in $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
do
.
.
done
-------------------------------------------------------------
before doing this step i should not move to pgno-47 (furhter) right
can u explain in detail about this step only
plz
|
|
|
04-08-2011, 04:14 AM
|
#10
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
hi druuna,i think i got it
i simply copy and pasted
why i confused here that 'for file' word
lfs:/mnt/lfs/sources$ for file in \
> $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
> do
> cp -uv $file{,.orig}
> sed -e 's@/lib\(64\)\?\(32\)\?/ld@/tools&@g' \
> -e 's@/usr@/tools@g' $file.orig > $file
> echo '
> #undef STANDARD_INCLUDE_DIR
> #define STANDARD_INCLUDE_DIR 0
> #define STANDARD_STARTFILE_PREFIX_1 ""
> #define STANDARD_STARTFILE_PREFIX_2 ""' >> $file
> touch $file.orig
> done
thanku so much
|
|
|
04-08-2011, 05:42 AM
|
#11
|
Member
Registered: Jan 2011
Location: mangalore
Distribution: ubuntu
Posts: 167
Original Poster
Rep:
|
hi druuna
here i am giving what i got
lfs:/mnt/lfs/sources/gcc-4.5.1$ for file in \
> $(find gcc/config -name linux64.h -o -name linux.h -o -name sysv4.h)
> do
> cp -uv $file{,.orig}
> sed -e 's@/lib\(64\)\?\(32\)\?/ld@/tools&@g' \
> -e 's@/usr@/tools@g' $file.orig > $file
> echo '
> #undef STANDARD_INCLUDE_DIR
> #define STANDARD_INCLUDE_DIR 0
> #define STANDARD_STARTFILE_PREFIX_1 ""
> #define STANDARD_STARTFILE_PREFIX_2 ""' >> $file
> touch $file.orig
> done
`gcc/config/i386/sysv4.h' -> `gcc/config/i386/sysv4.h.orig'
`gcc/config/i386/linux64.h' -> `gcc/config/i386/linux64.h.orig'
`gcc/config/i386/linux.h' -> `gcc/config/i386/linux.h.orig'
`gcc/config/ia64/sysv4.h' -> `gcc/config/ia64/sysv4.h.orig'
`gcc/config/ia64/linux.h' -> `gcc/config/ia64/linux.h.orig'
`gcc/config/sparc/sysv4.h' -> `gcc/config/sparc/sysv4.h.orig'
`gcc/config/sparc/linux64.h' -> `gcc/config/sparc/linux64.h.orig'
`gcc/config/sparc/linux.h' -> `gcc/config/sparc/linux.h.orig'
`gcc/config/cris/linux.h' -> `gcc/config/cris/linux.h.orig'
`gcc/config/m32r/linux.h' -> `gcc/config/m32r/linux.h.orig'
`gcc/config/rs6000/sysv4.h' -> `gcc/config/rs6000/sysv4.h.orig'
`gcc/config/rs6000/linux64.h' -> `gcc/config/rs6000/linux64.h.orig'
`gcc/config/rs6000/linux.h' -> `gcc/config/rs6000/linux.h.orig'
`gcc/config/xtensa/linux.h' -> `gcc/config/xtensa/linux.h.orig'
`gcc/config/mn10300/linux.h' -> `gcc/config/mn10300/linux.h.orig'
`gcc/config/frv/linux.h' -> `gcc/config/frv/linux.h.orig'
`gcc/config/alpha/linux.h' -> `gcc/config/alpha/linux.h.orig'
`gcc/config/sh/linux.h' -> `gcc/config/sh/linux.h.orig'
`gcc/config/bfin/linux.h' -> `gcc/config/bfin/linux.h.orig'
`gcc/config/s390/linux.h' -> `gcc/config/s390/linux.h.orig'
`gcc/config/linux.h' -> `gcc/config/linux.h.orig'
`gcc/config/m68k/linux.h' -> `gcc/config/m68k/linux.h.orig'
`gcc/config/mips/linux64.h' -> `gcc/config/mips/linux64.h.orig'
`gcc/config/mips/linux.h' -> `gcc/config/mips/linux.h.orig'
`gcc/config/vax/linux.h' -> `gcc/config/vax/linux.h.orig'
everything working great, i moved to pgno-47(tcl pkg)
thanku so much,
|
|
|
All times are GMT -5. The time now is 09:14 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|