hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Nauroth <cnaur...@hortonworks.com>
Subject Re: building branch-2 on windows
Date Wed, 28 Oct 2015 21:28:32 GMT
I just confirmed that I can build the release-2.6.2-RC0 tag from source on
Windows, including the native components.

For zlib, my setup is to have the source extracted in C:\zlib-1.2.7, and
that's where I point ZLIB_HOME.  The headers are in that directory.  I
have the built zlib1.dll in C:\zlib-1.2.7-bin\x64fre.  I include that
directory in my PATH at runtime.  This is only a requirement for the
runtime dynamic linking though, not a build requirement.  Running "hadoop
checknative" can confirm if the dynamic linking is working correctly.

Steve's output shows that it's trying to call CMake.  hadoop.dll and
winutils.exe are not built using CMake, so this makes me think that you
called the build with the -Pnative profile.  This profile is
*nix-specific.  For Windows, use -Pnative-win, or simply omit the
argument, because native-win is on by default in the pom.xml when Maven
detects the OS is Windows.

The other ZLIB_* environment variables you mentioned are not necessary,
unless these are somehow used indirectly in your own custom dev setup.  I
only set ZLIB_HOME.

--Chris Nauroth




On 10/28/15, 10:25 AM, "Xiaoyu Yao" <xyao@hortonworks.com> wrote:

>Can you change ZLIB_HOME to ZLIB_HOME=C:\bin\zlib-1.2.8 and copy two
>header files (zconf.h, lib.h) from %ZLIB_HOME%\include to %ZLIB_HOME%?
>
>
>Also, can you check if the Platform variable is defined?
>set Platform=x64 when building on a 64-bit system and set Platform=Win32
>when building on a 32-bit system.
>
>
>Thanks,
>Xiaoyu
>
>On 10/28/15, 9:18 AM, "Steve Loughran" <stevel@hortonworks.com> wrote:
>
>>
>>I've tried to get Hadoop 2.6.2 to build on windows, and can do the
>>non-native stuff if I disable javadocs.
>>
>>what I can't do is build the native libs; and this also holds for
>>branch-2
>>
>>main:
>>     [exec] -- Building for: NMake Makefiles
>>     [exec] -- The C compiler identification is MSVC 16.0.30319.1
>>     [exec] -- The CXX compiler identification is MSVC 16.0.30319.1
>>     [exec] -- Check for working C compiler: C:/Program Files
>>(x86)/Microsoft Visual Studio 10.0/VC/bin/amd64/cl.exe
>>     [exec] -- Check for working C compiler: C:/Program Files
>>(x86)/Microsoft Visual Studio 10.0/VC/bin/amd64/cl.exe --
>>works
>>     [exec] -- Detecting C compiler ABI info
>>     [exec] -- Detecting C compiler ABI info - done
>>     [exec] -- Check for working CXX compiler: C:/Program Files
>>(x86)/Microsoft Visual Studio 10.0/VC/bin/amd64/cl.exe
>>     [exec] -- Check for working CXX compiler: C:/Program Files
>>(x86)/Microsoft Visual Studio 10.0/VC/bin/amd64/cl.exe -
>>- works
>>     [exec] -- Detecting CXX compiler ABI info
>>     [exec] -- Detecting CXX compiler ABI info - done
>>     [exec] -- Found JNI: C:/Java/jdk8/lib/jawt.lib
>>     [exec] -- Configuring incomplete, errors occurred!
>>     [exec] See also
>>"C:/Work/hadoop-trunk/hadoop-common-project/hadoop-common/target/native/C
>>MakeFiles/CMakeOutput.log"
>>.
>>     [exec] CMake Error at
>>C:/bin/cmake-2.8/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cm
>>ake:108 (message):
>>     [exec]   Could NOT find ZLIB (missing: ZLIB_LIBRARY
>>ZLIB_INCLUDE_DIR)
>>     [exec] Call Stack (most recent call first):
>>     [exec]   
>>C:/bin/cmake-2.8/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cm
>>ake:315 (_FPHSA_FAILURE_MESSAGE)
>>     [exec]   C:/bin/cmake-2.8/share/cmake-2.8/Modules/FindZLIB.cmake:85
>>(FIND_PACKAGE_HANDLE_STANDARD_ARGS)
>>     [exec]   CMakeLists.txt:47 (find_package)
>>     [exec]
>>
>>So, no ZLIB
>>
>>Except I do have ZLIB, and certainly the native stuff built last year
>>
>>ZLIB_DIR=C:\bin\zlib-1.2.8
>>ZLIB_HOME=C:\bin\zlib-1.2.8\include
>>ZLIB_INCLUDE_DIR=C:\bin\zlib-1.2.8\include
>>ZLIB_LIBRARY=C:\bin\zlib-1.2.8\lib\zdll.lib
>>
>>C:\Work\hadoop-trunk>dir %ZLIB_INCLUDE_DIR%
>> Volume in drive C has no label.
>> Volume Serial Number is F021-1FF9
>>
>> Directory of C:\bin\zlib-1.2.8\include
>>
>>02/09/2014  17:47    <DIR>          .
>>02/09/2014  17:47    <DIR>          ..
>>14/06/2012  12:00            15,508 zconf.h
>>14/06/2012  11:58            87,883 zlib.h
>>               2 File(s)        103,391 bytes
>>               2 Dir(s)  28,374,454,272 bytes free
>>
>>C:\Work\hadoop-trunk>dir %ZLIB_LIBRARY%
>> Volume in drive C has no label.
>> Volume Serial Number is F021-1FF9
>>
>> Directory of C:\bin\zlib-1.2.8\lib
>>
>>18/07/2010  22:22            15,256 zdll.lib
>>
>>
>>Does anyone have any suggestions here? I like to have a setup where I
>>can build the native windows libs for the ASF releases
>>
>>


Mime
View raw message