hadoop-lzo logs version information when it loads. We've discovered that for Windows builds, we're instead getting error output from the get_build_revision.sh script. For example:
14/09/29 14:30:47 INFO lzo.LzoCodec: Successfully loaded & initialized native-lzo library [hadoop-lzo rev D:\w\b\project\hadoop-lzo/scripts/get_build_revision.sh: line 2: $'\r': command not found
D:\w\b\project\hadoop-lzo/scripts/get_build_revision.sh: line 28: syntax error: unexpected end of file]
This information comes from the build.properties file. There are 2 problems with the way this file is generated on Windows:
Running sh on a script, even on Windows, expects LF line endings. At least this is the case with the sh builds from GnuWin32 that I've used. However, depending on the git user, the files might get checked out with CRLF line endings on Windows.
The argument passed to sh is the absolute path of the get_build_revision.sh, composed by concatenating the Maven basedir and the relative path to get_build_revision.sh. On Windows, basedir will contain back slashes. sh can handle this, but it writes a warning to stderr advising that it would be better to use forward slashes.
hadoop-lzo logs version information when it loads. We've discovered that for Windows builds, we're instead getting error output from the get_build_revision.sh script. For example:
This information comes from the build.properties file. There are 2 problems with the way this file is generated on Windows: