Hello;
I was trying to build Hadoop 2.4.0 on FreeBSD 10 and while the Java
stuff went fine, I got stuck in file:
[exec]
/usr/ports/devel/hadoop2/work/hadoop-2.4.0-src/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/container-executor.c:1250:48:
error: too many arguments to function call, expected 4, have 5
[exec] if (mount("none", mount_path, "cgroup", 0, controller)
== 0) {
[exec] ~~~~~ ^~~~~~~~~~
[exec] /usr/include/sys/mount.h:929:1: note: 'mount' declared here
[exec] int mount(const char *, const char *, int, void *);
[exec] ^
[exec] 2 warnings and 2 errors generated.
[exec] *** Error code 1
[exec]
[exec] Stop.
[exec] make[2]: stopped in
/usr/ports/devel/hadoop2/work/hadoop-2.4.0-src/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/target/native
[exec] *** Error code 1
[exec]
[exec] Stop.
...
I don't know well the code, and I have never used linux but I would
assume by the name that mount_cgroup() is meant to be linux dependent?
Container Groups are, of course, not available on FreeBSD but perhaps
they could be replaced by resource limits[1]. In any case, it would seem
like the code should avoid attempting to build linux-specific features
on non-linux.
Regards,
Pedro.
[1]
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/security-resourcelimits.html