Friday, July 5, 2013

HBase compiling snappy

Error message:


     [exec] /bin/sh ./libtool --tag=CC   --mode=link gcc -g -Wall -fPIC -O2 -m64 -g -O2 -version-info 0:1:0 -L/usr/local/lib -o libhadoopsnappy.la -rpath /usr/local/lib src/org/apache/hadoop/io/compress/snappy/SnappyCompressor.lo src/org/apache/hadoop/io/compress/snappy/SnappyDecompressor.lo  -ljvm -ldl
     [exec] libtool: link: gcc -shared  src/org/apache/hadoop/io/compress/snappy/.libs/SnappyCompressor.o src/org/apache/hadoop/io/compress/snappy/.libs/SnappyDecompressor.o   -L/usr/local/lib -ljvm -ldl  -m64   -Wl,-soname -Wl,libhadoopsnappy.so.0 -o .libs/libhadoopsnappy.so.0.0.1
     [exec] /usr/bin/ld: cannot find -ljvm


Copy libjvm.so to /usr/local/lib

[dc@localhost bigtop-0.5.0]$ sudo cp /usr/java/jdk1.6.0_45/jre/lib/amd64/server/libjvm.so /usr/local/lib


Run >mvn install after changing the permissions on hadoop-snappy-readonly to do writes. I just did chmod 755 -R /home/dc/hadoop-snappy-readonly


[dc@localhost hadoop-snappy-read-only]$ mvn install
[INFO] Scanning for projects...
[INFO]                                                                        
[INFO] ------------------------------------------------------------------------
[INFO] Building Hadoop Snappy 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.5:resources (default-resources) @ hadoop-snappy ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /home/dc/hadoop-snappy-read-only/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) @ hadoop-snappy ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-antrun-plugin:1.6:run (compile) @ hadoop-snappy ---
[INFO] Executing tasks

main:

checkpreconditions:

