public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* cannot compute suffix of object files: cannot compile: -a64 unsupported
@ 2013-11-25 22:22 dellair jie
  2013-11-26  9:47 ` Jonathan Wakely
  0 siblings, 1 reply; 9+ messages in thread
From: dellair jie @ 2013-11-25 22:22 UTC (permalink / raw)
  To: GCC HELP

Folks,

I am compiling GCC 4.4.5 on AIX 6.1 with xlc 10.1.

GMP, MPFR, MPC are compiled because we have no root control over the server.

Configuration options are as following.

Would be appreciated if anyone can shed some lights on what went wrong.

PS: a64 option is found nowhere, which is really weird.

config.log:
Configured with: /gcc/configure --prefix=/AIX32 --enable-static
--with-gmp=/crosstools/gmp/AIX32 --with-mpfr=/crosstools/mpfr/AIX32
--with-mpc=/crosstools/mpc/AIX32 --disable-nls --enable-threads
--enable-languages=c,c++
Thread model: aix
gcc version 4.4.5 (GCC)
configure:2391: $? = 0
configure:2393: /gcc/host-powerpc-ibm-aix6.1.0.0/gcc/xgcc
-B/gcc/host-powerpc-ibm-aix6.1.0.0/gcc/
-B/AIX32/powerpc-ibm-aix6.1.0.0/bin/
-B/AIX32/powerpc-ibm-aix6.1.0.0/lib/ -isystem
/AIX32/powerpc-ibm-aix6.1.0.0/include -isystem
/AIX32/powerpc-ibm-aix6.1.0.0/sys-include -maix64 -V </dev/null >&5
xgcc: '-V' must come at the start of the command line
configure:2396: $? = 1
configure:2415: /gcc/host-powerpc-ibm-aix6.1.0.0/gcc/xgcc
-B/gcc/host-powerpc-ibm-aix6.1.0.0/gcc/
-B/AIX32/powerpc-ibm-aix6.1.0.0/bin/
-B/AIX32/powerpc-ibm-aix6.1.0.0/lib/ -isystem
/AIX32/powerpc-ibm-aix6.1.0.0/include -isystem
/AIX32/powerpc-ibm-aix6.1.0.0/sys-include -maix64 -o conftest -g -q32
conftest.c >&5
xgcc: unrecognized option '-q32'
Assembler messages:
Fatal error: -a64 unsupported
configure:2418: $? = 1
configure:2590: checking for suffix of object files
configure:2611: /gcc/host-powerpc-ibm-aix6.1.0.0/gcc/xgcc
-B/gcc/host-powerpc-ibm-aix6.1.0.0/gcc/
-B/AIX32/powerpc-ibm-aix6.1.0.0/bin/
-B/AIX32/powerpc-ibm-aix6.1.0.0/lib/ -isystem
/AIX32/powerpc-ibm-aix6.1.0.0/include -isystem
/AIX32/powerpc-ibm-aix6.1.0.0/sys-include -maix64 -c -g -q32
conftest.c >&5
xgcc: unrecognized option '-q32'
Assembler messages:
Fatal error: -a64 unsupported
configure:2614: $? = 1
configure: failed program was:
| /* confdefs.h. */
|
| #define PACKAGE_NAME "GNU C Runtime Library"
| #define PACKAGE_TARNAME "libgcc"
| #define PACKAGE_VERSION "1.0"
| #define PACKAGE_STRING "GNU C Runtime Library 1.0"
| #define PACKAGE_BUGREPORT ""
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:2627: error: in `/gcc/powerpc-ibm-aix6.1.0.0/ppc64/libgcc':
configure:2629: error: cannot compute suffix of object files: cannot compile
See `config.log' for more details.


Br,
Dellair

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-25 22:22 cannot compute suffix of object files: cannot compile: -a64 unsupported dellair jie
@ 2013-11-26  9:47 ` Jonathan Wakely
  2013-11-26 11:13   ` dellair jie
  0 siblings, 1 reply; 9+ messages in thread
From: Jonathan Wakely @ 2013-11-26  9:47 UTC (permalink / raw)
  To: dellair jie; +Cc: GCC HELP

On 25 November 2013 19:13, dellair jie wrote:
> Folks,
>
> I am compiling GCC 4.4.5 on AIX 6.1 with xlc 10.1.
>
> GMP, MPFR, MPC are compiled because we have no root control over the server.

Then you should probably build then in-tree, not install them
separately. See http://gcc.gnu.org/wiki/InstallingGCC

> configure:2627: error: in `/gcc/powerpc-ibm-aix6.1.0.0/ppc64/libgcc':
> configure:2629: error: cannot compute suffix of object files: cannot compile
> See `config.log' for more details.

Have you read http://gcc.gnu.org/wiki/FAQ#configure_suffix ?

If you follow the instructions at
http://gcc.gnu.org/wiki/InstallingGCC it will probably solve your
problem.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-26  9:47 ` Jonathan Wakely
@ 2013-11-26 11:13   ` dellair jie
  2013-11-26 12:14     ` Jonathan Wakely
  0 siblings, 1 reply; 9+ messages in thread
From: dellair jie @ 2013-11-26 11:13 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: GCC HELP

Dear Jonathan,

Thanks for the reply and information shared.

We are not able to compile the GMP/MPFR/MPC libraries via prerequisite
script as the server is not connected to internet either. Hence we can
only compile them separately.
The libraries we compile are static libraries, and after the
compilation, a "make check" has been done in order for accuracy.

I did follow your guide to check the config.log under sub-directory,
in this case libgcc, and the log was attached in first email.
It failed at "Fatal error: -a64 unsupported" and it is very confusing
cause there's nowhere to find the a64 option in command/arguments.

Could it be incompatibility of AIX6.1 and GCC 4.4.5 and XLC 10.1?

Thanks,
Dellair

On Mon, Nov 25, 2013 at 11:22 PM, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
> On 25 November 2013 19:13, dellair jie wrote:
>> Folks,
>>
>> I am compiling GCC 4.4.5 on AIX 6.1 with xlc 10.1.
>>
>> GMP, MPFR, MPC are compiled because we have no root control over the server.
>
> Then you should probably build then in-tree, not install them
> separately. See http://gcc.gnu.org/wiki/InstallingGCC
>
>> configure:2627: error: in `/gcc/powerpc-ibm-aix6.1.0.0/ppc64/libgcc':
>> configure:2629: error: cannot compute suffix of object files: cannot compile
>> See `config.log' for more details.
>
> Have you read http://gcc.gnu.org/wiki/FAQ#configure_suffix ?
>
> If you follow the instructions at
> http://gcc.gnu.org/wiki/InstallingGCC it will probably solve your
> problem.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-26 11:13   ` dellair jie
@ 2013-11-26 12:14     ` Jonathan Wakely
  2013-11-26 12:40       ` dellair jie
  0 siblings, 1 reply; 9+ messages in thread
From: Jonathan Wakely @ 2013-11-26 12:14 UTC (permalink / raw)
  To: dellair jie; +Cc: GCC HELP

On 26 November 2013 09:47, dellair jie wrote:
> Dear Jonathan,
>
> Thanks for the reply and information shared.
>
> We are not able to compile the GMP/MPFR/MPC libraries via prerequisite
> script as the server is not connected to internet either. Hence we can
> only compile them separately.

That's not true, you don't need to use the download_prerequisites
script, it just makes it easier. You can still put the sources in the
GCC tree manually to build them in-tree.

> The libraries we compile are static libraries, and after the
> compilation, a "make check" has been done in order for accuracy.

OK, building them static avoids the problem I thought you were having
(but it's still easier to build them in-tree).

> I did follow your guide to check the config.log under sub-directory,
> in this case libgcc, and the log was attached in first email.

> It failed at "Fatal error: -a64 unsupported" and it is very confusing
> cause there's nowhere to find the a64 option in command/arguments.

It also says the option -q32 is not recognised. GCC should not be
trying to use arguments it doesn't recognise, so that suggests the
argument came from your configuration.  Do you have any environment
variables set that contain -q32?  e.g. CFLAGS?  What does this show?
env | fgrep q32

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-26 12:14     ` Jonathan Wakely
@ 2013-11-26 12:40       ` dellair jie
  2013-11-26 12:54         ` Jonathan Wakely
  0 siblings, 1 reply; 9+ messages in thread
From: dellair jie @ 2013-11-26 12:40 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: GCC HELP

Hello Jon,

Regarding the q32 option, I think it is a default behavior of xlc
compiler, it automatically adds q32 to build 32 bit objects.
I added one more option "--disable-multilib", and the build seems to
go further then stopped at: Permission denied to
/usr/local/include/time.h

In fact, the correct local include directory is: /usr/include instead
of /usr/local/include, any idea how we can specify it for compilation?
I just added "LOCAL_INCLUDE_DIR" variable to the build, and it is still ongoing.
What do you think adding the option "-DLOCAL_INCLUDE_DIR=" to CFLAGs
in case it stopped on the same error?

Regards,


On Tue, Nov 26, 2013 at 12:13 PM, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
> On 26 November 2013 09:47, dellair jie wrote:
>> Dear Jonathan,
>>
>> Thanks for the reply and information shared.
>>
>> We are not able to compile the GMP/MPFR/MPC libraries via prerequisite
>> script as the server is not connected to internet either. Hence we can
>> only compile them separately.
>
> That's not true, you don't need to use the download_prerequisites
> script, it just makes it easier. You can still put the sources in the
> GCC tree manually to build them in-tree.
>
>> The libraries we compile are static libraries, and after the
>> compilation, a "make check" has been done in order for accuracy.
>
> OK, building them static avoids the problem I thought you were having
> (but it's still easier to build them in-tree).
>
>> I did follow your guide to check the config.log under sub-directory,
>> in this case libgcc, and the log was attached in first email.
>
>> It failed at "Fatal error: -a64 unsupported" and it is very confusing
>> cause there's nowhere to find the a64 option in command/arguments.
>
> It also says the option -q32 is not recognised. GCC should not be
> trying to use arguments it doesn't recognise, so that suggests the
> argument came from your configuration.  Do you have any environment
> variables set that contain -q32?  e.g. CFLAGS?  What does this show?
> env | fgrep q32

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-26 12:40       ` dellair jie
@ 2013-11-26 12:54         ` Jonathan Wakely
  2013-11-26 13:34           ` dellair jie
  0 siblings, 1 reply; 9+ messages in thread
From: Jonathan Wakely @ 2013-11-26 12:54 UTC (permalink / raw)
  To: dellair jie; +Cc: GCC HELP

On 26 November 2013 12:14, dellair jie wrote:
> Hello Jon,
>
> Regarding the q32 option, I think it is a default behavior of xlc
> compiler, it automatically adds q32 to build 32 bit objects.

But the option is being added to a gcc command, not xlc.

You might need to look earlier in libgcc/config.log for other relevant errors.

> I added one more option "--disable-multilib", and the build seems to
> go further then stopped at: Permission denied to
> /usr/local/include/time.h
>
> In fact, the correct local include directory is: /usr/include instead
> of /usr/local/include, any idea how we can specify it for compilation?

It will automatically look in /usr/include

The error suggests it is trying to also look in /usr/local/include but
doesn't have permission to.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-26 12:54         ` Jonathan Wakely
@ 2013-11-26 13:34           ` dellair jie
  2013-11-27  8:18             ` Jonathan Wakely
  0 siblings, 1 reply; 9+ messages in thread
From: dellair jie @ 2013-11-26 13:34 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: GCC HELP

Thanks Jon,

Regarding the "permisison denied" error, I have added
"-DLOCAL_INCLUDE_DIR" and setup the environment variable to
/usr/include folder.
However, I am still getting it in config.log.

Any ideas on how to get this solved?

Our environment is setup like:
All standard head files are under /usr/include
The /usr/local/include exist but only readable to root.

configure:2842: /GCC/gcc-4.4.0-aix/./gcc/xgcc -B/smhs1_c2/u/cm/ljie/
GCC/gcc-4.4.0-aix/./gcc/ -B/GCC/gcc-4.4.0-aix/AIX32/powerpc-ibm-aix6
.1.0.0/bin/ -B/GCC/gcc-4.4.0-aix/AIX32/powerpc-ibm-aix6.1.0.0/lib/ -
isystem /GCC/gcc-4.4.0-aix/AIX32/powerpc-ibm-aix6.1.0.0/include -isy
stem /GCC/gcc-4.4.0-aix/AIX32/powerpc-ibm-aix6.1.0.0/sys-include  -c
 -g -DLOCAL_INCLUDE_DIR=/usr/include    conftest.c >&5
In file included from conftest.c:10:
/GCC/gcc-4.4.0-aix/./gcc/include-fixed/stdio.h:57:23: error: /usr/lo
cal/include/standards.h: Permission denied
In file included from conftest.c:11:
/GCC/gcc-4.4.0-aix/./gcc/include-fixed/sys/types.h:67:29: error: /us
r/local/include/strict_stdtypes.h: Permission denied
/GCC/gcc-4.4.0-aix/./gcc/include-fixed/sys/types.h:70:26: error: /us
r/local/include/sys/inttypes.h: Permission denied
/GCC/gcc-4.4.0-aix/./gcc/include-fixed/sys/types.h:73:33: error: /us
r/local/include/end_strict_stdtypes.h: Permission denied
conftest.c:12:22: error: /usr/local/include/sys/stat.h: Permission denied
conftest.c:15: error: expected '=', ',', ';', 'asm' or '__attribute__'
before '*' token
conftest.c:44: error: expected declaration specifiers or '...' before 'FILE'
configure:2848: $? = 1
configure: failed program was

Thanks in advance!

On Tue, Nov 26, 2013 at 1:40 PM, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
> On 26 November 2013 12:14, dellair jie wrote:
>> Hello Jon,
>>
>> Regarding the q32 option, I think it is a default behavior of xlc
>> compiler, it automatically adds q32 to build 32 bit objects.
>
> But the option is being added to a gcc command, not xlc.
>
> You might need to look earlier in libgcc/config.log for other relevant errors.
>
>> I added one more option "--disable-multilib", and the build seems to
>> go further then stopped at: Permission denied to
>> /usr/local/include/time.h
>>
>> In fact, the correct local include directory is: /usr/include instead
>> of /usr/local/include, any idea how we can specify it for compilation?
>
> It will automatically look in /usr/include
>
> The error suggests it is trying to also look in /usr/local/include but
> doesn't have permission to.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-26 13:34           ` dellair jie
@ 2013-11-27  8:18             ` Jonathan Wakely
  2013-11-27 20:44               ` dellair jie
  0 siblings, 1 reply; 9+ messages in thread
From: Jonathan Wakely @ 2013-11-27  8:18 UTC (permalink / raw)
  To: dellair jie; +Cc: GCC HELP

On 26 November 2013 13:22, dellair jie wrote:
> Thanks Jon,
>
> Regarding the "permisison denied" error, I have added
> "-DLOCAL_INCLUDE_DIR" and setup the environment variable to
> /usr/include folder.

I'm not sure what you've done here. It would help to show the exact
commands you used.

> However, I am still getting it in config.log.
>
> Any ideas on how to get this solved?
>
> Our environment is setup like:
> All standard head files are under /usr/include
> The /usr/local/include exist but only readable to root.

GCC cannot be used if one of the directories in its search path is not readable.

Have you tried using the --with-local-prefix=/usr configuration option?
See http://gcc.gnu.org/install/configure.html

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: cannot compute suffix of object files: cannot compile: -a64 unsupported
  2013-11-27  8:18             ` Jonathan Wakely
@ 2013-11-27 20:44               ` dellair jie
  0 siblings, 0 replies; 9+ messages in thread
From: dellair jie @ 2013-11-27 20:44 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: GCC HELP

You are a saver!!!

The rebuild works like magic! :)

