Results 1 to 9 of 9
hi,
I am trying to install avr gcc compiler, I could install the binutils 2.15 first but I am stuck at gcc. I am going through the following document :
...
- 01-12-2008 #1Just Joined!
- Join Date
- Jan 2008
- Posts
- 8
avr-ranlib: Command not found
hi,
I am trying to install avr gcc compiler, I could install the binutils 2.15 first but I am stuck at gcc. I am going through the following document :
http://www.tuxgraphics.org/electroni...ticle352.shtml
I can run make without any trouble I guess, it reaches to the end but while running make install I got following error:
avr-ranlib /usr/local/avr/lib/gcc/avr/3.4.2/libgcc.a
make[2]: avr-ranlib: Command not found
make[2]: *** [install] Error 127
make[2]: Leaving directory `/home/oguzhan/Desktop/Oguzhan/gcc-3.4.2/obj-avr/gcc'
make[1]: *** [install-multilib] Error 2
make[1]: Leaving directory `/home/oguzhan/Desktop/Oguzhan/gcc-3.4.2/obj-avr/gcc'
make: *** [install-gcc] Error 2
avr-ranlib in my path under directory /usr/local/avr/bin and it is executable. What might be the problem with it? I can supply any info related, could you help me to fix?
- 01-12-2008 #2
Sounds to me as though /usr/local/avr is not part of your PATH environment variable. To find out, do this at the command line:
If you want to add it to PATH, do this:Code:which avr-ranlib echo $PATH
Notice that there's only one dollar sign in that command.Code:export PATH=$PATH:/usr/local/avr
But this might not be a wise thing to do. I'm sure they've checked out the installation procedure. Perhaps there's a part of it you might have overlooked? If so, just doing the export command above will fix your immediate problem but might still not be enough to make the installation go smoothly.--
Bill
Old age and treachery will overcome youth and skill.
- 01-12-2008 #3Just Joined!
- Join Date
- Jan 2008
- Posts
- 8
thanks for the reply,
I have alrady checked the PATH, avr-ranlib is under /usr/local/avr/bin and this is added to the PATH, I have tried adding /usr/local/avr too despite I dont see any sense in it. Can it be realeted to the updating linker cache with ldconfig command. I have called it after I installed binutils but I am not sure it worked properly, I rebooted the system but nothing changed.
Does any one have any idea?
Are there any other ways to install gcc-core-3.4.2 package to a directory I like? Maybe with aptitude or synaptic package manager?
- 01-13-2008 #4Linux Engineer
- Join Date
- Apr 2006
- Location
- Saint Paul, MN, USA / CentOS, Debian, Solaris, SuSE
- Posts
- 1,117
Hi.
I know nothing about the AVR subject, but here are some comments after a quick skim:
I could not get the document unless I used: tuxgraphics.org: 352, Programming the AVR microcontroller with GCC, libc 1.0.4
That document advises the PATH be changed with:
which places the added path before the existing path.Code:export PATH=/usr/local/avr/bin:${PATH}
Several places require:
Rebuilding the linker cache with:Code:# as root:
should have been been emphasized -- it's very easy to miss it.Add the line /usr/local/avr/lib to the file /etc/ld.so.conf and run the command /sbin/ldconfig to rebuild the linker cache.
After installation, for compiling, he suggests:
Later, in lf231, Hardware: Programming the AVR Microcontroller with GCCIf needed edit your .bash_profile or .tcshrc and add:
...
he suggests, among others:
which, if he didn't update the more recent files, might be related to the problem, because the path is different. I think I'd check the files doconf and domake.Code:export PATH=/usr/local/atmel/bin:${PATH} export RANLIB=avr-ranlib
Best wishes, keep us posted ... cheers, drlWelcome - get the most out of the forum by reading forum basics and guidelines: click here.
90% of questions can be answered by using man pages, Quick Search, Advanced Search, Google search, Wikipedia.
We look forward to helping you with the challenge of the other 10%.
( Mn, 2.6.n, AMD-64 3000+, ASUS A8V Deluxe, 1 GB, SATA + IDE, Matrox G400 AGP )
- 01-13-2008 #5Just Joined!
- Join Date
- Jan 2008
- Posts
- 8
I have changed the PATH as suggested;
export PATH=/usr/local/avr/bin:{PATH}
I did not added the line /usr/local/avr/bin to the /etc/ld.so.conf because it was already there, in a previous try I had added it there. I run the command /etc/ldconfig, it did not show any reports or errors, it just ran.
Thank you for the other link I haven't seen it before, I could not end the installation so I do not consider editing .bash_profile or .tcshrc for the moment. But maybe I should consider trying export RANLIB=avr-ranlib before installing gcc, should I?
I dont know what are doconf and domake files but I will search some info about those as well.
Thanks for the reply.
- 01-13-2008 #6Linux Engineer
- Join Date
- Apr 2006
- Location
- Saint Paul, MN, USA / CentOS, Debian, Solaris, SuSE
- Posts
- 1,117
Hi.
Sorry, I cannot give you any knowledgeable answers about the RANLIB setting. I don't know why they would need a different version of ranlib, but the AVR stuff might require it.
To look at the linker cache, use:
but it does produce a lot of output, almost 800 lines on my system.Code:ldconfig -p
I have often found that I can understand problems better if I explain the situation to a friend over coffee. That makes me look more closely at some things I may have skipped or misunderstood earlier ... cheers, drlWelcome - get the most out of the forum by reading forum basics and guidelines: click here.
90% of questions can be answered by using man pages, Quick Search, Advanced Search, Google search, Wikipedia.
We look forward to helping you with the challenge of the other 10%.
( Mn, 2.6.n, AMD-64 3000+, ASUS A8V Deluxe, 1 GB, SATA + IDE, Matrox G400 AGP )
- 01-13-2008 #7Just Joined!
- Join Date
- Jan 2008
- Posts
- 8
Thanks for your reply, I will switch my system from xubuntu to ubuntu, I want to make a fresh start. Thanks again
- 01-13-2008 #8Linux Engineer
- Join Date
- Apr 2006
- Location
- Saint Paul, MN, USA / CentOS, Debian, Solaris, SuSE
- Posts
- 1,117
Hi.
I assume your decision is for a number of reasons, not only to try to resolve this problem.
In any case, I hope you have better luck next time around ... cheers, drlWelcome - get the most out of the forum by reading forum basics and guidelines: click here.
90% of questions can be answered by using man pages, Quick Search, Advanced Search, Google search, Wikipedia.
We look forward to helping you with the challenge of the other 10%.
( Mn, 2.6.n, AMD-64 3000+, ASUS A8V Deluxe, 1 GB, SATA + IDE, Matrox G400 AGP )
- 04-14-2009 #9Just Joined!
- Join Date
- Apr 2009
- Posts
- 1
PATH problem
Hi, I use Ubuntu and had the exact same problem
avr-libc compiled all right, but I had to run 'make install' with the command sudo. It showed that my PATH became that of the root user. I solved this by switch to root user and then export the PATH again:
This seems to have workedCode:$sudo -s -H #export PATH=$PATH:/usr/local/AVR/bin #make install

Regards.


Reply With Quote
