LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
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


Reply
  Search this Thread
Old 01-06-2022, 06:46 PM   #1
TripleDave
Member
 
Registered: Jun 2018
Location: Adelaide SA
Distribution: Lubuntu 18.04 & Mint 20.04
Posts: 38

Rep: Reputation: Disabled
LFS v11.0 binutils 5.2.1 installation fail


Everything completed successfully as per the book until the 'make install -j1' instruction at page 45. I'm doing this as the lfs user however the existing /usr/local/share/ require root to access, hence the Permission denied error. What've I missed?

lfs:/mnt/lfs/sources/binutils-2.37/build$ make install -j1
make[1]: Entering directory '/mnt/lfs/sources/binutils-2.37/build'
/bin/sh ../mkinstalldirs /usr/local /usr/local
make[2]: Entering directory '/mnt/lfs/sources/binutils-2.37/build/bfd'
make install-recursive
make[3]: Entering directory '/mnt/lfs/sources/binutils-2.37/build/bfd'
Making install in doc
make[4]: Entering directory '/mnt/lfs/sources/binutils-2.37/build/bfd/doc'
/bin/mkdir -p '/usr/local/share/info'
/bin/mkdir: cannot create directory '/usr/local/share/info': Permission denied
make[4]: *** [Makefile:826: install-info-am] Error 1
make[4]: Leaving directory '/mnt/lfs/sources/binutils-2.37/build/bfd/doc'
make[3]: *** [Makefile:1643: install-recursive] Error 1
make[3]: Leaving directory '/mnt/lfs/sources/binutils-2.37/build/bfd'
make[2]: *** [Makefile:1751: install] Error 2
make[2]: Leaving directory '/mnt/lfs/sources/binutils-2.37/build/bfd'
make[1]: *** [Makefile:2884: install-bfd] Error 2
make[1]: Leaving directory '/mnt/lfs/sources/binutils-2.37/build'
make: *** [Makefile:2339: install] Error 2
 
Old 01-07-2022, 05:43 AM   #2
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,613
Blog Entries: 19

Rep: Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460Reputation: 4460
Chapter 5 tools shouldn't be installed into /usr/local but into /$LFS/tools. You must have forgotten the "prefix" option on your build.
Quote:
../configure --prefix=$LFS/tools \
--with-sysroot=$LFS \
--target=$LFS_TGT \
--disable-nls \
--disable-werror
The way configure scripts work is that they always try to install into the /usr/local tree if not told otherwise.
 
Old 01-07-2022, 05:59 PM   #3
TripleDave
Member
 
Registered: Jun 2018
Location: Adelaide SA
Distribution: Lubuntu 18.04 & Mint 20.04
Posts: 38

Original Poster
Rep: Reputation: Disabled
Thanks Hazel - you were spot on Sport! I missed the prior ../configure --prefix=$LFS/tools command. I'm doing this build to expand my knowledge of all thing linux and this forum is proving very helpful.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] if [[ -n "$1" ]]; then FAIL FAIL FAIL rbees Programming 7 03-25-2015 02:39 PM
[SOLVED] LFS: Error during Binutils-2.22 - Pass 1 (Section 5.4, LFS 7.2) erkant Linux From Scratch 4 11-26-2012 01:26 PM
nvidia display drivers installation error with binutils, binutils allready installed mandrakeBren Linux - Newbie 9 01-06-2009 12:52 PM
binutils-2.16.1 or binutils-2.17 Hern_28 Linux From Scratch 2 07-15-2007 09:05 AM
Installation of binutils....can't mkdir...../binutils-build hmonster Linux From Scratch 6 08-22-2004 04:07 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 10:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration