You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by "Mahajan, Neeraj" <ne...@ebay.com> on 2007/06/19 04:44:29 UTC

Build failing for native code

Hi,
 
I am trying to build the native code (which includes the compression
library) on Solaris 10 (x86 64-bit). I get the following error while
building:
 
gmake  all-recursive
gmake[1]: Entering directory
`/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
Making all in src/org/apache/hadoop/io/compress/zlib
gmake[2]: Entering directory
`/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apache/
hadoop/io/compress/zlib'
if /bin/sh ../../../../../../../libtool --mode=compile gcc
-DHAVE_CONFIG_H -I. -I. -I../../../../../../..  -I/usr/java/include
-I/usr/java/include/solaris -I/src
-I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall -fPIC
-O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF
".deps/ZlibCompressor.Tpo" -c -o ZlibCompressor.lo ZlibCompressor.c; \
then mv -f ".deps/ZlibCompressor.Tpo" ".deps/ZlibCompressor.Plo"; else
rm -f ".deps/ZlibCompressor.Tpo"; exit 1; fi
 gcc -DHAVE_CONFIG_H -I. -I. -I../../../../../../.. -I/usr/java/include
-I/usr/java/include/solaris -I/src
-I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall -fPIC
-O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF .deps/ZlibCompressor.Tpo
-c ZlibCompressor.c  -fPIC -DPIC -o .libs/ZlibCompressor.o
cc1: error: missing argument to "-m"
gmake[2]: *** [ZlibCompressor.lo] Error 1
gmake[2]: Leaving directory
`/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apache/
hadoop/io/compress/zlib'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory
`/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'

 
Any idea how this can be resolved?
 
Thanks,
Neeraj

RE: Build failing for native code

Posted by "Mahajan, Neeraj" <ne...@ebay.com>.
I made one mistake here. I ran make directly in the native folder. I
think you should run 'ant compile-core-native' in the project root
folder.

Anyways, ant also didn't work as I didn't have dumpbin on my system. I
had to compile binutils for that. I also saw that the shell script
complained about svn not being found. I compile svn too. And added both
to path and my ant compile-core-native was successful. This built the
libhadoop.* files.

I really wish that all the scripts were written for pure bourne shell
(things like 'export A=..' which can be found in the scripts, do not
work with Solaris sh) and checks for utilities like dumpbin (which is
required) be done at configure level.

~ Neeraj

-----Original Message-----
From: Mahajan, Neeraj [mailto:nemahajan@ebay.com] 
Sent: Tuesday, June 19, 2007 9:17 AM
To: hadoop-user@lucene.apache.org
Subject: RE: Build failing for native code

The problem is how to fix it ... What in which script needs to be
changed to fix this?

~ Neeraj 

-----Original Message-----
From: Phantom [mailto:ghostwhoowalks@gmail.com]
Sent: Monday, June 18, 2007 7:54 PM
To: hadoop-user@lucene.apache.org
Subject: Re: Build failing for native code

By looking at the gcc command that you have a -m in it. It needs to be
either -m32 or -m64 depending on whether your machine is a 32 or 64 bit
machine.

A

On 6/18/07, Mahajan, Neeraj <ne...@ebay.com> wrote:
>
> Hi,
>
> I am trying to build the native code (which includes the compression
> library) on Solaris 10 (x86 64-bit). I get the following error while
> building:
>
> gmake  all-recursive
> gmake[1]: Entering directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
> Making all in src/org/apache/hadoop/io/compress/zlib
> gmake[2]: Entering directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apach
> e/
> hadoop/io/compress/zlib'
> if /bin/sh ../../../../../../../libtool --mode=compile gcc 
> -DHAVE_CONFIG_H -I. -I. -I../../../../../../..  -I/usr/java/include 
> -I/usr/java/include/solaris -I/src 
> -I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall 
> -fPIC
> -O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF 
> ".deps/ZlibCompressor.Tpo" -c -o ZlibCompressor.lo ZlibCompressor.c; \

> then mv -f ".deps/ZlibCompressor.Tpo" ".deps/ZlibCompressor.Plo"; else

> rm -f ".deps/ZlibCompressor.Tpo"; exit 1; fi gcc -DHAVE_CONFIG_H -I. 
> -I. -I../../../../../../.. -I/usr/java/include 
> -I/usr/java/include/solaris -I/src 
> -I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall 
> -fPIC
> -O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF 
> .deps/ZlibCompressor.Tpo -c ZlibCompressor.c  -fPIC -DPIC -o 
> .libs/ZlibCompressor.o
> cc1: error: missing argument to "-m"
> gmake[2]: *** [ZlibCompressor.lo] Error 1
> gmake[2]: Leaving directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apach
> e/
> hadoop/io/compress/zlib'
> gmake[1]: *** [all-recursive] Error 1
> gmake[1]: Leaving directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
>
>
> Any idea how this can be resolved?
>
> Thanks,
> Neeraj
>

RE: Build failing for native code

Posted by "Mahajan, Neeraj" <ne...@ebay.com>.
The problem is how to fix it ... What in which script needs to be
changed to fix this?

~ Neeraj 

-----Original Message-----
From: Phantom [mailto:ghostwhoowalks@gmail.com] 
Sent: Monday, June 18, 2007 7:54 PM
To: hadoop-user@lucene.apache.org
Subject: Re: Build failing for native code

By looking at the gcc command that you have a -m in it. It needs to be
either -m32 or -m64 depending on whether your machine is a 32 or 64 bit
machine.

A

On 6/18/07, Mahajan, Neeraj <ne...@ebay.com> wrote:
>
> Hi,
>
> I am trying to build the native code (which includes the compression
> library) on Solaris 10 (x86 64-bit). I get the following error while
> building:
>
> gmake  all-recursive
> gmake[1]: Entering directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
> Making all in src/org/apache/hadoop/io/compress/zlib
> gmake[2]: Entering directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apach
> e/
> hadoop/io/compress/zlib'
> if /bin/sh ../../../../../../../libtool --mode=compile gcc 
> -DHAVE_CONFIG_H -I. -I. -I../../../../../../..  -I/usr/java/include 
> -I/usr/java/include/solaris -I/src 
> -I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall 
> -fPIC
> -O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF 
> ".deps/ZlibCompressor.Tpo" -c -o ZlibCompressor.lo ZlibCompressor.c; \

> then mv -f ".deps/ZlibCompressor.Tpo" ".deps/ZlibCompressor.Plo"; else

> rm -f ".deps/ZlibCompressor.Tpo"; exit 1; fi gcc -DHAVE_CONFIG_H -I. 
> -I. -I../../../../../../.. -I/usr/java/include 
> -I/usr/java/include/solaris -I/src 
> -I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall 
> -fPIC
> -O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF 
> .deps/ZlibCompressor.Tpo -c ZlibCompressor.c  -fPIC -DPIC -o 
> .libs/ZlibCompressor.o
> cc1: error: missing argument to "-m"
> gmake[2]: *** [ZlibCompressor.lo] Error 1
> gmake[2]: Leaving directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apach
> e/
> hadoop/io/compress/zlib'
> gmake[1]: *** [all-recursive] Error 1
> gmake[1]: Leaving directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
>
>
> Any idea how this can be resolved?
>
> Thanks,
> Neeraj
>

Re: Build failing for native code

Posted by Phantom <gh...@gmail.com>.
By looking at the gcc command that you have a -m in it. It needs to be
either -m32 or -m64 depending on whether your machine is a 32 or 64 bit
machine.

A

On 6/18/07, Mahajan, Neeraj <ne...@ebay.com> wrote:
>
> Hi,
>
> I am trying to build the native code (which includes the compression
> library) on Solaris 10 (x86 64-bit). I get the following error while
> building:
>
> gmake  all-recursive
> gmake[1]: Entering directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
> Making all in src/org/apache/hadoop/io/compress/zlib
> gmake[2]: Entering directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apache/
> hadoop/io/compress/zlib'
> if /bin/sh ../../../../../../../libtool --mode=compile gcc
> -DHAVE_CONFIG_H -I. -I. -I../../../../../../..  -I/usr/java/include
> -I/usr/java/include/solaris -I/src
> -I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall -fPIC
> -O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF
> ".deps/ZlibCompressor.Tpo" -c -o ZlibCompressor.lo ZlibCompressor.c; \
> then mv -f ".deps/ZlibCompressor.Tpo" ".deps/ZlibCompressor.Plo"; else
> rm -f ".deps/ZlibCompressor.Tpo"; exit 1; fi
> gcc -DHAVE_CONFIG_H -I. -I. -I../../../../../../.. -I/usr/java/include
> -I/usr/java/include/solaris -I/src
> -I/home/nemahajan/hadoop-install/lzo/lzo-2.02-bin/include -g -Wall -fPIC
> -O2 -m -g -O2 -MT ZlibCompressor.lo -MD -MP -MF .deps/ZlibCompressor.Tpo
> -c ZlibCompressor.c  -fPIC -DPIC -o .libs/ZlibCompressor.o
> cc1: error: missing argument to "-m"
> gmake[2]: *** [ZlibCompressor.lo] Error 1
> gmake[2]: Leaving directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native/src/org/apache/
> hadoop/io/compress/zlib'
> gmake[1]: *** [all-recursive] Error 1
> gmake[1]: Leaving directory
> `/home/nemahajan/hadoop-install/hadoop-0.13.0/src/native'
>
>
> Any idea how this can be resolved?
>
> Thanks,
> Neeraj
>