LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-19-2016, 09:43 AM   #1
raviteja1992
LQ Newbie
 
Registered: Jan 2016
Posts: 8

Rep: Reputation: Disabled
How to solve the eror cannot find -lgcc


/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.9/libgcc.a when searching for -lgcc
/usr/bin/ld: cannot find -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.9/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
collect2: error: ld returned 1 exit status
Makefile:21: recipe for target 'btestexplicit' failed
make: *** [btestexplicit] Error 1
./driver.pl: Could not make btest in /var/tmp/datalab.root.9403. The files are in /var/tmp/datalab.root.9403.


tried apt-get install g++-multilib.

Package g++-multilib is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'g++-multilib' has no installation candidate
 
Old 02-19-2016, 10:17 AM   #2
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573

Rep: Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142
You haven't told us what you're trying to build or what system you're running on.
 
Old 02-19-2016, 11:51 PM   #3
raviteja1992
LQ Newbie
 
Registered: Jan 2016
Posts: 8

Original Poster
Rep: Reputation: Disabled
operating system:- kali
i am trying to build a automatic grade checker for c programs.
Make file

#
# Makefile that builds btest and other helper programs for the CS:APP data lab
#
CC = gcc
CFLAGS = -O -Wall -m32
LIBS = -lm

all: btest fshow ishow

btest: btest.c bits.c decl.c tests.c btest.h bits.h
$(CC) $(CFLAGS) $(LIBS) -o btest bits.c btest.c decl.c tests.c

fshow: fshow.c
$(CC) $(CFLAGS) -o fshow fshow.c

ishow: ishow.c
$(CC) $(CFLAGS) -o ishow ishow.c

# Forces a recompile. Used by the driver program.
btestexplicit:
$(CC) $(CFLAGS) $(LIBS) -o btest bits.c btest.c decl.c tests.c

clean:
rm -f *.o btest fshow ishow *~
 
Old 02-20-2016, 09:04 AM   #4
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573

Rep: Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142
Kali is a penetration testing distro, it's not really built for every-day usage. I wouldn't be surprised if there's a problem with the repository that's preventing the installation of the 32-bit gcc libraries.

You tried g++-multilib, but how about gcc-multilib?
 
Old 02-20-2016, 04:26 PM   #5
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,627

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
you ARE going to have major issues using Kali

the best fix if you need to use a debian based OS is to well install Debian 8 or Mint 17

also if you are NEEDING to explicitly build a old 32 bit version you likely will also need to use a older version of gcc
"gcc 3.4-compatibility " will be in the Debian and mint repos , but not likely in the kali repos
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
U-boot build fails - cannot find lgcc / gcclib.a lachlanp Linux - Newbie 0 10-15-2014 10:44 PM
Glibc 2.7 Build Error "ld: cannot find -lgcc" binzyw Linux From Scratch 8 06-25-2012 02:51 AM
Error...-lgcc not found manoj7410 Linux - Embedded & Single-board computer 1 06-18-2012 08:13 AM
-lgcc not found. manoj7410 Linux - Embedded & Single-board computer 1 06-12-2012 08:54 AM
how to solve the cannot find lX11 northern_lights Linux - Newbie 1 08-30-2006 04:58 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:43 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