LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-24-2010, 02:08 AM   #1
lohith ys
LQ Newbie
 
Registered: Apr 2010
Posts: 2

Rep: Reputation: 0
Question C compiler cannot create executables


hello all,

i am getting error while doing ./configure. i tried to install gilb, binutils,as suggested in ohter posts ,and it shows all are installed. please help me out, its urget. i have attached config.log file also , and by d way im tryin this in folder /opt/tinyos-2.x/support/sdk/c/sf/ as a root..

thanks in advance..

error shows

[root@localhost sf]# ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... xlc -q64
checking for C compiler default output file name...
configure: error: in `/opt/tinyos-2.x/support/sdk/c/sf':
configure: error: C compiler cannot create executables
See `config.log' for more details.

and config.log files shows ,

$ ./configure

## --------- ##
## Platform. ##
## --------- ##

hostname = localhost.localdomain
uname -m = i686
uname -r = 2.6.31.5-127.fc12.i686.PAE
uname -s = Linux
uname -v = #1 SMP Sat Nov 7 21:25:57 EST 2009

/usr/bin/uname -p = unknown
/bin/uname -X = unknown

/bin/arch = i686
/usr/bin/arch -k = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo = unknown
/bin/machine = unknown
/usr/bin/oslevel = unknown
/bin/universe = unknown

PATH: /opt/msp430/bin
PATH: /usr/lib/qt-3.3/bin
PATH: /usr/kerberos/sbin
PATH: /usr/kerberos/bin
PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /sbin
PATH: /bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /opt/msp430/bin
PATH: /opt/msp430/bin
PATH: /opt/jdk1.6.0_02/bin
PATH: /root/bin


## ----------- ##
## Core tests. ##
## ----------- ##

configure:1831: checking for a BSD-compatible install
configure:1899: result: /usr/bin/install -c
configure:1910: checking whether build environment is sane
configure:1970: result: yes
configure:2111: checking for a thread-safe mkdir -p
configure:2150: result: /bin/mkdir -p
configure:2163: checking for gawk
configure:2179: found /bin/gawk
configure:2190: result: gawk
configure:2201: checking whether make sets $(MAKE)
configure:2223: result: yes
configure:2354: checking for gcc
configure:2370: found /usr/bin/gcc
configure:2381: result: gcc
configure:2613: checking for C compiler version
configure:2621: gcc --version >&5
gcc (GCC) 4.4.3 20100127 (Red Hat 4.4.3-4)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2625: $? = 0
configure:2632: gcc -v >&5
Using built-in specs.
Target: i686-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre --enable-libgcj-multifile --enable-java-maintainer-mode --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --disable-libjava-multilib --with-ppl --with-cloog --with-tune=generic --with-arch=i686 --build=i686-redhat-linux
Thread model: posix
gcc version 4.4.3 20100127 (Red Hat 4.4.3-4) (GCC)
configure:2636: $? = 0
configure:2643: gcc -V >&5
gcc: '-V' option must have argument
configure:2647: $? = 1
configure:2670: checking for C compiler default output file name
configure:2692: gcc conftest.c >&5
as: unrecognized option '-Qy'
configure:2696: $? = 1
configure:2734: result:
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "cmotesdk"
| #define PACKAGE_TARNAME "cmotesdk"
| #define PACKAGE_VERSION "1.0"
| #define PACKAGE_STRING "cmotesdk 1.0"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE "cmotesdk"
| #define VERSION "1.0"
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:2740: error: in `/opt/tinyos-2.x/support/sdk/c/sf':
configure:2743: error: C compiler cannot create executables
See `config.log' for more details.

## ---------------- ##
## Cache variables. ##
## ---------------- ##

ac_cv_env_CC_set=
ac_cv_env_CC_value=
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_LIBS_set=
ac_cv_env_LIBS_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_path_install='/usr/bin/install -c'
ac_cv_path_mkdir=/bin/mkdir
ac_cv_prog_AWK=gawk
ac_cv_prog_ac_ct_CC=gcc
ac_cv_prog_make_make_set=yes

## ----------------- ##
## Output variables. ##
## ----------------- ##

ACLOCAL='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/missing --run aclocal-1.11'
AMDEPBACKSLASH=''
AMDEP_FALSE=''
AMDEP_TRUE=''
AMTAR='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/missing --run tar'
AUTOCONF='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/missing --run autoconf'
AUTOHEADER='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/missing --run autoheader'
AUTOMAKE='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/missing --run automake-1.11'
AWK='gawk'
CC='gcc'
CCDEPMODE=''
CFLAGS=''
CPPFLAGS=''
CYGPATH_W='echo'
DEFS=''
DEPDIR=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EXEEXT=''
INSTALL_DATA='${INSTALL} -m 644'
INSTALL_PROGRAM='${INSTALL}'
INSTALL_SCRIPT='${INSTALL}'
INSTALL_STRIP_PROGRAM='$(install_sh) -c -s'
LDFLAGS=''
LIBOBJS=''
LIBS=''
LTLIBOBJS=''
MAKEINFO='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/missing --run makeinfo'
MKDIR_P='/bin/mkdir -p'
OBJEXT=''
PACKAGE='cmotesdk'
PACKAGE_BUGREPORT=''
PACKAGE_NAME='cmotesdk'
PACKAGE_STRING='cmotesdk 1.0'
PACKAGE_TARNAME='cmotesdk'
PACKAGE_VERSION='1.0'
PATH_SEPARATOR=':'
RANLIB=''
SET_MAKE=''
SHELL='/bin/sh'
STRIP=''
VERSION='1.0'
ac_ct_CC='gcc'
am__EXEEXT_FALSE=''
am__EXEEXT_TRUE=''
am__fastdepCC_FALSE=''
am__fastdepCC_TRUE=''
am__include=''
am__isrc=''
am__leading_dot='.'
am__quote=''
am__tar='${AMTAR} chof - "$$tardir"'
am__untar='${AMTAR} xf -'
bindir='${exec_prefix}/bin'
build_alias=''
datadir='${datarootdir}'
datarootdir='${prefix}/share'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
dvidir='${docdir}'
exec_prefix='NONE'
host_alias=''
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
install_sh='${SHELL} /opt/tinyos-2.x/support/sdk/c/sf/config-aux/install-sh'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
mkdir_p='/bin/mkdir -p'
oldincludedir='/usr/include'
pdfdir='${docdir}'
prefix='NONE'
program_transform_name='s,x,x,'
psdir='${docdir}'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
sysconfdir='${prefix}/etc'
target_alias=''