On Tue, Nov 26, 2013 at 2:40 PM, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
> On 26 November 2013 13:22, dellair jie wrote:
>> Thanks Jon,
>>
>> Regarding the "permisison denied" error, I have added
>> "-DLOCAL_INCLUDE_DIR" and setup the environment variable to
>> /usr/include folder.
>
> I'm not sure what you've done here. It would help to show the exact
> commands you used.
>
>> However, I am still getting it in config.log.
>>
>> Any ideas on how to get this solved?
>>
>> Our environment is setup like:
>> All standard head files are under /usr/include
>> The /usr/local/include exist but only readable to root.
>
> GCC cannot be used if one of the directories in its search path is not readable.
>
> Have you tried using the --with-local-prefix=/usr configuration option?
> See http://gcc.gnu.org/install/configure.html

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2013-11-27 19:10 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-25 22:22 cannot compute suffix of object files: cannot compile: -a64 unsupported dellair jie
2013-11-26  9:47 ` Jonathan Wakely
2013-11-26 11:13   ` dellair jie
2013-11-26 12:14     ` Jonathan Wakely
2013-11-26 12:40       ` dellair jie
2013-11-26 12:54         ` Jonathan Wakely
2013-11-26 13:34           ` dellair jie
2013-11-27  8:18             ` Jonathan Wakely
2013-11-27 20:44               ` dellair jie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).