hadoop 1.0.4源代码在cygwin编译错误解决

环境:cygwin+hadoop1.0.4+ant1.9+jdk1.6+win7
 
    其它过程我不再说明,google下都有了,只是在使用ant eclipse过程中,出现如下错误:
      我在cygwin里使用ant eclipse构建hadoop1.0.4的时候出现如下错误,大家帮忙看看。create-native-configure:
 
BUILD FAILED
D:\hadoop\hadoop1.0\build.xml:618: Execute failed: java.io.IOException: Cannot r                                                 un program "autoreconf" (in directory "D:\hadoop\hadoop1.0\src\native"): CreateP                                                 rocess error=2, ?????????
        at java.lang.ProcessBuilder.start(ProcessBuilder.java:460)
        at java.lang.Runtime.exec(Runtime.java:593)
        at org.apache.tools.ant.taskdefs.launcher.Java13CommandLauncher.exec(Jav                                                 a13CommandLauncher.java:41)哈达哦
 
 
   经过反复查找,终于确定,在cygwin下,hadoop1.0.4的native lib编译本身就是不支持的,链接: http://hadoop.apache.org/docs/r1.0.4/native_libraries.html
 
   因为我们只是了调试和分析源代码,并不一定要全部编译,所在我修改build.xml如下几行:
    <target name="compile-native">
    <antcall target="compile-core-native">
      <param name="compile.native" value="false"/>
    </antcall> 
  </target>
 
  <target name="create-native-configure">
    <!--<exec executable="autoreconf" dir="${native.src.dir}" searchpath="yes" 
          failοnerrοr="no">
       <arg value="-if"/>
    </exec>-->
  </target>
 
   重新执行ant eclipse,编译成功,导入到eclipse如下:
 

 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值