## ----------- ##
## confdefs.h. ##
## ----------- ##

#define PACKAGE_NAME "cmotesdk"
#define PACKAGE_TARNAME "cmotesdk"
#define PACKAGE_VERSION "1.0"
#define PACKAGE_STRING "cmotesdk 1.0"
#define PACKAGE_BUGREPORT ""
#define PACKAGE "cmotesdk"
#define VERSION "1.0"

configure: exit 77
 
Old 04-24-2010, 07:14 AM   #2
johnsfine
LQ Guru
 
Registered: Dec 2007
Distribution: Centos
Posts: 5,286

Rep: Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197
Since most of us don't know what tinyos is, some context would have helped us provide a better answer.

Quote:
Originally Posted by lohith ys View Post
i am getting error while doing ./configure. i tried to install gilb, binutils,as suggested in ohter posts ,and it shows all are installed. please help me out, its urget. i have attached config.log file also , and by d way im tryin this in folder /opt/tinyos-2.x/support/sdk/c/sf/ as a root..
I took a quick look at some tinyos sites online and didn't see any meaningful top level summary, so I'm guessing at all the following:
Tinyos runs on some hardware very different from a PC. On a Linux system, you can run Tinyos binaries inside some kind of emulator and you can build Tinyos programs with some kind of cross compiler. So the support/sdk/c/sf/ that you are trying to make contains a little program to be built to run inside Tinyos, not to be built natively for Linux.

Does that fit what you understand and what you are asking? Or am I way off (or are you)?

The readme for that directory says:
Code:
 To build this SDK, run 
    6   ./bootstrap
    7   ./configure --prefix=<somewhere>
    8   make
Did you do the ./bootstrap step? Did it seem to work?

The problem spot in the long log you quoted seems to be:

Code:
configure:2643: gcc -V >&5
gcc: '-V' option must have argument
configure:2647: $? = 1
configure:2670: checking for C compiler default output file name
configure:2692: gcc    conftest.c  >&5
as: unrecognized option '-Qy'
I don't know why gcc would be passing -Qy to as. I'm wild guessing that might be something related to cross compiling, and that you might not have everything needed for cross compiling installed.
 
Old 04-26-2010, 04:22 AM   #3
lohith ys
LQ Newbie
 
Registered: Apr 2010
Posts: 2

Original Poster
Rep: Reputation: 0
thanks a lot for ur reply... ya v both r on same understanding...
that prob got solved .. if i do ./configure as a user lohith its working fine..
but same thing is giving error if i do as a root... i am not understanding y it is so??..
even if i try to execute simple hello.c prog as a root its giving error as 'unrecognized option '-Qy' ' ... ( but same works fine if i do as use r lohith)

and now im facing prob in next step of ./configure i.e in make step.
if i do make ( as a user lohith ), then its showing error as
make: *** No rule to make target `/usr/src/rpm/BUILD/tinyos-tools-1.4.0/tools/lib/serial/Serial.h', needed by `serialpacket.h'. Stop.
plz suggest me soln on this thanks....


lohith
 
Old 04-26-2010, 07:50 AM   #4
johnsfine
LQ Guru
 
Registered: Dec 2007
Distribution: Centos
Posts: 5,286

Rep: Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197Reputation: 1197
Quote:
Originally Posted by lohith ys View Post
thanks a lot for ur reply... ya v both r on same understanding...
Please take the small extra effort to type words, not ur, ya, v, or r.

Quote:
but same thing is giving error if i do as a root... i am not understanding y it is so??..
It is generally a bad idea to do anything as root that doesn't need to be done as root. Sometimes open source developers who are more fanatic about this rule than I am intentionally put things into ordinary scripts to make those scripts fail when run as root. I don't think that is the problem this time, but I can't rule it out.

At some point you must have installed whatever cross compiler tool set is needed for this project. I have no idea what, where, how you installed that. The symptoms imply you installed it in a way that only works for user lohith.

Quote:
prob in next step of ./configure i.e in make step.
if i do make ( as a user lohith ), then its showing error as
make: *** No rule to make target `/usr/src/rpm/BUILD/tinyos-tools-1.4.0/tools/lib/serial/Serial.h', needed by `serialpacket.h'. Stop.
That is a source file that should have been installed there before building the thing you're trying to build.

I don't have time to dig far enough into tinyos to figure ought what package you should have installed. Don't they have a forum for such questions.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
C compiler cannot create executables nedzer Linux - Newbie 13 01-21-2009 12:15 PM
C compiler cannot create executables freemanty Ubuntu 1 02-13-2007 02:42 PM
C compiler cannot create executables cov Amigo 3 05-06-2005 02:18 AM
C compiler cannot create executables martincho Linux - Software 3 10-01-2004 07:04 PM
C compiler cannot create executables... Sfpiano Linux - Software 9 12-11-2003 10:28 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:57 AM.

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