mesos-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin Mahler <benjamin.mah...@gmail.com>
Subject Re: Compilation error while building mesos
Date Mon, 23 Sep 2013 18:15:56 GMT
This was possibly fixed here, are you compiling on a 32 bit system?

$ git show 56a54f53
commit 56a54f536b2d6b2b2bd80fdfd665d1cd5980a9c1
Author: Benjamin Mahler <bmahler@twitter.com>
Date:   Mon Aug 26 18:20:27 2013 -0700

    Fixed a 32 bit compilation issue in files.cpp.

    The call to min(ssize_t, long int) won't compile on 32 bit systems
    because ssize_t resolves to int on those systems.

    From: Kevin Lyda <kevin@ie.suberic.net>
    Review: https://reviews.apache.org/r/13793

diff --git a/src/files/files.cpp b/src/files/files.cpp
index c609505..69d6852 100644
--- a/src/files/files.cpp
+++ b/src/files/files.cpp
@@ -272,7 +272,7 @@ Future<Response> FilesProcess::read(const Request&
request)
   }

   // Cap the read length at 16 pages.
-  length = std::min(length, sysconf(_SC_PAGE_SIZE) * 16);
+  length = std::min<ssize_t>(length, sysconf(_SC_PAGE_SIZE) * 16);

   if (offset >= size) {
     os::close(fd.get());


On Sat, Sep 21, 2013 at 1:34 AM, bidha 2kbsd <bidha2kbsd@yahoo.com> wrote:

> Hello there.
>
> I was building mesos but got an error at last few minutes.
>
> I am using
>
> gcc --version
> gcc (SUSE Linux) 4.6.2
>
>
> javac -version
> javac 1.6.0_22
>
>
> Here is the compilation error
>
>
> libtool: compile:  g++ -DPACKAGE_NAME=\"mesos\"
> -DPACKAGE_TARNAME=\"mesos\" -DPACKAGE_VERSION=\"0.13.0\"
> "-DPACKAGE_STRING=\"mesos 0.13.0\"" -DPACKAGE_BUGREPORT=\"\"
> -DPACKAGE_URL=\"\" -DPACKAGE=\"mesos\" -DVERSION=\"0.13.0\"
> -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1
> -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1
> -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\"
> -DHAVE_PTHREAD=1 -DMESOS_HAS_JAVA=1 -DHAVE_PYTHON=\"2.7\"
> -DMESOS_HAS_PYTHON=1 -DHAVE_LIBZ=1 -DHAVE_LIBCRYPTO=1 -DHAVE_LIBSSL=1
> -DHAVE_LIBCURL=1 -I. -Wall -Werror -DLIBDIR=\"/usr/local/lib\"
> -DPKGLIBEXECDIR=\"/usr/local/lib/mesos\"
> -DPKGDATADIR=\"/usr/local/share/mesos\" -I../include
> -I../3rdparty/libprocess/include
> -I../3rdparty/libprocess/3rdparty/stout/include -I../include
> -I../3rdparty/libprocess/3rdparty/boost-1.53.0
> -I../3rdparty/libprocess/3rdparty/protobuf-2.4.1/src
> -I../3rdparty/libprocess/3rdparty/glog-0.3.1/src
> -I../3rdparty/zookeeper-3.3.4/src/c/include
> -I../3rdparty/zookeeper-3.3.4/src/c/generated -pthread -g -g2 -O2 -MT
> files/libmesos_no_3rdparty_la-files.lo -MD -MP -MF
> files/.deps/libmesos_no_3rdparty_la-files.Tpo -c files/files.cpp  -fPIC
> -DPIC -o files/.libs/libmesos_no_3rdparty_la-files.o
> files/files.cpp: In member function
> 'process::Future<process::http::Response>
> mesos::internal::FilesProcess::read(const process::http::Request&)':
> files/files.cpp:275:56: error: no matching function for call to
> 'min(ssize_t&, long int)'
> files/files.cpp:275:56: note: candidates are:
> /usr/include/c++/4.6/bits/stl_algobase.h:187:5: note: template<class _Tp>
> const _Tp& std::min(const _Tp&, const _Tp&)
> /usr/include/c++/4.6/bits/stl_algobase.h:233:5: note: template<class _Tp,
> class _Compare> const _Tp& std::min(const _Tp&, const _Tp&, _Compare)
> make[2]: *** [files/libmesos_no_3rdparty_la-files.lo] Error 1
> make[2]: Leaving directory `/home/sarose/stuff/java/mesos-0.13.0/src'
> make[1]: *** [all] Error 2
> make[1]: Leaving directory `/home/sarose/stuff/java/mesos-0.13.0/src'
> make: *** [all-recursive] Error 1
> sarose@linux-ljse:~/stuff/java/mesos-0.13.0>
>
>
>
>
> - Bidha
>

Mime
View raw message