compilenative:
     [exec] libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, `config'.
     [exec] libtoolize: copying file `config/ltmain.sh'
     [exec] libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
     [exec] libtoolize: copying file `m4/libtool.m4'
     [exec] libtoolize: copying file `m4/ltoptions.m4'
     [exec] libtoolize: copying file `m4/ltsugar.m4'
     [exec] libtoolize: copying file `m4/ltversion.m4'
     [exec] libtoolize: copying file `m4/lt~obsolete.m4'
     [exec] checking for gcc... gcc
     [exec] checking for C compiler default output file name... a.out
     [exec] checking whether the C compiler works... yes
     [exec] checking whether we are cross compiling... no
     [exec] checking for suffix of executables...
     [exec] checking for suffix of object files... o
     [exec] checking whether we are using the GNU C compiler... yes
     [exec] checking whether gcc accepts -g... yes
     [exec] checking for gcc option to accept ISO C89... none needed
     [exec] checking for special C compiler options needed for large files... no
     [exec] checking for _FILE_OFFSET_BITS value needed for large files... no
     [exec] checking for a BSD-compatible install... /usr/bin/install -c
     [exec] checking whether build environment is sane... yes
     [exec] checking for a thread-safe mkdir -p... /bin/mkdir -p
     [exec] checking for gawk... gawk
     [exec] checking whether make sets $(MAKE)... yes
     [exec] checking for style of include used by make... GNU
     [exec] checking dependency style of gcc... gcc3
     [exec] checking for gcc... (cached) gcc
     [exec] checking whether we are using the GNU C compiler... (cached) yes
     [exec] checking whether gcc accepts -g... (cached) yes
     [exec] checking for gcc option to accept ISO C89... (cached) none needed
     [exec] checking build system type... x86_64-unknown-linux-gnu
     [exec] checking host system type... x86_64-unknown-linux-gnu
     [exec] checking for a sed that does not truncate output... /bin/sed
     [exec] checking for grep that handles long lines and -e... /bin/grep
     [exec] checking for egrep... /bin/grep -E
     [exec] checking for fgrep... /bin/grep -F
     [exec] checking for ld used by gcc... /usr/bin/ld
     [exec] checking if the linker (/usr/bin/ld) is GNU ld... yes
     [exec] checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
     [exec] checking the name lister (/usr/bin/nm -B) interface... BSD nm
     [exec] checking whether ln -s works... yes
     [exec] checking the maximum length of command line arguments... 1966080
     [exec] checking whether the shell understands some XSI constructs... yes
     [exec] checking whether the shell understands "+="... yes
     [exec] checking for /usr/bin/ld option to reload object files... -r
     [exec] checking for objdump... objdump
     [exec] checking how to recognize dependent libraries... pass_all
     [exec] checking for ar... ar
     [exec] checking for strip... strip
     [exec] checking for ranlib... ranlib
     [exec] checking command to parse /usr/bin/nm -B output from gcc object... ok
     [exec] checking how to run the C preprocessor... gcc -E
     [exec] checking for ANSI C header files... yes
     [exec] checking for sys/types.h... yes
     [exec] checking for sys/stat.h... yes
     [exec] checking for stdlib.h... yes
     [exec] checking for string.h... yes
     [exec] checking for memory.h... yes
     [exec] checking for strings.h... yes
     [exec] checking for inttypes.h... yes
     [exec] checking for stdint.h... yes
     [exec] checking for unistd.h... yes
     [exec] checking for dlfcn.h... yes
     [exec] checking for objdir... .libs
     [exec] checking if gcc supports -fno-rtti -fno-exceptions... no
     [exec] checking for gcc option to produce PIC... -fPIC -DPIC
     [exec] checking if gcc PIC flag -fPIC -DPIC works... yes
     [exec] checking if gcc static flag -static works... no
     [exec] checking if gcc supports -c -o file.o... yes
     [exec] checking if gcc supports -c -o file.o... (cached) yes
     [exec] checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
     [exec] checking whether -lc should be explicitly linked in... no
     [exec] checking dynamic linker characteristics... GNU/Linux ld.so
     [exec] checking how to hardcode library paths into programs... immediate
     [exec] checking whether stripping libraries is possible... yes
     [exec] checking if libtool supports shared libraries... yes
     [exec] checking whether to build shared libraries... yes
     [exec] checking whether to build static libraries... yes
     [exec] checking whether gcc and cc understand -c and -o together... yes
     [exec] checking for dlopen in -ldl... yes
     [exec] checking for ANSI C header files... (cached) yes
     [exec] checking stdio.h usability... yes
     [exec] checking stdio.h presence... yes
     [exec] checking for stdio.h... yes
     [exec] checking stddef.h usability... yes
     [exec] checking stddef.h presence... yes
     [exec] checking for stddef.h... yes
     [exec] checking snappy-c.h usability... yes
     [exec] checking snappy-c.h presence... yes
     [exec] checking for snappy-c.h... yes
     [exec] checking Checking for the 'actual' dynamic-library for '-lsnappy'... "libsnappy.so.1"
     [exec] checking for an ANSI C-conforming const... yes
     [exec] checking for size_t... yes
     [exec] checking for JNI_GetCreatedJavaVMs in -ljvm... yes
     [exec] checking jni.h usability... yes
     [exec] checking jni.h presence... yes
     [exec] checking for jni.h... yes
     [exec] configure: creating ./config.status
     [exec] config.status: creating Makefile
     [exec] config.status: creating config.h
     [exec] config.status: config.h is unchanged
     [exec] config.status: executing depfiles commands
     [exec] config.status: executing libtool commands
     [exec] make[1]: Entering directory `/home/dc/hadoop-snappy-read-only/target/native-src'
     [exec] test -z "/usr/local/lib" || /bin/mkdir -p "/home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib"
     [exec]  /bin/sh ./libtool   --mode=install /usr/bin/install -c   libhadoopsnappy.la '/home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib'
     [exec] libtool: install: /usr/bin/install -c .libs/libhadoopsnappy.so.0.0.1 /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib/libhadoopsnappy.so.0.0.1
     [exec] libtool: install: (cd /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib && { ln -s -f libhadoopsnappy.so.0.0.1 libhadoopsnappy.so.0 || { rm -f libhadoopsnappy.so.0 && ln -s libhadoopsnappy.so.0.0.1 libhadoopsnappy.so.0; }; })
     [exec] libtool: install: (cd /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib && { ln -s -f libhadoopsnappy.so.0.0.1 libhadoopsnappy.so || { rm -f libhadoopsnappy.so && ln -s libhadoopsnappy.so.0.0.1 libhadoopsnappy.so; }; })
     [exec] libtool: install: /usr/bin/install -c .libs/libhadoopsnappy.lai /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib/libhadoopsnappy.la
     [exec] libtool: install: /usr/bin/install -c .libs/libhadoopsnappy.a /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib/libhadoopsnappy.a
     [exec] libtool: install: warning: remember to run `libtool --finish /usr/local/lib'
     [exec] libtool: install: chmod 644 /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib/libhadoopsnappy.a
     [exec] libtool: install: ranlib /home/dc/hadoop-snappy-read-only/target/native-build/usr/local/lib/libhadoopsnappy.a
     [exec] make[1]: Nothing to be done for `install-data-am'.
     [exec] make[1]: Leaving directory `/home/dc/hadoop-snappy-read-only/target/native-src'
[INFO] Executed tasks
[INFO]
[INFO] --- maven-resources-plugin:2.5:testResources (default-testResources) @ hadoop-snappy ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO]
[INFO] --- maven-compiler-plugin:2.3.2:testCompile (default-testCompile) @ hadoop-snappy ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-surefire-plugin:2.6:test (default-test) @ hadoop-snappy ---
[INFO] Surefire report directory: /home/dc/hadoop-snappy-read-only/target/surefire-reports

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.apache.hadoop.io.compress.snappy.TestSnappyCodec
Jul 5, 2013 7:19:50 PM org.apache.hadoop.io.compress.snappy.LoadSnappy
WARNING: Snappy native library is available
Jul 5, 2013 7:19:50 PM org.apache.hadoop.io.compress.snappy.LoadSnappy
INFO: Snappy native library loaded
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.262 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO]
[INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ hadoop-snappy ---
[INFO]
[INFO] --- maven-assembly-plugin:2.2-beta-3:single (default) @ hadoop-snappy ---
[INFO] Reading assembly descriptor: src/main/assemblies/hadoop-snappy.xml
[INFO] Copying files to /home/dc/hadoop-snappy-read-only/target/hadoop-snappy-0.0.1-SNAPSHOT-tar
[WARNING] Assembly file: /home/dc/hadoop-snappy-read-only/target/hadoop-snappy-0.0.1-SNAPSHOT-tar is not a regular file (it may be a directory). It cannot be attached to the project build for installation or deployment.
[INFO]
[INFO] --- maven-antrun-plugin:1.6:run (package) @ hadoop-snappy ---
[INFO] Executing tasks

main:

checkpreconditions:

cleanuppreviousrun:

assemblynative:

checkpreconditions:

cleanuppreviousrun:

assemblynative:
[INFO] Executed tasks
[INFO]
[INFO] --- build-helper-maven-plugin:1.5:attach-artifact (abc) @ hadoop-snappy ---
[INFO]
[INFO] --- maven-install-plugin:2.3.1:install (default-install) @ hadoop-snappy ---
[INFO] Installing /home/dc/hadoop-snappy-read-only/target/hadoop-snappy-0.0.1-SNAPSHOT.jar to /home/dc/.m2/repository/org/apache/hadoop/hadoop-snappy/0.0.1-SNAPSHOT/hadoop-snappy-0.0.1-SNAPSHOT.jar
[INFO] Installing /home/dc/hadoop-snappy-read-only/pom.xml to /home/dc/.m2/repository/org/apache/hadoop/hadoop-snappy/0.0.1-SNAPSHOT/hadoop-snappy-0.0.1-SNAPSHOT.pom
[INFO] Installing /home/dc/hadoop-snappy-read-only/target/hadoop-snappy-0.0.1-SNAPSHOT-Linux-amd64-64.tar to /home/dc/.m2/repository/org/apache/hadoop/hadoop-snappy/0.0.1-SNAPSHOT/hadoop-snappy-0.0.1-SNAPSHOT-Linux-amd64-64.tar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 22.203s
[INFO] Finished at: Fri Jul 05 19:19:56 PDT 2013
[INFO] Final Memory: 8M/145M
[INFO] ------------------------------------------------------------------------
[dc@localhost hadoop-snappy-read-only]$

No comments:

Post a Comment